From 266d3ac6c32d4ffd48aa717555bb8671be8c78d4 Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Tue, 27 Jun 2023 19:52:18 -0400 Subject: [PATCH 01/15] Bump version and update CHANGELOG for core v2.3.0 --- VERSION | 2 +- docs/CHANGELOG.md | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/VERSION b/VERSION index ccbccc3dc62..276cbf9e285 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2.2.0 +2.3.0 diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 2c5d1a761e9..d347297fb61 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -8,6 +8,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] + +... + +## 2.3.0 - UNRELEASED + ### Added - Add a new field called `Order` (range from 1 to 100) to `EVM.Nodes` that is used for the `PriorityLevel` node selector and also as a tie-breaker for `HighestHead` and `TotalDifficulty`. `Order` levels are considered in ascending order. If not defined it will default to `Order = 100` (last level). - Added new node selection mode called `PriorityLevel` for EVM, it is a tiered round-robin in ascending order of the`Order` field. Example: From a0ec6a526426c0597bc2c5b5ed0cb5ab99d2dc3b Mon Sep 17 00:00:00 2001 From: David Cauchi <13139524+davidcauchi@users.noreply.github.com> Date: Thu, 20 Jul 2023 22:48:20 +0200 Subject: [PATCH 02/15] Add base config (#9865) * Add base config * Updated Docs * Base goerli config to match Optimism goerli --------- Co-authored-by: simsonraj (cherry picked from commit ee724fc32951f2c8f7f234695afc4dbf0591eeea) --- .../evm/config/v2/defaults/Base_Goerli.toml | 26 +++ .../evm/config/v2/defaults/Base_Mainnet.toml | 26 +++ docs/CONFIG.md | 156 ++++++++++++++++++ 3 files changed, 208 insertions(+) create mode 100644 core/chains/evm/config/v2/defaults/Base_Goerli.toml create mode 100644 core/chains/evm/config/v2/defaults/Base_Mainnet.toml diff --git a/core/chains/evm/config/v2/defaults/Base_Goerli.toml b/core/chains/evm/config/v2/defaults/Base_Goerli.toml new file mode 100644 index 00000000000..2a9c59173c1 --- /dev/null +++ b/core/chains/evm/config/v2/defaults/Base_Goerli.toml @@ -0,0 +1,26 @@ +ChainID = '84531' +ChainType = 'optimismBedrock' +FinalityDepth = 200 +LogPollInterval = '2s' +NoNewHeadsThreshold = '40s' +MinIncomingConfirmations = 1 + +[GasEstimator] +EIP1559DynamicFees = true +PriceMin = '1 wei' +BumpMin = '100 wei' + +[GasEstimator.BlockHistory] +BlockHistorySize = 60 + +[Transactions] +ResendAfterThreshold = '30s' + +[HeadTracker] +HistoryDepth = 300 + +[NodePool] +SyncThreshold = 10 + +[OCR] +ContractConfirmations = 1 \ No newline at end of file diff --git a/core/chains/evm/config/v2/defaults/Base_Mainnet.toml b/core/chains/evm/config/v2/defaults/Base_Mainnet.toml new file mode 100644 index 00000000000..5455ad22c12 --- /dev/null +++ b/core/chains/evm/config/v2/defaults/Base_Mainnet.toml @@ -0,0 +1,26 @@ +ChainID = '8453' +ChainType = 'optimismBedrock' +FinalityDepth = 200 +LogPollInterval = '2s' +NoNewHeadsThreshold = '40s' +MinIncomingConfirmations = 1 + +[GasEstimator] +EIP1559DynamicFees = true +PriceMin = '1 wei' +BumpMin = '100 wei' + +[GasEstimator.BlockHistory] +BlockHistorySize = 24 + +[Transactions] +ResendAfterThreshold = '30s' + +[HeadTracker] +HistoryDepth = 300 + +[NodePool] +SyncThreshold = 10 + +[OCR] +ContractConfirmations = 1 \ No newline at end of file diff --git a/docs/CONFIG.md b/docs/CONFIG.md index b817ddd143e..fdbf92fed45 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -3119,6 +3119,84 @@ GasLimit = 5300000

+
Base Mainnet (8453)

+ +```toml +AutoCreateKey = true +BlockBackfillDepth = 10 +BlockBackfillSkip = false +ChainType = 'optimismBedrock' +FinalityDepth = 200 +FinalityTagEnabled = false +LogBackfillBatchSize = 1000 +LogPollInterval = '2s' +LogKeepBlocksDepth = 100000 +MinIncomingConfirmations = 1 +MinContractPayment = '0.00001 link' +NonceAutoSync = true +NoNewHeadsThreshold = '40s' +RPCDefaultBatchSize = 250 +RPCBlockQueryDelay = 1 + +[Transactions] +ForwardersEnabled = false +MaxInFlight = 16 +MaxQueued = 250 +ReaperInterval = '1h0m0s' +ReaperThreshold = '168h0m0s' +ResendAfterThreshold = '30s' + +[BalanceMonitor] +Enabled = true + +[GasEstimator] +Mode = 'BlockHistory' +PriceDefault = '20 gwei' +PriceMax = '115792089237316195423570985008687907853269984665.640564039457584007913129639935 tether' +PriceMin = '1 wei' +LimitDefault = 500000 +LimitMax = 500000 +LimitMultiplier = '1' +LimitTransfer = 21000 +BumpMin = '100 wei' +BumpPercent = 20 +BumpThreshold = 3 +EIP1559DynamicFees = true +FeeCapDefault = '100 gwei' +TipCapDefault = '1 wei' +TipCapMin = '1 wei' + +[GasEstimator.BlockHistory] +BatchSize = 25 +BlockHistorySize = 24 +CheckInclusionBlocks = 12 +CheckInclusionPercentile = 90 +TransactionPercentile = 60 + +[HeadTracker] +HistoryDepth = 300 +MaxBufferSize = 3 +SamplingInterval = '1s' + +[NodePool] +PollFailureThreshold = 5 +PollInterval = '10s' +SelectionMode = 'HighestHead' +SyncThreshold = 10 + +[OCR] +ContractConfirmations = 1 +ContractTransmitterTransmitTimeout = '10s' +DatabaseTimeout = '10s' +ObservationGracePeriod = '1s' + +[OCR2] +[OCR2.Automation] +GasLimit = 5300000 +``` + +

