Skip to content

feat: modify txmgr to send EIP-1559 txns#2086

Merged
mslipper merged 6 commits intoethereum-optimism:developfrom
cfromknecht:bss-eip-1559
Jan 31, 2022
Merged

feat: modify txmgr to send EIP-1559 txns#2086
mslipper merged 6 commits intoethereum-optimism:developfrom
cfromknecht:bss-eip-1559

Conversation

@cfromknecht
Copy link
Copy Markdown
Contributor

@cfromknecht cfromknecht commented Jan 26, 2022

Description
Modifies the txmgr to use EIP-1559 dynamic fee txns, rather the current
method of linearly increasing the gas price between a configured minimum
and maximum.

In addition, we add generic fallback in case the L1 provider does not support
queries for eth_maxPriorityFeePerGas. Of our infrastructure providers,
i.e. Alchemy, Infura, Quicknode, and Hardhat (in test envs), only
Alchemy supports this call. In production, we will be routing this call
directly to Alchemy, which should work in the general case. However, if
they were to be unavailable the batch submitter would be stalled until
service was restored. This modification also allows the new EIP-1559
batch submitter to pass our integration tests, since the default Hardhat
backend doesn't support the query either.

Compare to the existing, approach, we should see quicker confirmation times,
as the prior iteration would start ratcheting from well below the market rate. This
should have small, net positive effect on the overall TPS of the system.

Metadata

  • Fixes ENG-1486

@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Jan 26, 2022

🦋 Changeset detected

Latest commit: 3a7e709

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@eth-optimism/batch-submitter-service Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@cfromknecht cfromknecht force-pushed the bss-eip-1559 branch 3 times, most recently from 6c860d7 to e7d25e2 Compare January 27, 2022 16:57
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Jan 27, 2022

Codecov Report

Merging #2086 (3a7e709) into develop (36151fe) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff            @@
##           develop    #2086   +/-   ##
========================================
  Coverage    75.37%   75.37%           
========================================
  Files           81       81           
  Lines         2705     2705           
  Branches       436      436           
========================================
  Hits          2039     2039           
  Misses         666      666           
Flag Coverage Δ
batch-submitter 62.63% <ø> (ø)
contracts 90.48% <ø> (ø)
core-utils 59.94% <ø> (ø)
data-transport-layer 38.64% <ø> (ø)
message-relayer 70.86% <ø> (ø)
sdk 86.34% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 36151fe...3a7e709. Read the comment docs.

@cfromknecht cfromknecht marked this pull request as ready for review January 27, 2022 17:37
@cfromknecht cfromknecht requested review from mslipper and tynes January 27, 2022 17:37
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tynes is the best we can do in terms of a fallback? i.e. using a constant, or is there a better way you can think of?

This commit adds a fallback in case the L1 provider does not support
queries for eth_maxPriorityFeePerGas. Of our infrastructure providers,
i.e. Alchemy, Infura, Quicknode, and Hardhat (in test envs), only
Alchemy suports this call. In production, we will be routing this call
directly to Alchemy, which should work in the general case. However, if
they were to be unavailable the batch submitter would be stalled until
service was restored. This modification also allows the new EIP-1559
batch submitter to pass our integration tests, since the default Hardhat
backend can't support the query either.
Removes the MAX_L1_GAS_PRICE_IN_GWEI and GAS_RETRY_INCREMENT env vars,
as well as the MinL1GasPrice, MaxL1GasPrice, and GasRetryIncrement
values from the txmgr config struct.
@mslipper mslipper merged commit dc1ed3c into ethereum-optimism:develop Jan 31, 2022
@cfromknecht cfromknecht deleted the bss-eip-1559 branch February 1, 2022 02:10
theochap pushed a commit that referenced this pull request Dec 10, 2025
…`derivationOriginUpdate` (#2331)

Closes #2086 

The PR:
- Introduces new table `BlockTraversal` to store all L1 blocks, even if
there are no L2 blocks derived from it.
- Add respective trait methods.
- Modified `latest_derived_block_pair` to send the latest derived block
from `DerivedBlocks` and latest source block from `BlockTraversal`.
- Exclusively dealing with `derivationUpdate` and
`derivationOriginUpdate` i.e. updating latest derived on
`derivationUpdate` and updating latest source on
`derivationOriginUpdate`.
- The e2e test `TestFinalizedHeadAdvancing` passes now. 

TODO: (in another PR)
- Remove `current_l1` and its usage. No longer required.
- ~~For now, `check_node_consistency()` is commented in this PR. #2330
takes care of that.~~

~~Currently in draft: Tests are missing.~~

---------

Co-authored-by: Arun Dhyani <dhyaniarun7@gmail.com>
theochap pushed a commit that referenced this pull request Jan 14, 2026
…`derivationOriginUpdate` (op-rs/kona#2331)

Closes #2086 

The PR:
- Introduces new table `BlockTraversal` to store all L1 blocks, even if
there are no L2 blocks derived from it.
- Add respective trait methods.
- Modified `latest_derived_block_pair` to send the latest derived block
from `DerivedBlocks` and latest source block from `BlockTraversal`.
- Exclusively dealing with `derivationUpdate` and
`derivationOriginUpdate` i.e. updating latest derived on
`derivationUpdate` and updating latest source on
`derivationOriginUpdate`.
- The e2e test `TestFinalizedHeadAdvancing` passes now. 

TODO: (in another PR)
- Remove `current_l1` and its usage. No longer required.
- ~~For now, `check_node_consistency()` is commented in this PR. #2330
takes care of that.~~

~~Currently in draft: Tests are missing.~~

---------

Co-authored-by: Arun Dhyani <dhyaniarun7@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants