-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
At a high level the relay is basically a compounder. We have two types of Relay:
- compounder - was designed for everyone to convert claimed rewards into VELO and locked veVELO into deposited veNFTs
- converter - was designed for our Foundations to convert claimed rewards into USDC
The general flow here is:
- Claim & lock rebases
- Claim rewards
- Swap rewards into VELO or USDC
- Extra step for compounders lock/compound the VELO
The challenges here are:
- all computations are done in real-time onchain, there’s no APIs nor external services
- onchain data needs to be fetched efficiently and we should leverage the Sugar where possible
- limited memory / computing resources on the execution nodes, likely needs some architecture work for splitting the workload into steps (eg. swaps, or claims), sort of dispatcher approach (see bellow)
The current relay automation architecture we have is monolithic, so I don't expect it to fit in this current shape. It would have to be broken down per relay, where the processing is done per relay and every step can be run independently and/or triggered by a previous step/event:
- Relay epoch triggered
- Claims rewards and triggers
- Swaps rewards and triggers
- Compounds
- Claims rebases
Relevat repositories (plus a private one we can share, with the current monolithic implementation):
https://github.com/velodrome-finance/relay
https://github.com/velodrome-finance/sugar/?tab=readme-ov-file#relay-data
Metadata
Metadata
Assignees
Labels
No labels