Proposal overview
Aave v2/v3 Collectors unification
Simple Summary
Technical upgrade to align the implementation and architecture of Aave’s ecosystem Collector contracts across all networks.
Motivation
The Aave ecosystem, and more precisely its liquidity protocol (v1/v2/v3) collect fees in a decentralized way, which later on are used for example to fund grants, pay different service providers, or pursue different other strategies.
All these actions are controlled by the Aave Governance V2 smart contracts (or cross-chain governance), and due to technical reasons regarding upgradeable contracts, usually they are triggered by interacting with another contract called Controller of Collector, which simply acts as a layer of indirection with the Collector itself.
But in practice, this current organization has some points of improvement:
- The codebase of the Collector is different across instances of Aave. The most updated version is the one on Ethereum, with others for example not supporting streaming, just because of legacy reasons.
- The pattern of Controller of Collector <> Collector can be simplified and unified with other parts of the ecosystem.
Sometimes, this lack of technical unification creates overhead (both operational and of understanding) on contributors, specifically those interacting with the “treasury” side of the protocol like Llama, so we present this proposal to improve the system.
Specification
The smart contract used as the implementation of the Aave v2 & v3 Collector (a common proxy for both) is the most updated of the ecosystem, activated on https://app.aave.com/governance/proposal/71/, and mainly adding streaming capabilities.
- UpgradeAaveCollectorPayload: this proposal payload will deploy the most up-to-date version of the collector and set it as the implementation for the existing proxy for all v3 deployments. Moreover, it will change not optimal "Controller of Collector" pattern to a more commonly used "ProxyAdmin".
Currently, apart from Ethereum, Polygon, and Avalanche are the only networks with both instances of Aave v2 and v3.
- MigrateV2CollectorPayload: This proposal will redirect all future fee collection of the v2 pools to v3’s Collector by updating the AToken implementation. For both Polygon and Avalanche v2, instances, before redirecting fee collection to the v3’s Collector, the proposal will send there all the accrued fees plus rewards incentives on those.
This proposal will be an approval for the Avalanche part, and both payloads will be executed there separately by the Aave Guardian. For other networks, the execution will happen through this proposal.
References
A list of relevant links like for this proposal:
- forum discussion
- tests
- Contracts:
Security Considerations
The previous upgrade of the Collector contract, which is currently active on Mainnet, was reviewed by Certora. Our policy was to have minimum deviaton from this version.
-
Code diffing: Comparing the codebase of all existing Collectors with the consolidated one, to not have any unexpected logic included or missing.
-
Storage diffing: Comparing the storage layout of versions, to verify that there is no misalignment between them, which could create important problems. Generated diffs:
-
E2E tests: we are checking that the main actions available on the Collector can be performed (e.g. transfer, approve) on networks, and additionally we check that updated permissions are set correctly.
Deployed Contracts
Collector Unification
V2 Funds Transfer
Copyright
Copyright and related rights waived via CC0.
Your voting info
Voting results
YAE
634,985
AAVE100.00%
NAY
<1
AAVE<0.01%
Votes
Executed on
Apr 22, 2023Required
634.98K
320.00K
Required
634.98K
80,000.00
16,000,000
Proposal details
Block
17 Apr 2023, 08:01 UTC +00:00
17065190
Block
18 Apr 2023, 08:28 UTC +00:00
17072390
Block
21 Apr 2023, 00:28 UTC +00:00
17091590
22 Apr 2023, 01:44 UTC +00:00
BGD Labs (@bgdlabs)