Skip to content

feat: Develop PoolFactory.sol smart contract #23

Description

@rafamiziara

Description

Develop the PoolFactory smart contract that will be responsible for creating and managing lending pool deployments using upgradeable proxy patterns.

Acceptance Criteria

  • Create PoolFactory.sol contract with createPool function
  • Implement upgradeable proxy pattern for LendingPool deployments
  • Add proper access controls (Ownable)
  • Emit PoolCreated events with relevant data
  • Include pool registry functionality
  • Add comprehensive unit tests
  • Gas optimization and security considerations

Technical Requirements

  • Use OpenZeppelin upgradeable contracts
  • Implement proper initialization patterns
  • Include comprehensive error handling with custom errors
  • Follow security best practices (reentrancy guards, etc.)
  • Support for ERC20 token pools and native POL pools

Smart Contract Functions

  • createPool(poolParams) - Creates new lending pool
  • getPoolAddress(poolId) - Returns deployed pool address
  • getPoolCount() - Returns total number of pools
  • transferOwnership() - For multi-sig transfer

Definition of Done

  • PoolFactory contract is fully implemented and tested
  • Unit test coverage > 90%
  • Gas usage optimized
  • Security audit checklist completed
  • Contract compiles without warnings

Metadata

Metadata

Assignees

Labels

comp: contractsIssues related to the smart contracts in packages/contracts

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions