Parallelize Translate FQ changeset & some state loading to speed up r…#22621
Parallelize Translate FQ changeset & some state loading to speed up r…#22621simsonraj wants to merge 1 commit into
Conversation
|
👋 simsonraj, thanks for creating this pull request! To help reviewers, please consider creating future PRs as drafts first. This allows you to self-review and make any final changes before notifying the team. Once you're ready, you can mark it as "Ready for review" to request feedback. Thanks! |
|
✅ No conflicts with other open PRs targeting |
There was a problem hiding this comment.
Pull request overview
Risk Rating: MEDIUM
Parallelizes on-chain state loading and the 1.5→1.6 FeeQuoter translation/migration RPC fetches to reduce end-to-end runtime, especially for legacy-heavy environments.
Changes:
- Parallelize RPC-bound contract state loading in
LoadChainStatewith bounded concurrency. - Batch-fetch 1.5.0 OnRamp fee token configs and token transfer fee configs concurrently, replacing per-token sequential operations.
- Add new batch operations to retrieve per-token configs with an
errgroupconcurrency limit.
Scrupulous Human Review Areas
deployment/ccip/shared/stateview/state.go: concurrency correctness in the newworkexecution (goroutine closures, mutex coverage, and correctness of resulting state).deployment/ccip/operation/evm/v1_5/ops_evm2evm_onramp.go: RPC concurrency limits and context propagation behavior (provider throttling, cancellation, and error surface).
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| deployment/ccip/shared/stateview/state.go | Introduces parallel execution for RPC-bound address/state loading with a concurrency cap. |
| deployment/ccip/sequence/evm/migration/seq_translate_onramp_fq.go | Switches translation to use new batch operations instead of per-token sequential config fetches. |
| deployment/ccip/operation/evm/v1_5/ops_evm2evm_onramp.go | Adds batch operations to concurrently fetch fee token and transfer fee configs from a 1.5.0 OnRamp. |
| // run RPC-bound work in parallel | ||
| grp, gctx := errgroup.WithContext(ctx) | ||
| grp.SetLimit(10) | ||
| for _, w := range work { |
|




Translate FQ changeset & state loading (especially with legacy contracts) takes long load time
Parallelize to improve the run time