Kodiak Island Factory
The core factory contract that manages deploying new islands and central shared setting between these islands for permission-less islands
Deploying New Islands
Creates a new Kodiak Island using these parameters. Get the tokens and fee tier for the pool you want to deploy the island for.
Deployment process - The tokens are sorted and the kodiak pool is fetched, if the kodiak pool does not exist it throws an error.
Parameters:
tokenA
: First token in the pool pairtokenB
: Second token in the pool pairuniFee
: Underlying pool fee tier (eg: 100, 500, 3000, 10000)manager
: Manager address (0x0 for unmanaged/permisionless islands)managerTreasury
: The address that will receive the manager's fee sharemanagerFee
: Manager fee in basis points (0 - 10000)lowerTick
: lower tick of the island's positionupperTick
: upper tick of the islnad's position
Returns:
island (address): The address of the newly deployed KodiakIsland vault.
Deployment Process:
The function sorts the tokens (tokenA, tokenB) to ensure consistent ordering.
It fetches the corresponding Kodiak V3 pool address using the provided tokens and fee tier.
It validates that the Kodiak V3 pool exists and that the provided ticks align with the pool's tick spacing.
It clones the islandImplementation contract to create a new KodiakIsland vault.
It initializes the new vault with the provided parameters.
It adds the deployer to the list of deployers and the island to the list of islands deployed by the manager.
Emits: IslandCreated
on successful deployment
Requirements for deploying a permissionless Island
The
manager
address must be set to zero address.The
managerTreasury
must be set to zero address.The
managerFee
must be set to 0.The deployed island refers the
managerFee
andmanagerTreasury
from the factory for permissionless islands
Querying Deployed Islands and related data
Get All Deployers
Returns array of all addresses that have deployed at least one island.
Returns:
address[]
: Array of deployer addresses
Get Islands by Deployer
Returns array of all islands deployed by a specific address.
Parameters:
deployer
: Address to query islands for
Returns:
islands
: Array of island addresses deployed by specified deployerReturns empty array if no islands deployed
Count Functions
Returns total number of islands deployed through factory.
Returns total number of unique deployer addresses.
Returns number of islands deployed by specific address.
Parameters:
deployer
: Address to query island count for
Factory Management
Only the factory owner can call these functions.
Set Island Implementation
Updates the implementation contract used for new island deployments.
Parameters:
_implementation
: Address of new implementation contractMust be non-zero address
Must be a valid KodiakIsland contract
Requirements:
Caller must be factory owner
Implementation address cannot be zero
Emits: UpdateIslandImplementation(address implementation)
Set Treasury
Updates the treasury address that receives protocol fees.
Parameters:
_treasury
: New treasury addressMust be non-zero address
Will receive protocol fees from permissionless islands
Requirements:
Caller must be factory owner
Treasury address cannot be zero
Emits: TreasurySet(address treasury)
Set Island Fee
Updates the protocol fee for permissionless islands.
Parameters:
_islandFee
: New protocol fee in basis pointsMust be between 0-2000 (0-20%)
Applied to all permissionless islands
Requirements:
Caller must be factory owner
Fee cannot exceed 2000 (20%)
Emits: IslandFeeSet(uint16 islandFee)
ABI
Last updated