Ccip-8548 deploy and update fee quoter changeset#1641
Ccip-8548 deploy and update fee quoter changeset#1641
Conversation
…into CCIP-8548-deploy-fq
| ) | ||
|
|
||
| // CreateFeeQuoterUpdateInputFromV160 creates FeeQuoterUpdate input by importing configuration from FeeQuoter v1.6.0 | ||
| CreateFeeQuoterUpdateInputFromV160 = cldf_ops.NewSequence( |
There was a problem hiding this comment.
@RensR could you please review this sequence?
| }) | ||
|
|
||
| // CreateFeeQuoterUpdateInputFromV150 creates FeeQuoterUpdate input by importing configuration from PriceRegistry v1.5.0 and EVM2EVMOnRamp v1.5.0 | ||
| CreateFeeQuoterUpdateInputFromV150 = cldf_ops.NewSequence( |
RensR
left a comment
There was a problem hiding this comment.
You determine to call 1.5 import or 1.6 import based on the currently active lane, right?
| ) | ||
|
|
||
| var ( | ||
| EVMFamilySelector, _ = hex.DecodeString("2812d52c") |
There was a problem hiding this comment.
Let's put this somewhere else
There was a problem hiding this comment.
chainlink-ccip/deployment/utils/common.go
Line 58 in dcb7f6e
| // SequenceFeeQuoterUpdate is a sequence that deploys or fetches existing FeeQuoter contract | ||
| // and does the following if the corresponding input is provided - | ||
| // 1. applies destination chain config updates | ||
| // 2. price updates |
There was a problem hiding this comment.
What is the purpose of doing manual price updates?
There was a problem hiding this comment.
The existing connectChain changeset does manual price updates, wanted to keep this equivalent to all ops done in connectchain changeset for feequoter
| MaxDataBytes: destChainConfig.MaxDataBytes, | ||
| MaxPerMsgGasLimit: destChainConfig.MaxPerMsgGasLimit, | ||
| DestGasOverhead: destChainConfig.DestGasOverhead, | ||
| DestGasPerPayloadByteBase: destChainConfig.DestGasPerPayloadByteBase, |
There was a problem hiding this comment.
This should account for DA costs now, which makes it tricky to calculate. @matYang is our DA expert maybe he has some wisdom (aka constant multipliers)
There was a problem hiding this comment.
Will keep it same as the existing value for now and come back to it when @matYang can get to this
| DefaultTokenDestGasOverhead: destChainConfig.DefaultTokenDestGasOverhead, | ||
| DefaultTxGasLimit: destChainConfig.DefaultTxGasLimit, | ||
| NetworkFeeUSDCents: uint16(destChainConfig.NetworkFeeUSDCents), | ||
| LinkFeeMultiplierPercent: 90, |
There was a problem hiding this comment.
Please move up to constant, no magic values should be hidden in these functions
| fqops.Version, | ||
| "", | ||
| ) | ||
| isNewDeployment := datastore_utils.IsAddressRefEmpty(feeQuoterRef) |
There was a problem hiding this comment.
This means 1.7 is a new deployment, right? Can we make that more clear.
Can we also move this down to the other if isNewDeployment and merge them?
| semver.MustParse("1.7.0"), | ||
| "Creates FeeQuoterUpdate input by importing configuration from PriceRegistry v1.5.0 and EVM2EVMOnRamp v1.5.0", | ||
| func(b cldf_ops.Bundle, chain evm.Chain, input deploy.FeeQuoterUpdateInput) (output FeeQuoterUpdate, err error) { | ||
| // get ro |
| DestChainConfigArgs: destChainCfgs, | ||
| TokenTransferFeeConfigArgs: tokenTransferFeeConfigArgsForAll, | ||
| // TODO: what to do with price updaters for 1.5 if there is no 1.6 lanes here | ||
| PriceUpdaters: []common.Address{}, |
There was a problem hiding this comment.
Price updaters can just be all 1.5 commit stores and all 1.6 offramps on any lane, right? That always gives you everything you need
Yes that's a good call, updating it |
| MaxPerMsgGasLimit: onRampCfg.DynamicConfig.MaxPerMsgGasLimit, | ||
| DestGasOverhead: onRampCfg.DynamicConfig.DestGasOverhead, | ||
| DestGasPerPayloadByteBase: uint8(onRampCfg.DynamicConfig.DestGasPerPayloadByte), | ||
| ChainFamilySelector: [4]byte(EVMFamilySelector), // as this is evm, safe to assume chain family selector is same as chain selector |
There was a problem hiding this comment.
This is for a remote chain though, remote chain selector not guaranteed to be EVM
| DefaultTokenDestGasOverhead: onRampCfg.DynamicConfig.DefaultTokenDestGasOverhead, | ||
| DefaultTxGasLimit: uint32(onRampCfg.StaticConfig.DefaultTxGasLimit), | ||
| NetworkFeeUSDCents: networkFeeUSDCents, | ||
| LinkFeeMultiplierPercent: 90, |
…inlink-ccip into CCIP-8548-deploy-fq
|
deployment/deploy/feequoterupdater.go):Introduces
UpdateFeeQuoterChangesetthat orchestrates the complete FeeQuoter deployment/update workflow.Supports deploying new FeeQuoter contracts or updating existing ones
Automatically updates OnRamp and OffRamp contracts to reference the new FeeQuoter address
- Added support for updating OnRamp and OffRamp contracts with new FeeQuoter addresses
- Handles source chain configuration updates for OffRamp
Handles configuration import from v1.5.0 and v1.6.0 versions ( refer to the ccv/chains/evm/deployment/v1_7_0/sequences/SequenceFeeQuoterInputCreation_Mapping.md)
Fee Quoter Update Workflow
PopulateConfigis enabled, imports configuration from previous FeeQuoter versionsFeeQuoterUpdateInputfrom existing contract metadata or imported configuration