OEV-699 Introduce relayConfig.GasLimit to override gas limit on job level#302
Merged
OEV-699 Introduce relayConfig.GasLimit to override gas limit on job level#302
Conversation
cll-gg
added a commit
to smartcontractkit/chainlink
that referenced
this pull request
Nov 26, 2025
Contributor
There was a problem hiding this comment.
Pull request overview
This PR introduces the ability to configure gas limits at the job level through relayConfig.GasLimit, providing a higher-precedence override than existing configuration options. This enables specific feeds (like SVR and L2EP) to use custom gas limits without conforming to global settings.
Key Changes:
- Added
GasLimitfield toRelayConfigstructure with highest precedence in the gas limit hierarchy - Extracted gas limit resolution logic into a dedicated
getGasLimitFromfunction for better testability - Added comprehensive test coverage for all gas limit precedence scenarios
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| pkg/config/types.go | Added GasLimit field to RelayConfig struct with documentation |
| pkg/config/types_test.go | Extended test to verify GasLimit field serialization/deserialization |
| pkg/transmitter/util.go | Refactored gas limit logic into getGasLimitFrom function and added relay config gas limit support |
| pkg/transmitter/util_test.go | Added comprehensive unit tests for gas limit precedence logic |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
cll-gg
added a commit
to smartcontractkit/chainlink
that referenced
this pull request
Nov 26, 2025
Use different chainlink-ccv/go version to make make tidy work
jmank88
reviewed
Nov 26, 2025
…g.GasLimit -> opts.PluginGasLimit
jmank88
approved these changes
Nov 26, 2025
pavel-raykov
approved these changes
Nov 26, 2025
cll-gg
added a commit
to smartcontractkit/chainlink
that referenced
this pull request
Nov 27, 2025
This reverts commit 2ca8e45.
cll-gg
added a commit
to smartcontractkit/chainlink
that referenced
this pull request
Nov 27, 2025
github-merge-queue bot
pushed a commit
to smartcontractkit/chainlink
that referenced
this pull request
Nov 27, 2025
* OEV-699 WIP: forward job.GasLimit to Transmitter for OCR2 median jobs * Fix test * Set gas limit on the median config * Tested with an actual gas limit on a job * Remove test output * Add changeset * Improve log message * Add tag to changeset * Add check to install protoc script (seems to fail) * Revert "Add check to install protoc script (seems to fail)" This reverts commit 5c6996d. * Remove erroneous log message * Don't override gasLimit if already set * Add test for overriding gas limit * Bit of cleanup * Reformat * Run golangci-lint-v2 * Inline * Just use pluginConfig.GasLimit directly * Add unit test * Remove old test * Move test-specific mocks into their specific test * Use setupMocksAndRelayer() in the test * Use setupMocksAndRelayer only in the added test * Move gasLimit to RelayConfig instead (smartcontractkit/chainlink-evm#302) * Revert a bit more * Update changeset * Use chainlink-evm commit hash (not merged yet) * Revert "Use chainlink-evm commit hash (not merged yet)" This reverts commit 956804b. * Use smartcontractkit/chainlink-evm#302 for chainlink-evm Use different chainlink-ccv/go version to make make tidy work * Revert "Use smartcontractkit/chainlink-evm#302 for chainlink-evm" This reverts commit 2ca8e45. * Use latest chainlink-evm (specifically, smartcontractkit/chainlink-evm#302)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
OEV-699: Make it possible to set the gas limit per feed.
We want to do this for SVR and L2EP feeds specifically, so that they don't need to conform to the global gas limit.
There's support on the transmitter side for setting a custom gas limit here.
This is used for e.g. Automation to set gas limit per Product.
With this change, we can now also set gas limit per job.
Supports
smartcontractkit/chainlink#20386
Notes