diff --git a/.changeset/wild-cats-think.md b/.changeset/wild-cats-think.md new file mode 100644 index 00000000000..f56f41b242c --- /dev/null +++ b/.changeset/wild-cats-think.md @@ -0,0 +1,5 @@ +--- +"chainlink": minor +--- + +Added the `EVM.Transactions.Enabled` config to enable or disable the transaction manager. #added diff --git a/core/chains/evm/config/chain_scoped_transactions.go b/core/chains/evm/config/chain_scoped_transactions.go index 27edb12648a..8cddce20e65 100644 --- a/core/chains/evm/config/chain_scoped_transactions.go +++ b/core/chains/evm/config/chain_scoped_transactions.go @@ -11,6 +11,10 @@ type transactionsConfig struct { c toml.Transactions } +func (t *transactionsConfig) Enabled() bool { + return *t.c.Enabled +} + func (t *transactionsConfig) ForwardersEnabled() bool { return *t.c.ForwardersEnabled } diff --git a/core/chains/evm/config/config.go b/core/chains/evm/config/config.go index f2a571f94b0..fbaf1ff6dda 100644 --- a/core/chains/evm/config/config.go +++ b/core/chains/evm/config/config.go @@ -103,6 +103,7 @@ type ClientErrors interface { } type Transactions interface { + Enabled() bool ForwardersEnabled() bool ReaperInterval() time.Duration ResendAfterThreshold() time.Duration diff --git a/core/chains/evm/config/config_test.go b/core/chains/evm/config/config_test.go index 7eb13458f56..ab0d600efe0 100644 --- a/core/chains/evm/config/config_test.go +++ b/core/chains/evm/config/config_test.go @@ -219,9 +219,20 @@ func TestChainScopedConfig(t *testing.T) { assert.Equal(t, false, cfg3.EVM().LogBroadcasterEnabled()) }) + }) + + t.Run("EVM.Transactions.Enabled", func(t *testing.T) { + t.Run("turn on EVM.Transactions.Enabled by default", func(t *testing.T) { + assert.True(t, cfg.EVM().Transactions().Enabled()) + }) - t.Run("use Noop logBroadcaster when LogBroadcaster is disabled", func(t *testing.T) { + t.Run("verify EVM.Transactions.Enabled is set correctly", func(t *testing.T) { + val := false + cfg3 := testutils.NewTestChainScopedConfig(t, func(c *toml.EVMConfig) { + c.Transactions.Enabled = ptr(val) + }) + assert.False(t, cfg3.EVM().Transactions().Enabled()) }) }) } diff --git a/core/chains/evm/config/toml/config.go b/core/chains/evm/config/toml/config.go index 0505449943e..807e1141791 100644 --- a/core/chains/evm/config/toml/config.go +++ b/core/chains/evm/config/toml/config.go @@ -472,6 +472,7 @@ func (c *Chain) ValidateConfig() (err error) { } type Transactions struct { + Enabled *bool ForwardersEnabled *bool MaxInFlight *uint32 MaxQueued *uint32 @@ -483,6 +484,9 @@ type Transactions struct { } func (t *Transactions) setFrom(f *Transactions) { + if v := f.Enabled; v != nil { + t.Enabled = v + } if v := f.ForwardersEnabled; v != nil { t.ForwardersEnabled = v } diff --git a/core/chains/evm/config/toml/defaults.go b/core/chains/evm/config/toml/defaults.go index 0885d94e6df..6f03575056b 100644 --- a/core/chains/evm/config/toml/defaults.go +++ b/core/chains/evm/config/toml/defaults.go @@ -236,7 +236,6 @@ func (c *Chain) SetFrom(f *Chain) { if v := f.FinalizedBlockOffset; v != nil { c.FinalizedBlockOffset = v } - if v := f.NoNewFinalizedHeadsThreshold; v != nil { c.NoNewFinalizedHeadsThreshold = v } diff --git a/core/chains/evm/config/toml/defaults/fallback.toml b/core/chains/evm/config/toml/defaults/fallback.toml index ab349ee4688..d2a6f0e4a2d 100644 --- a/core/chains/evm/config/toml/defaults/fallback.toml +++ b/core/chains/evm/config/toml/defaults/fallback.toml @@ -19,6 +19,7 @@ NoNewFinalizedHeadsThreshold = '0' LogBroadcasterEnabled = true [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 diff --git a/core/chains/legacyevm/chain.go b/core/chains/legacyevm/chain.go index d8eed88dedf..3e6aeef911c 100644 --- a/core/chains/legacyevm/chain.go +++ b/core/chains/legacyevm/chain.go @@ -194,10 +194,10 @@ func newChain(ctx context.Context, cfg *evmconfig.ChainScoped, nodes []*toml.Nod chainID := cfg.EVM().ChainID() l := opts.Logger var client evmclient.Client + var err error if !opts.AppConfig.EVMRPCEnabled() { client = evmclient.NewNullClient(chainID, l) } else if opts.GenEthClient == nil { - var err error client, err = evmclient.NewEvmClient(cfg.EVM().NodePool(), cfg.EVM(), cfg.EVM().NodePool().Errors(), l, chainID, nodes, cfg.EVM().ChainType()) if err != nil { return nil, err @@ -244,10 +244,24 @@ func newChain(ctx context.Context, cfg *evmconfig.ChainScoped, nodes []*toml.Nod } } - // note: gas estimator is started as a part of the txm - txm, gasEstimator, err := newEvmTxm(opts.DS, cfg.EVM(), opts.AppConfig.EVMRPCEnabled(), opts.AppConfig.Database(), opts.AppConfig.Database().Listener(), client, l, logPoller, opts, headTracker, clientsByChainID) + // initialize gas estimator + gasEstimator, err := newGasEstimator(cfg.EVM(), client, l, opts, clientsByChainID) if err != nil { - return nil, fmt.Errorf("failed to instantiate EvmTxm for chain with ID %s: %w", chainID.String(), err) + return nil, fmt.Errorf("failed to instantiate gas estimator for chain with ID %s: %w", chainID, err) + } + + // note: gas estimator is started as a part of the txm + var txm txmgr.TxManager + //nolint:gocritic // ignoring suggestion to convert to switch statement + if !opts.AppConfig.EVMRPCEnabled() { + txm = &txmgr.NullTxManager{ErrMsg: fmt.Sprintf("Ethereum is disabled for chain %d", chainID)} + } else if !cfg.EVM().Transactions().Enabled() { + txm = &txmgr.NullTxManager{ErrMsg: fmt.Sprintf("TXM disabled for chain %d", chainID)} + } else { + txm, err = newEvmTxm(opts.DS, cfg.EVM(), opts.AppConfig.Database(), opts.AppConfig.Database().Listener(), client, l, logPoller, opts, headTracker, gasEstimator) + if err != nil { + return nil, fmt.Errorf("failed to instantiate EvmTxm for chain with ID %s: %w", chainID, err) + } } headBroadcaster.Subscribe(txm) diff --git a/core/chains/legacyevm/evm_txm.go b/core/chains/legacyevm/evm_txm.go index 3a96a9da937..17dbce79e84 100644 --- a/core/chains/legacyevm/evm_txm.go +++ b/core/chains/legacyevm/evm_txm.go @@ -17,7 +17,6 @@ import ( func newEvmTxm( ds sqlutil.DataSource, cfg evmconfig.EVM, - evmRPCEnabled bool, databaseConfig txmgr.DatabaseConfig, listenerConfig txmgr.ListenerConfig, client evmclient.Client, @@ -25,16 +24,11 @@ func newEvmTxm( logPoller logpoller.LogPoller, opts ChainRelayOpts, headTracker httypes.HeadTracker, - clientsByChainID map[string]rollups.DAClient, -) (txm txmgr.TxManager, estimator gas.EvmFeeEstimator, +) (txm txmgr.TxManager, err error, ) { chainID := cfg.ChainID() - if !evmRPCEnabled { - txm = &txmgr.NullTxManager{ErrMsg: fmt.Sprintf("Ethereum is disabled for chain %d", chainID)} - return txm, nil, nil - } lggr = lggr.Named("Txm") lggr.Infow("Initializing EVM transaction manager", @@ -45,15 +39,6 @@ func newEvmTxm( "limitDefault", cfg.GasEstimator().LimitDefault(), ) - // build estimator from factory - if opts.GenGasEstimator == nil { - if estimator, err = gas.NewEstimator(lggr, client, cfg.ChainType(), chainID, cfg.GasEstimator(), clientsByChainID); err != nil { - return nil, nil, fmt.Errorf("failed to initialize estimator: %w", err) - } - } else { - estimator = opts.GenGasEstimator(chainID) - } - if opts.GenTxManager == nil { txm, err = txmgr.NewTxm( ds, @@ -74,3 +59,23 @@ func newEvmTxm( } return } + +func newGasEstimator( + cfg evmconfig.EVM, + client evmclient.Client, + lggr logger.Logger, + opts ChainRelayOpts, + clientsByChainID map[string]rollups.DAClient, +) (estimator gas.EvmFeeEstimator, err error) { + lggr = lggr.Named("Txm") + chainID := cfg.ChainID() + // build estimator from factory + if opts.GenGasEstimator == nil { + if estimator, err = gas.NewEstimator(lggr, client, cfg.ChainType(), chainID, cfg.GasEstimator(), clientsByChainID); err != nil { + return nil, fmt.Errorf("failed to initialize estimator: %w", err) + } + } else { + estimator = opts.GenGasEstimator(chainID) + } + return +} diff --git a/core/config/docs/chains-evm.toml b/core/config/docs/chains-evm.toml index 62360cb02cb..e8adb3d611c 100644 --- a/core/config/docs/chains-evm.toml +++ b/core/config/docs/chains-evm.toml @@ -106,6 +106,8 @@ LogBroadcasterEnabled = true # Default NoNewFinalizedHeadsThreshold = '0' # Default [EVM.Transactions] +# Enabled is a feature flag for the Transaction Manager. This flag also enables or disables the gas estimator since it is dependent on the TXM to start it. +Enabled = true # Default # ForwardersEnabled enables or disables sending transactions through forwarder contracts. ForwardersEnabled = false # Default # MaxInFlight controls how many transactions are allowed to be "in-flight" i.e. broadcast but unconfirmed at any one time. You can consider this a form of transaction throttling. diff --git a/core/services/chainlink/config_test.go b/core/services/chainlink/config_test.go index 769005feb72..aab601133d6 100644 --- a/core/services/chainlink/config_test.go +++ b/core/services/chainlink/config_test.go @@ -654,6 +654,7 @@ func TestConfig_Marshal(t *testing.T) { NoNewFinalizedHeadsThreshold: &hour, Transactions: evmcfg.Transactions{ + Enabled: ptr(true), MaxInFlight: ptr[uint32](19), MaxQueued: ptr[uint32](99), ReaperInterval: &minute, @@ -1118,6 +1119,7 @@ FinalizedBlockOffset = 16 NoNewFinalizedHeadsThreshold = '1h0m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = true MaxInFlight = 19 MaxQueued = 99 diff --git a/core/services/chainlink/testdata/config-full.toml b/core/services/chainlink/testdata/config-full.toml index 47193f80184..61469716bf3 100644 --- a/core/services/chainlink/testdata/config-full.toml +++ b/core/services/chainlink/testdata/config-full.toml @@ -337,6 +337,7 @@ FinalizedBlockOffset = 16 NoNewFinalizedHeadsThreshold = '1h0m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = true MaxInFlight = 19 MaxQueued = 99 diff --git a/core/services/chainlink/testdata/config-multi-chain-effective.toml b/core/services/chainlink/testdata/config-multi-chain-effective.toml index 7e658b170db..794e02dd119 100644 --- a/core/services/chainlink/testdata/config-multi-chain-effective.toml +++ b/core/services/chainlink/testdata/config-multi-chain-effective.toml @@ -320,6 +320,7 @@ FinalizedBlockOffset = 12 NoNewFinalizedHeadsThreshold = '9m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -430,6 +431,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -534,6 +536,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '6m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 5000 diff --git a/core/web/resolver/testdata/config-full.toml b/core/web/resolver/testdata/config-full.toml index ef26bfea75a..451faade0ad 100644 --- a/core/web/resolver/testdata/config-full.toml +++ b/core/web/resolver/testdata/config-full.toml @@ -337,6 +337,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '15m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = true MaxInFlight = 19 MaxQueued = 99 diff --git a/core/web/resolver/testdata/config-multi-chain-effective.toml b/core/web/resolver/testdata/config-multi-chain-effective.toml index 7bdf50b9080..c4a9f24d545 100644 --- a/core/web/resolver/testdata/config-multi-chain-effective.toml +++ b/core/web/resolver/testdata/config-multi-chain-effective.toml @@ -320,6 +320,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '9m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -430,6 +431,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -534,6 +536,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '6m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 5000 diff --git a/docs/CONFIG.md b/docs/CONFIG.md index 946703695eb..11cc2fbad01 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -2034,6 +2034,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '9m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -2138,6 +2139,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -2242,6 +2244,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -2346,6 +2349,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -2451,6 +2455,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '13m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -2559,6 +2564,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -2663,6 +2669,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -2768,6 +2775,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -2872,6 +2880,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '45s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -2975,6 +2984,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -3078,6 +3088,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -3182,6 +3193,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '40s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -3287,6 +3299,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '2m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -3391,6 +3404,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -3495,6 +3509,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '6m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 5000 @@ -3599,6 +3614,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -3704,6 +3720,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -3809,6 +3826,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '1h10m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -3917,6 +3935,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4021,6 +4040,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4129,6 +4149,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4236,6 +4257,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4340,6 +4362,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4444,6 +4467,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4551,6 +4575,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4659,6 +4684,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4767,6 +4793,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '1h30m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4875,6 +4902,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -4978,6 +5006,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -5082,6 +5111,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -5186,6 +5216,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -5291,6 +5322,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '40s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -5395,6 +5427,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '40s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -5499,6 +5532,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '1h10m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -5607,6 +5641,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '45m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -5714,6 +5749,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -5819,6 +5855,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '2h0m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -5927,6 +5964,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6031,6 +6069,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6135,6 +6174,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6243,6 +6283,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6348,6 +6389,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6452,6 +6494,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '1h30m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6559,6 +6602,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6663,6 +6707,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '15m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6771,6 +6816,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '2m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6876,6 +6922,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -6984,6 +7031,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -7092,6 +7140,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -7199,6 +7248,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '1m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -7303,6 +7353,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '1m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -7407,6 +7458,7 @@ FinalizedBlockOffset = 2 NoNewFinalizedHeadsThreshold = '1m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -7511,6 +7563,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '45m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -7616,6 +7669,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '15m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -7727,6 +7781,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '15m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -7836,6 +7891,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -7939,6 +7995,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -8044,6 +8101,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -8150,6 +8208,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -8254,6 +8313,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '1h50m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -8362,6 +8422,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 5000 @@ -8465,6 +8526,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '12m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 5000 @@ -8568,6 +8630,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '5m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -8672,6 +8735,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -8780,6 +8844,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '12m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -8889,6 +8954,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -8997,6 +9063,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -9104,6 +9171,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -9211,6 +9279,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -9320,6 +9389,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -9429,6 +9499,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '1h50m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -9537,6 +9608,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -9641,6 +9713,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '15m0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -9749,6 +9822,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -9853,6 +9927,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '0s' [Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 @@ -10138,6 +10213,7 @@ Set to zero to disable. ## EVM.Transactions ```toml [EVM.Transactions] +Enabled = true # Default ForwardersEnabled = false # Default MaxInFlight = 16 # Default MaxQueued = 250 # Default @@ -10147,6 +10223,12 @@ ResendAfterThreshold = '1m' # Default ``` +### Enabled +```toml +Enabled = true # Default +``` +Enabled is a feature flag for the Transaction Manager. This flag also enables or disables the gas estimator since it is dependent on the TXM to start it. + ### ForwardersEnabled ```toml ForwardersEnabled = false # Default diff --git a/testdata/scripts/node/validate/defaults-override.txtar b/testdata/scripts/node/validate/defaults-override.txtar index 336f170bd1b..eaa8b9b2e43 100644 --- a/testdata/scripts/node/validate/defaults-override.txtar +++ b/testdata/scripts/node/validate/defaults-override.txtar @@ -393,6 +393,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '9m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 diff --git a/testdata/scripts/node/validate/disk-based-logging-disabled.txtar b/testdata/scripts/node/validate/disk-based-logging-disabled.txtar index 677058e1c08..8e632f7b23f 100644 --- a/testdata/scripts/node/validate/disk-based-logging-disabled.txtar +++ b/testdata/scripts/node/validate/disk-based-logging-disabled.txtar @@ -376,6 +376,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '9m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 diff --git a/testdata/scripts/node/validate/disk-based-logging-no-dir.txtar b/testdata/scripts/node/validate/disk-based-logging-no-dir.txtar index 0e5a78f4a39..cbe09179049 100644 --- a/testdata/scripts/node/validate/disk-based-logging-no-dir.txtar +++ b/testdata/scripts/node/validate/disk-based-logging-no-dir.txtar @@ -376,6 +376,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '9m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 diff --git a/testdata/scripts/node/validate/disk-based-logging.txtar b/testdata/scripts/node/validate/disk-based-logging.txtar index 7fc05533a47..ed6d3d608d8 100644 --- a/testdata/scripts/node/validate/disk-based-logging.txtar +++ b/testdata/scripts/node/validate/disk-based-logging.txtar @@ -376,6 +376,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '9m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 diff --git a/testdata/scripts/node/validate/invalid.txtar b/testdata/scripts/node/validate/invalid.txtar index b048af38a3b..f0882d0d24c 100644 --- a/testdata/scripts/node/validate/invalid.txtar +++ b/testdata/scripts/node/validate/invalid.txtar @@ -366,6 +366,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '9m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250 diff --git a/testdata/scripts/node/validate/valid.txtar b/testdata/scripts/node/validate/valid.txtar index bc84a9b2a37..f7278540745 100644 --- a/testdata/scripts/node/validate/valid.txtar +++ b/testdata/scripts/node/validate/valid.txtar @@ -373,6 +373,7 @@ FinalizedBlockOffset = 0 NoNewFinalizedHeadsThreshold = '9m0s' [EVM.Transactions] +Enabled = true ForwardersEnabled = false MaxInFlight = 16 MaxQueued = 250