The PoolDeployer contract facilitates the atomic deployment, initialization and configuration of the all contracts necessary to run a Pool:
PoolManager, which itself deploys:
- some number of
The following pre-requisite configurations are necessary in order to deploy a Pool in the Maple protocol.
- 1.Deploying address is a valid Pool Delegate in
- 2.The provided
PoolManagerFactoryis a valid factory in
- 3.The provided
WithdrawalManagerFactoryis a valid factory in
- 4.Each provided
LoanManagerFactoryis a valid factory in
- 5.The Pool Delegate does not own a
- 6.The Pool Asset is a valid asset in
WithdrawalManagerwithdrawal window is shorter than the cycle duration.
- 8.The required pool cover can be transferred from the Pool Delegate to the
To deploy a Pool,
PoolDeployercan be called with the following parameters:
asset- The main asset that the pool denominates in.
symbolfor identification of the pool shares token.
- Configuration params:
liquidityCap- The maximum amount of funds asset that can be deposited in the pool
managementFeeRate- The rate of the interest that is sent to pool delegates as management fee.
poolCoverAmount- The amount of pool cover that the pool delegate is required to deposit.
cycleDuration- The duration, in seconds, of each cycle of the withdrawal manager.
windowDuration- The duration, in seconds, of the withdrawal window.
initialSupply- The initial supply of pool tokens.
Before the Pool can start accepting deposits and operating, the Governor needs to call
activatePoolManagerin Globals. This will activate the Pool. This allows the Governor to set up fee parameters, default parameters, and ensure that the requisite cover has been posted by the Pool Delegate before running the Pool.