+
Arbitrum Mainnet (42161)

```toml @@ -3582,6 +3660,84 @@ GasLimit = 5300000

+
Base Goerli (84531)

+ +```toml +AutoCreateKey = true +BlockBackfillDepth = 10 +BlockBackfillSkip = false +ChainType = 'optimismBedrock' +FinalityDepth = 200 +FinalityTagEnabled = false +LogBackfillBatchSize = 1000 +LogPollInterval = '2s' +LogKeepBlocksDepth = 100000 +MinIncomingConfirmations = 1 +MinContractPayment = '0.00001 link' +NonceAutoSync = true +NoNewHeadsThreshold = '40s' +RPCDefaultBatchSize = 250 +RPCBlockQueryDelay = 1 + +[Transactions] +ForwardersEnabled = false +MaxInFlight = 16 +MaxQueued = 250 +ReaperInterval = '1h0m0s' +ReaperThreshold = '168h0m0s' +ResendAfterThreshold = '30s' + +[BalanceMonitor] +Enabled = true + +[GasEstimator] +Mode = 'BlockHistory' +PriceDefault = '20 gwei' +PriceMax = '115792089237316195423570985008687907853269984665.640564039457584007913129639935 tether' +PriceMin = '1 wei' +LimitDefault = 500000 +LimitMax = 500000 +LimitMultiplier = '1' +LimitTransfer = 21000 +BumpMin = '100 wei' +BumpPercent = 20 +BumpThreshold = 3 +EIP1559DynamicFees = true +FeeCapDefault = '100 gwei' +TipCapDefault = '1 wei' +TipCapMin = '1 wei' + +[GasEstimator.BlockHistory] +BatchSize = 25 +BlockHistorySize = 60 +CheckInclusionBlocks = 12 +CheckInclusionPercentile = 90 +TransactionPercentile = 60 + +[HeadTracker] +HistoryDepth = 300 +MaxBufferSize = 3 +SamplingInterval = '1s' + +[NodePool] +PollFailureThreshold = 5 +PollInterval = '10s' +SelectionMode = 'HighestHead' +SyncThreshold = 10 + +[OCR] +ContractConfirmations = 1 +ContractTransmitterTransmitTimeout = '10s' +DatabaseTimeout = '10s' +ObservationGracePeriod = '1s' + +[OCR2] +[OCR2.Automation] +GasLimit = 5300000 +``` + +

+
Arbitrum Rinkeby (421611)

```toml From 932b20c98f94208bebbc9c3558a39b80a351fe8c Mon Sep 17 00:00:00 2001 From: Simson Date: Fri, 21 Jul 2023 02:03:57 -0400 Subject: [PATCH 03/15] Base(Mainnet) + Optimism hotfix (#9862) * Base(Mainnet) + Optimism hotfix * Revert "Base(Mainnet) + Optimism hotfix" This reverts commit a13e8487eff0935b3eacf78bc020288842028c96. * Base+ optimism hotfix for non-successfull ocr rounds * fix tests (cherry picked from commit 38e9e4a0ba0e19e6a87a258e10c850921f2301c9) --- core/services/ocr/contract_tracker.go | 2 +- core/services/ocr/contract_tracker_test.go | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/core/services/ocr/contract_tracker.go b/core/services/ocr/contract_tracker.go index cd04fc97ee7..671f6b8cfad 100644 --- a/core/services/ocr/contract_tracker.go +++ b/core/services/ocr/contract_tracker.go @@ -388,7 +388,7 @@ func (t *OCRContractTracker) ConfigFromLogs(ctx context.Context, changedInBlock // LatestBlockHeight queries the eth node for the most recent header func (t *OCRContractTracker) LatestBlockHeight(ctx context.Context) (blockheight uint64, err error) { switch t.cfg.ChainType() { - case config.ChainMetis, config.ChainOptimismBedrock: + case config.ChainMetis: // We skip confirmation checking anyway on these L2s so there's no need to // care about the block height; we have no way of getting the L1 block // height anyway diff --git a/core/services/ocr/contract_tracker_test.go b/core/services/ocr/contract_tracker_test.go index d3646b30f16..33561a53023 100644 --- a/core/services/ocr/contract_tracker_test.go +++ b/core/services/ocr/contract_tracker_test.go @@ -24,7 +24,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" configtest "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest/v2" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" - v2 "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest/v2" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/ocr" @@ -107,14 +106,6 @@ func newContractTrackerUni(t *testing.T, opts ...interface{}) (uni contractTrack func Test_OCRContractTracker_LatestBlockHeight(t *testing.T) { t.Parallel() - t.Run("on L2 chains, always returns 0", func(t *testing.T) { - uni := newContractTrackerUni(t, v2.ChainOptimismMainnet(t)) - l, err := uni.tracker.LatestBlockHeight(testutils.Context(t)) - require.NoError(t, err) - - assert.Equal(t, uint64(0), l) - }) - t.Run("before first head incoming, looks up on-chain", func(t *testing.T) { uni := newContractTrackerUni(t) uni.ec.On("HeadByNumber", mock.AnythingOfType("*context.cancelCtx"), (*big.Int)(nil)).Return(&evmtypes.Head{Number: 42}, nil) From 2e251f8cc4b4d3ac345c1c9c70bc28596277bd0a Mon Sep 17 00:00:00 2001 From: Simson Date: Fri, 21 Jul 2023 03:37:58 -0400 Subject: [PATCH 04/15] Added automation gaslimit for Base (#9878) (cherry picked from commit 22a60fbcad22367cca4d1ec7604b169e3a38108f) --- core/chains/evm/config/v2/defaults/Base_Goerli.toml | 5 ++++- core/chains/evm/config/v2/defaults/Base_Mainnet.toml | 5 ++++- docs/CONFIG.md | 4 ++-- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/core/chains/evm/config/v2/defaults/Base_Goerli.toml b/core/chains/evm/config/v2/defaults/Base_Goerli.toml index 2a9c59173c1..5ecfd036f46 100644 --- a/core/chains/evm/config/v2/defaults/Base_Goerli.toml +++ b/core/chains/evm/config/v2/defaults/Base_Goerli.toml @@ -23,4 +23,7 @@ HistoryDepth = 300 SyncThreshold = 10 [OCR] -ContractConfirmations = 1 \ No newline at end of file +ContractConfirmations = 1 + +[OCR2.Automation] +GasLimit = 6500000 diff --git a/core/chains/evm/config/v2/defaults/Base_Mainnet.toml b/core/chains/evm/config/v2/defaults/Base_Mainnet.toml index 5455ad22c12..314c12f8c54 100644 --- a/core/chains/evm/config/v2/defaults/Base_Mainnet.toml +++ b/core/chains/evm/config/v2/defaults/Base_Mainnet.toml @@ -23,4 +23,7 @@ HistoryDepth = 300 SyncThreshold = 10 [OCR] -ContractConfirmations = 1 \ No newline at end of file +ContractConfirmations = 1 + +[OCR2.Automation] +GasLimit = 6500000 diff --git a/docs/CONFIG.md b/docs/CONFIG.md index fdbf92fed45..ea512078c3e 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -3192,7 +3192,7 @@ ObservationGracePeriod = '1s' [OCR2] [OCR2.Automation] -GasLimit = 5300000 +GasLimit = 6500000 ```

@@ -3733,7 +3733,7 @@ ObservationGracePeriod = '1s' [OCR2] [OCR2.Automation] -GasLimit = 5300000 +GasLimit = 6500000 ```

From 42c4be6cef1a24f389154a528a481210ce10f2c1 Mon Sep 17 00:00:00 2001 From: simsonraj Date: Fri, 21 Jul 2023 20:05:22 +0530 Subject: [PATCH 05/15] re run config docs generate --- docs/CONFIG.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/docs/CONFIG.md b/docs/CONFIG.md index ea512078c3e..9cc91c91e58 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -3127,7 +3127,6 @@ BlockBackfillDepth = 10 BlockBackfillSkip = false ChainType = 'optimismBedrock' FinalityDepth = 200 -FinalityTagEnabled = false LogBackfillBatchSize = 1000 LogPollInterval = '2s' LogKeepBlocksDepth = 100000 @@ -3668,7 +3667,6 @@ BlockBackfillDepth = 10 BlockBackfillSkip = false ChainType = 'optimismBedrock' FinalityDepth = 200 -FinalityTagEnabled = false LogBackfillBatchSize = 1000 LogPollInterval = '2s' LogKeepBlocksDepth = 100000 From d0c54ead97a07a9759d9a51736c219c2c6a18681 Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Wed, 26 Jul 2023 10:46:58 -0400 Subject: [PATCH 06/15] Bump version and update CHANGELOG for core v2.4.0 --- VERSION | 2 +- docs/CHANGELOG.md | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 276cbf9e285..197c4d5c2d7 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2.3.0 +2.4.0 diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 615eaa4ab45..38ec4d263d7 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,6 +9,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] +... + +## 2.4.0 - UNRELEASED ### Fixed - Updated `v2/keys/evm` and `v2/keys/eth` routes to return 400 and 404 status codes where appropriate. Previously 500s were returned when requested resources were not found or client requests could not be parsed. From e6ebf1766958f3c63651f729cb17a00018868498 Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Fri, 28 Jul 2023 10:49:17 -0400 Subject: [PATCH 07/15] Finalize date on changelog for 2.3.0 --- docs/CHANGELOG.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index d347297fb61..b59e51c8859 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -11,7 +11,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ... -## 2.3.0 - UNRELEASED + + +## 2.3.0 - 2023-07-28 ### Added - Add a new field called `Order` (range from 1 to 100) to `EVM.Nodes` that is used for the `PriorityLevel` node selector and also as a tie-breaker for `HighestHead` and `TotalDifficulty`. `Order` levels are considered in ascending order. If not defined it will default to `Order = 100` (last level). @@ -66,8 +68,6 @@ Node operators may wish to add alerting based around these metrics. - Legacy chain types Optimism and Optimism2. OptimismBedrock is now used to handle Optimism's special cases. - Optimism Kovan configurations along with legacy error messages. - - # 2.2.0 - 2023-06-12 ### Added From f47eb347cd87a8aacde76789233a83f02739a3c9 Mon Sep 17 00:00:00 2001 From: Patrick Date: Tue, 8 Aug 2023 16:23:16 -0400 Subject: [PATCH 08/15] fix/changelog-simple-passwords: adding notification for upcoming breaking change wrt simple passwords in 2.5 (#10110) (cherry picked from commit 33f4e1a852da99f3a58f2b834533c495d095f874) --- docs/CHANGELOG.md | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 38ec4d263d7..d07d2f49e1e 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -18,7 +18,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added - Added the ability to specify and merge fields from multiple secrets files. Overrides of fields and keys are not allowed. -## 2.3.0 - UNRELEASED +### Upcoming Breaking Change +- Starting in 2.5.0, chainlink nodes will no longer allow insecure configuration for production builds. Any TOML configuration that sets the following line will fail validation checks in `node start` or `node validate`: +``` +AllowSimplePasswords=true +``` +- To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to RFC 3986 for special character escape rules. + + + +## 2.3.0 - 2023-07-28 ### Added - Add a new field called `Order` (range from 1 to 100) to `EVM.Nodes` that is used for the `PriorityLevel` node selector and also as a tie-breaker for `HighestHead` and `TotalDifficulty`. `Order` levels are considered in ascending order. If not defined it will default to `Order = 100` (last level). From 6329455b1083cfa97d1c4d06cb869690d2ea021e Mon Sep 17 00:00:00 2001 From: patrickhuie19 Date: Fri, 11 Aug 2023 11:36:15 -0400 Subject: [PATCH 09/15] feature/simple-passwords-log: adding notification for upcoming configuration change error logs for insecure configs on secure builds --- core/cmd/shell.go | 12 +++++++++--- core/cmd/shell_local.go | 10 ++++++++-- 2 files changed, 17 insertions(+), 5 deletions(-) diff --git a/core/cmd/shell.go b/core/cmd/shell.go index 514450ad99c..42ede9b39ed 100644 --- a/core/cmd/shell.go +++ b/core/cmd/shell.go @@ -116,9 +116,15 @@ func (s *Shell) errorOut(err error) cli.ExitCoder { func (s *Shell) configExitErr(validateFn func() error) cli.ExitCoder { err := validateFn() if err != nil { - fmt.Println("Invalid configuration:", err) - fmt.Println() - return s.errorOut(errors.New("invalid configuration")) + if err.Error() != "invalid secrets: Database.AllowSimplePasswords: invalid value (true): insecure configs are not allowed on secure builds" { + fmt.Println("Invalid configuration:", err) + fmt.Println() + return s.errorOut(errors.New("invalid configuration")) + } else { + fmt.Printf("Notification for upcoming configuration change: %v\n", err) + fmt.Println("This configuration will be disallowed in future production releases.") + fmt.Println() + } } return nil } diff --git a/core/cmd/shell_local.go b/core/cmd/shell_local.go index 4e0b97c894f..8323bbfbdc3 100644 --- a/core/cmd/shell_local.go +++ b/core/cmd/shell_local.go @@ -294,7 +294,10 @@ func (s *Shell) runNode(c *cli.Context) error { err := s.Config.Validate() if err != nil { - return errors.Wrap(err, "config validation failed") + if err.Error() != "invalid secrets: Database.AllowSimplePasswords: invalid value (true): insecure configs are not allowed on secure builds" { + return errors.Wrap(err, "config validation failed") + } + lggr.Errorf("Notification for upcoming configuration change: %v", err) } lggr.Infow(fmt.Sprintf("Starting Chainlink Node %s at commit %s", static.Version, static.Sha), "Version", static.Version, "SHA", static.Sha) @@ -627,7 +630,10 @@ func (s *Shell) RebroadcastTransactions(c *cli.Context) (err error) { err = s.Config.Validate() if err != nil { - return s.errorOut(fmt.Errorf("error validating configuration: %+v", err)) + if err.Error() != "invalid secrets: Database.AllowSimplePasswords: invalid value (true): insecure configs are not allowed on secure builds" { + return s.errorOut(fmt.Errorf("error validating configuration: %+v", err)) + } + lggr.Errorf("Notification for required upcoming configuration change: %v", err) } err = keyStore.Unlock(s.Config.Password().Keystore()) From 0eb4542630105e98d9e4f77a813d0ef4a1ecaf79 Mon Sep 17 00:00:00 2001 From: Patrick Date: Tue, 15 Aug 2023 09:26:41 -0400 Subject: [PATCH 10/15] release/2.4.0-fix: updating CHANGELOG for simple passwords entry comments (#10165) --- docs/CHANGELOG.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index d07d2f49e1e..7c995a64a60 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -18,12 +18,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added - Added the ability to specify and merge fields from multiple secrets files. Overrides of fields and keys are not allowed. -### Upcoming Breaking Change -- Starting in 2.5.0, chainlink nodes will no longer allow insecure configuration for production builds. Any TOML configuration that sets the following line will fail validation checks in `node start` or `node validate`: +### Upcoming Required Configuration Change +- Starting in 2.6.0, chainlink nodes will no longer allow insecure configuration for production builds. Any TOML configuration that sets the following line will fail validation checks in `node start` or `node validate`: ``` AllowSimplePasswords=true ``` -- To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to RFC 3986 for special character escape rules. +- To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986) for special character escape rules. From bd2c6d7c621aaae9e6b0a14833d30eb2f9d7f120 Mon Sep 17 00:00:00 2001 From: Aaron Lu <50029043+aalu1418@users.noreply.github.com> Date: Wed, 16 Aug 2023 12:46:14 -0600 Subject: [PATCH 11/15] add evm transfer validation for eip1559 (#10196) * add transfer validation for eip1559 * evm-transfer-eip1559-validation-proposal - adding TxAmountWithFees to WrappedEvmEstimator * small renaming + fix mocks * fix dynamic fee + remove unnecessary check * rename GetCost -> GetMaxCost * address cleanup items + add test case for GetMaxCost --------- Co-authored-by: patrickhuie19 --- .../chains/evm/gas/mocks/evm_fee_estimator.go | 37 ++++++++++++++- core/chains/evm/gas/models.go | 21 +++++++++ core/chains/evm/gas/models_test.go | 27 +++++++++-- core/web/evm_transfer_controller.go | 18 +------- core/web/evm_transfer_controller_test.go | 45 +++++++++++++++++++ 5 files changed, 128 insertions(+), 20 deletions(-) diff --git a/core/chains/evm/gas/mocks/evm_fee_estimator.go b/core/chains/evm/gas/mocks/evm_fee_estimator.go index 67eed66a529..20e6c940f7e 100644 --- a/core/chains/evm/gas/mocks/evm_fee_estimator.go +++ b/core/chains/evm/gas/mocks/evm_fee_estimator.go @@ -3,10 +3,12 @@ package mocks import ( - context "context" + big "math/big" assets "github.com/smartcontractkit/chainlink/v2/core/assets" + context "context" + evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" gas "github.com/smartcontractkit/chainlink/v2/core/chains/evm/gas" @@ -104,6 +106,39 @@ func (_m *EvmFeeEstimator) GetFee(ctx context.Context, calldata []byte, feeLimit return r0, r1, r2 } +// GetMaxCost provides a mock function with given fields: ctx, amount, calldata, feeLimit, maxFeePrice, opts +func (_m *EvmFeeEstimator) GetMaxCost(ctx context.Context, amount assets.Eth, calldata []byte, feeLimit uint32, maxFeePrice *assets.Wei, opts ...types.Opt) (*big.Int, error) { + _va := make([]interface{}, len(opts)) + for _i := range opts { + _va[_i] = opts[_i] + } + var _ca []interface{} + _ca = append(_ca, ctx, amount, calldata, feeLimit, maxFeePrice) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) + + var r0 *big.Int + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, assets.Eth, []byte, uint32, *assets.Wei, ...types.Opt) (*big.Int, error)); ok { + return rf(ctx, amount, calldata, feeLimit, maxFeePrice, opts...) + } + if rf, ok := ret.Get(0).(func(context.Context, assets.Eth, []byte, uint32, *assets.Wei, ...types.Opt) *big.Int); ok { + r0 = rf(ctx, amount, calldata, feeLimit, maxFeePrice, opts...) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*big.Int) + } + } + + if rf, ok := ret.Get(1).(func(context.Context, assets.Eth, []byte, uint32, *assets.Wei, ...types.Opt) error); ok { + r1 = rf(ctx, amount, calldata, feeLimit, maxFeePrice, opts...) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // HealthReport provides a mock function with given fields: func (_m *EvmFeeEstimator) HealthReport() map[string]error { ret := _m.Called() diff --git a/core/chains/evm/gas/models.go b/core/chains/evm/gas/models.go index 7c0571c897d..a9cbc0a924a 100644 --- a/core/chains/evm/gas/models.go +++ b/core/chains/evm/gas/models.go @@ -41,6 +41,9 @@ type EvmFeeEstimator interface { GetFee(ctx context.Context, calldata []byte, feeLimit uint32, maxFeePrice *assets.Wei, opts ...feetypes.Opt) (fee EvmFee, chainSpecificFeeLimit uint32, err error) BumpFee(ctx context.Context, originalFee EvmFee, feeLimit uint32, maxFeePrice *assets.Wei, attempts []EvmPriorAttempt) (bumpedFee EvmFee, chainSpecificFeeLimit uint32, err error) + + // GetMaxCost returns the total value = max price x fee units + transferred value + GetMaxCost(ctx context.Context, amount assets.Eth, calldata []byte, feeLimit uint32, maxFeePrice *assets.Wei, opts ...feetypes.Opt) (*big.Int, error) } // NewEstimator returns the estimator for a given config @@ -173,6 +176,24 @@ func (e WrappedEvmEstimator) GetFee(ctx context.Context, calldata []byte, feeLim return } +func (e WrappedEvmEstimator) GetMaxCost(ctx context.Context, amount assets.Eth, calldata []byte, feeLimit uint32, maxFeePrice *assets.Wei, opts ...feetypes.Opt) (*big.Int, error) { + fees, gasLimit, err := e.GetFee(ctx, calldata, feeLimit, maxFeePrice, opts...) + if err != nil { + return nil, err + } + + var gasPrice *assets.Wei + if e.EIP1559Enabled { + gasPrice = fees.DynamicFeeCap + } else { + gasPrice = fees.Legacy + } + + fee := new(big.Int).Mul(gasPrice.ToInt(), big.NewInt(int64(gasLimit))) + amountWithFees := new(big.Int).Add(amount.ToInt(), fee) + return amountWithFees, nil +} + func (e WrappedEvmEstimator) BumpFee(ctx context.Context, originalFee EvmFee, feeLimit uint32, maxFeePrice *assets.Wei, attempts []EvmPriorAttempt) (bumpedFee EvmFee, chainSpecificFeeLimit uint32, err error) { // validate only 1 fee type is present if (!originalFee.ValidDynamic() && originalFee.Legacy == nil) || (originalFee.ValidDynamic() && originalFee.Legacy != nil) { diff --git a/core/chains/evm/gas/models_test.go b/core/chains/evm/gas/models_test.go index 3e793d27348..048646a980c 100644 --- a/core/chains/evm/gas/models_test.go +++ b/core/chains/evm/gas/models_test.go @@ -2,6 +2,7 @@ package gas_test import ( "context" + "math/big" "testing" "github.com/stretchr/testify/assert" @@ -22,14 +23,14 @@ func TestWrappedEvmEstimator(t *testing.T) { legacyFee := assets.NewWeiI(10) dynamicFee := gas.DynamicFee{ FeeCap: assets.NewWeiI(20), - TipCap: assets.NewWeiI(21), + TipCap: assets.NewWeiI(1), } e := mocks.NewEvmEstimator(t) e.On("GetDynamicFee", mock.Anything, mock.Anything, mock.Anything). - Return(dynamicFee, gasLimit, nil).Once() + Return(dynamicFee, gasLimit, nil).Twice() e.On("GetLegacyGas", mock.Anything, mock.Anything, mock.Anything, mock.Anything). - Return(legacyFee, gasLimit, nil).Once() + Return(legacyFee, gasLimit, nil).Twice() e.On("BumpDynamicFee", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything). Return(dynamicFee, gasLimit, nil).Once() e.On("BumpLegacyGas", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything). @@ -92,4 +93,24 @@ func TestWrappedEvmEstimator(t *testing.T) { }, 0, nil, nil) assert.Error(t, err) }) + + t.Run("GetMaxCost", func(t *testing.T) { + val := assets.NewEthValue(1) + + // expect legacy fee data + dynamicFees := false + estimator := gas.NewWrappedEvmEstimator(e, dynamicFees) + total, err := estimator.GetMaxCost(ctx, val, nil, gasLimit, nil) + require.NoError(t, err) + fee := new(big.Int).Mul(legacyFee.ToInt(), big.NewInt(int64(gasLimit))) + assert.Equal(t, new(big.Int).Add(val.ToInt(), fee), total) + + // expect dynamic fee data + dynamicFees = true + estimator = gas.NewWrappedEvmEstimator(e, dynamicFees) + total, err = estimator.GetMaxCost(ctx, val, nil, gasLimit, nil) + require.NoError(t, err) + fee = new(big.Int).Mul(dynamicFee.FeeCap.ToInt(), big.NewInt(int64(gasLimit))) + assert.Equal(t, new(big.Int).Add(val.ToInt(), fee), total) + }) } diff --git a/core/web/evm_transfer_controller.go b/core/web/evm_transfer_controller.go index 7e7df04160c..e5ceded58d4 100644 --- a/core/web/evm_transfer_controller.go +++ b/core/web/evm_transfer_controller.go @@ -9,7 +9,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/assets" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/gas" "github.com/smartcontractkit/chainlink/v2/core/logger/audit" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/store/models" @@ -94,26 +93,13 @@ func ValidateEthBalanceForTransfer(c *gin.Context, chain evm.Chain, fromAddr com return errors.Errorf("balance is too low for this transaction to be executed: %v", balance) } - var fees gas.EvmFee - gasLimit := chain.Config().EVM().GasEstimator().LimitTransfer() estimator := chain.GasEstimator() - fees, gasLimit, err = estimator.GetFee(c, nil, gasLimit, chain.Config().EVM().GasEstimator().PriceMaxKey(fromAddr)) + amountWithFees, err := estimator.GetMaxCost(c, amount, nil, gasLimit, chain.Config().EVM().GasEstimator().PriceMaxKey(fromAddr)) if err != nil { - return errors.Wrap(err, "failed to estimate gas") - } - - // TODO: support EIP-1559 transactions - if fees.Legacy == nil { - return errors.New("estimator did not return legacy tx fee estimates") + return err } - gasPrice := fees.Legacy - - // Creating a `Big` struct to avoid having a mutation on `tr.Amount` and hence affecting the value stored in the DB - amountAsBig := utils.NewBig(amount.ToInt()) - fee := new(big.Int).Mul(gasPrice.ToInt(), big.NewInt(int64(gasLimit))) - amountWithFees := new(big.Int).Add(amountAsBig.ToInt(), fee) if balance.Cmp(amountWithFees) < 0 { // ETH balance is less than the sent amount + fees return errors.Errorf("balance is too low for this transaction to be executed: %v", balance) diff --git a/core/web/evm_transfer_controller_test.go b/core/web/evm_transfer_controller_test.go index ce4e8c5172f..c58b810e67c 100644 --- a/core/web/evm_transfer_controller_test.go +++ b/core/web/evm_transfer_controller_test.go @@ -252,3 +252,48 @@ func TestTransfersController_JSONBindingError(t *testing.T) { cltest.AssertServerResponse(t, resp, http.StatusBadRequest) } + +func TestTransfersController_CreateSuccess_eip1559(t *testing.T) { + t.Parallel() + + key := cltest.MustGenerateRandomKey(t) + + ethClient := cltest.NewEthMocksWithTransactionsOnBlocksAssertions(t) + + balance, err := assets.NewEthValueS("200") + require.NoError(t, err) + + ethClient.On("PendingNonceAt", mock.Anything, key.Address).Return(uint64(1), nil) + ethClient.On("BalanceAt", mock.Anything, key.Address, (*big.Int)(nil)).Return(balance.ToInt(), nil) + + config := configtest2.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { + c.EVM[0].GasEstimator.EIP1559DynamicFees = ptr(true) + c.EVM[0].GasEstimator.Mode = ptr("FixedPrice") + }) + + app := cltest.NewApplicationWithConfigAndKey(t, config, ethClient, key) + require.NoError(t, app.Start(testutils.Context(t))) + + client := app.NewHTTPClient(cltest.APIEmailAdmin) + + amount, err := assets.NewEthValueS("100") + require.NoError(t, err) + + request := models.SendEtherRequest{ + DestinationAddress: common.HexToAddress("0xFA01FA015C8A5332987319823728982379128371"), + FromAddress: key.Address, + Amount: amount, + } + + body, err := json.Marshal(&request) + assert.NoError(t, err) + + resp, cleanup := client.Post("/v2/transfers", bytes.NewBuffer(body)) + t.Cleanup(cleanup) + + errors := cltest.ParseJSONAPIErrors(t, resp.Body) + assert.Equal(t, http.StatusOK, resp.StatusCode) + assert.Len(t, errors.Errors, 0) + + cltest.AssertCount(t, app.GetSqlxDB(), "eth_txes", 1) +} From 3ceda48d7fa885cd32e7b3f508a1b84e830086c8 Mon Sep 17 00:00:00 2001 From: Aaron Lu <50029043+aalu1418@users.noreply.github.com> Date: Wed, 16 Aug 2023 15:57:10 -0600 Subject: [PATCH 12/15] add changelog for fix in #10196 (#10235) * add changelog for fix in #10196 * specify which flag for overriding in changelog --- docs/CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 7c995a64a60..5746682f930 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -14,6 +14,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## 2.4.0 - UNRELEASED ### Fixed - Updated `v2/keys/evm` and `v2/keys/eth` routes to return 400 and 404 status codes where appropriate. Previously 500s were returned when requested resources were not found or client requests could not be parsed. +- Fixed withdrawing ETH from CL node for EIP1559 enabled chains. Previously would error out unless validation was overridden with `allowHigherAmounts`. ### Added - Added the ability to specify and merge fields from multiple secrets files. Overrides of fields and keys are not allowed. From a76c31cf1058ca014c3bf58cf228accf14dcb9fe Mon Sep 17 00:00:00 2001 From: Patrick Date: Mon, 7 Aug 2023 12:11:47 -0400 Subject: [PATCH 13/15] bug/2326-simple-passwords: re-enabling simple passwords restriction for prod (#10021) * bug/2326-simple-passwords: re-enabling simple passwords restriction for prod * strong password for tests --------- Co-authored-by: skudasov --- core/config/toml/types.go | 2 + core/config/toml/types_test.go | 77 ++++++++++++++++++++++++++++++++++ docs/CHANGELOG.md | 3 +- 3 files changed, 81 insertions(+), 1 deletion(-) diff --git a/core/config/toml/types.go b/core/config/toml/types.go index e4dd190d9a5..471d444339c 100644 --- a/core/config/toml/types.go +++ b/core/config/toml/types.go @@ -148,6 +148,8 @@ func validateDBURL(dbURI url.URL) error { func (d *DatabaseSecrets) ValidateConfig() (err error) { if d.URL == nil || (*url.URL)(d.URL).String() == "" { err = multierr.Append(err, configutils.ErrEmpty{Name: "URL", Msg: "must be provided and non-empty"}) + } else if *d.AllowSimplePasswords && build.IsProd() { + err = multierr.Append(err, configutils.ErrInvalid{Name: "AllowSimplePasswords", Value: true, Msg: "insecure configs are not allowed on secure builds"}) } else if !*d.AllowSimplePasswords { if verr := validateDBURL((url.URL)(*d.URL)); verr != nil { err = multierr.Append(err, configutils.ErrInvalid{Name: "URL", Value: "*****", Msg: dbURLPasswordComplexity(verr)}) diff --git a/core/config/toml/types_test.go b/core/config/toml/types_test.go index a85138c91b3..e2eb5eed815 100644 --- a/core/config/toml/types_test.go +++ b/core/config/toml/types_test.go @@ -2,10 +2,13 @@ package toml import ( "fmt" + "net/url" + "strings" "testing" "github.com/stretchr/testify/assert" + "github.com/smartcontractkit/chainlink/v2/core/build" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -97,3 +100,77 @@ func Test_validateDBURL(t *testing.T) { }) } } + +func TestValidateConfig(t *testing.T) { + validUrl := models.URL(url.URL{Scheme: "https", Host: "localhost"}) + validSecretURL := *models.NewSecretURL(&validUrl) + + invalidEmptyUrl := models.URL(url.URL{}) + invalidEmptySecretURL := *models.NewSecretURL(&invalidEmptyUrl) + + invalidBackupURL := models.URL(url.URL{Scheme: "http", Host: "localhost"}) + invalidBackupSecretURL := *models.NewSecretURL(&invalidBackupURL) + + tests := []struct { + name string + input *DatabaseSecrets + skip bool + expectedErrContains []string + }{ + { + name: "Nil URL", + input: &DatabaseSecrets{ + URL: nil, + }, + expectedErrContains: []string{"URL: empty: must be provided and non-empty"}, + }, + { + name: "Empty URL", + input: &DatabaseSecrets{ + URL: &invalidEmptySecretURL, + }, + expectedErrContains: []string{"URL: empty: must be provided and non-empty"}, + }, + { + name: "Insecure Password in Production", + input: &DatabaseSecrets{ + URL: &validSecretURL, + AllowSimplePasswords: &[]bool{true}[0], + }, + skip: !build.IsProd(), + expectedErrContains: []string{"insecure configs are not allowed on secure builds"}, + }, + { + name: "Invalid Backup URL with Simple Passwords Not Allowed", + input: &DatabaseSecrets{ + URL: &validSecretURL, + BackupURL: &invalidBackupSecretURL, + AllowSimplePasswords: &[]bool{false}[0], + }, + expectedErrContains: []string{"missing or insufficiently complex password"}, + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + // needed while -tags test is supported + if tt.skip { + t.SkipNow() + } + err := tt.input.ValidateConfig() + if err == nil && len(tt.expectedErrContains) > 0 { + t.Errorf("expected errors but got none") + return + } + + if err != nil { + errStr := err.Error() + for _, expectedErrSubStr := range tt.expectedErrContains { + if !strings.Contains(errStr, expectedErrSubStr) { + t.Errorf("expected error to contain substring %q but got %v", expectedErrSubStr, errStr) + } + } + } + }) + } +} diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 5746682f930..0351648a50e 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,7 +9,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] -... +### Changed +- Simple passwords are no longer allowed for production builds ## 2.4.0 - UNRELEASED ### Fixed From 76fb85cba425dbfe229db82a9ad7b18265a44f8c Mon Sep 17 00:00:00 2001 From: patrickhuie19 Date: Thu, 17 Aug 2023 10:01:57 -0400 Subject: [PATCH 14/15] fixing changelog --- docs/CHANGELOG.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 0351648a50e..e938159a48d 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,8 +9,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] -### Changed -- Simple passwords are no longer allowed for production builds ## 2.4.0 - UNRELEASED ### Fixed From c0865c6dc3cf2e0435b8edd8201f8ce21e75c603 Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Mon, 21 Aug 2023 14:09:49 -0400 Subject: [PATCH 15/15] Finalize date on changelog for 2.4.0 --- docs/CHANGELOG.md | 42 +++++++++++++++++++++++++++--------------- 1 file changed, 27 insertions(+), 15 deletions(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index e938159a48d..5c53da2fee1 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,29 +9,36 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] + + +## 2.4.0 - 2023-08-21 -## 2.4.0 - UNRELEASED ### Fixed -- Updated `v2/keys/evm` and `v2/keys/eth` routes to return 400 and 404 status codes where appropriate. Previously 500s were returned when requested resources were not found or client requests could not be parsed. + +- Updated `v2/keys/evm` and `v2/keys/eth` routes to return 400 and 404 status codes where appropriate. Previously 500s were returned when requested resources were not found or client requests could not be parsed. - Fixed withdrawing ETH from CL node for EIP1559 enabled chains. Previously would error out unless validation was overridden with `allowHigherAmounts`. ### Added + - Added the ability to specify and merge fields from multiple secrets files. Overrides of fields and keys are not allowed. ### Upcoming Required Configuration Change + - Starting in 2.6.0, chainlink nodes will no longer allow insecure configuration for production builds. Any TOML configuration that sets the following line will fail validation checks in `node start` or `node validate`: + ``` AllowSimplePasswords=true ``` -- To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986) for special character escape rules. - +- To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986) for special character escape rules. ## 2.3.0 - 2023-07-28 ### Added + - Add a new field called `Order` (range from 1 to 100) to `EVM.Nodes` that is used for the `PriorityLevel` node selector and also as a tie-breaker for `HighestHead` and `TotalDifficulty`. `Order` levels are considered in ascending order. If not defined it will default to `Order = 100` (last level). - Added new node selection mode called `PriorityLevel` for EVM, it is a tiered round-robin in ascending order of the`Order` field. Example: + ``` [EVM.NodePool] SelectionMode = 'PriorityLevel' @@ -40,8 +47,9 @@ SelectionMode = 'PriorityLevel' Name = '...' WSURL = '...' HTTPURL = '...' -Order = 5 +Order = 5 ``` + - The config keys `WebServer.StartTimeout` and `WebServer.HTTPMaxSize`. These keys respectively set a timeout for the node server to start and set the max request size for HTTP requests. Previously these attributes were set by `JobPipeline.DefaultHTTPLimit`/`JobPipeline.DefaultHTTPTimeout`. To migrate to these new fields, set their values to be identical to @@ -60,18 +68,20 @@ Order = 5 - Add two new config parameters `WebServer.ListenIP` and `WebServer.TLS.ListenIP` which allows binding Chainlink HTTP/HTTPS servers to a particular IP. The default is '0.0.0.0' which listens to all IP addresses (same behavior as before). Set to '127.0.0.1' to only allow connections from the local machine (this can be handy for local development). - Add several new metrics for mercury feeds, related to WSRPC connections: - - `mercury_transmit_timeout_count` - - `mercury_dial_count` - - `mercury_dial_success_count` - - `mercury_dial_error_count` - - `mercury_connection_reset_count` + - `mercury_transmit_timeout_count` + - `mercury_dial_count` + - `mercury_dial_success_count` + - `mercury_dial_error_count` + - `mercury_connection_reset_count` Node operators may wish to add alerting based around these metrics. ### Fixed + - Fixed a bug in the `nodes xxx list` command that caused results to not be displayed correctly ### Changed + - Assumption violations for MaxFeePerGas >= BaseFeePerGas and MaxFeePerGas >= MaxPriorityFeePerGas in EIP-1559 effective gas price calculation will now use a gas price if specified - Config validation now enforces protection against duplicate chain ids and node fields per provided TOML file. Duplicates accross multiple configuration files are still valid. If you have specified duplicate chain ids or nodes in a given configuration file, this change will error out of all `node` subcommands. - Restricted scope of the `Evm.GasEstimator.LimitJobType.OCR`, `OCR.DefaultTransactionQueueDepth`, and `OCR.SimulateTransactions` settings so they @@ -79,6 +89,7 @@ Node operators may wish to add alerting based around these metrics. want your settings to apply to OCR2. ### Removed + - Legacy chain types Optimism and Optimism2. OptimismBedrock is now used to handle Optimism's special cases. - Optimism Kovan configurations along with legacy error messages. @@ -91,16 +102,18 @@ Node operators may wish to add alerting based around these metrics. - New prometheus metric for mercury transmit queue: `mercury_transmit_queue_load`. This is a gauge, scoped by feed ID, that measures how many pending transmissions are in the queue. This should generally speaking be small (< 10 or so). Nops may wish to add alerting if this exceeds some amount. - Experimental support of runtime process isolation for Solana data feeds. Requires plugin binaries to be installed and configured via the env vars `CL_SOLANA_CMD` and `CL_MEDIAN_CMD`. See [plugins/README.md](../plugins/README.md). + ### Fixed - Fixed a bug which made it impossible to re-send the same transaction after abandoning it while manually changing the nonce. ### Changed + - Set default for EVM.GasEstimator.BumpTxDepth to EVM.Transactions.MaxInFlight. - Bumped batch size defaults for EVM specific configuration. If you are overriding any of these fields in your local config, please consider if it is necessary: - - `LogBackfillBatchSize = 1000` - - `RPCDefaultBatchSize = 250` - - `GasEstimator.BatchSize = 25` + - `LogBackfillBatchSize = 1000` + - `RPCDefaultBatchSize = 250` + - `GasEstimator.BatchSize = 25` - Dropped support for Development Mode configuration. `CL_DEV` is now ignored on production builds. - Updated Docker image's PostgreSQL client (used for backups) to v15 in order to support PostgreSQL v15 servers. @@ -1871,8 +1884,7 @@ transactions that started hitting this limit and instead continue to resubmit at the highest price that worked. Node operators should check their geth nodes and remove this cap if configured, -you can do this by running your geth node with `--rpc.gascap=0 ---rpc.txfeecap=0` or setting these values in your config toml. +you can do this by running your geth node with `--rpc.gascap=0 --rpc.txfeecap=0` or setting these values in your config toml. - Make head backfill asynchronous. This should eliminate some harmless but annoying errors related to backfilling heads, logged on startup and