Skip to content

feat(l2): config eth client through .toml #2510

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 36 commits into from
May 12, 2025
Merged

feat(l2): config eth client through .toml #2510

merged 36 commits into from
May 12, 2025

Conversation

tomip01
Copy link
Contributor

@tomip01 tomip01 commented Apr 21, 2025

Motivation

Here we want to be able to configure some constant values in our L2. These changes aim to improve flexibility in the L2 and provide better control.

Description

  • Added elasticity_multiplier to BuildPayloadArgs and passed it to calculate_base_fee_per_gas.
  • Incorporated elasticity_multiplier into BlockProducer.
  • Introduced new fields (max_number_of_retries, backoff_factor, min_retry_delay, max_retry_delay) in EthClient.

Closes #2479

Copy link

github-actions bot commented Apr 21, 2025

Lines of code report

Total lines added: 170
Total lines removed: 0
Total lines changed: 170

Detailed view
+---------------------------------------------------------+-------+------+
| File                                                    | Lines | Diff |
+---------------------------------------------------------+-------+------+
| ethrex/cmd/ethrex/l2/options.rs                         | 393   | +45  |
+---------------------------------------------------------+-------+------+
| ethrex/crates/blockchain/blockchain.rs                  | 495   | +2   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/blockchain/payload.rs                     | 552   | +2   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/blockchain/smoke_test.rs                  | 236   | +1   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/common/types/block.rs                     | 716   | +3   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/contracts/bin/deployer/cli.rs          | 266   | +36  |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/contracts/bin/deployer/main.rs         | 459   | +4   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/prover/src/backends/exec.rs            | 86    | +6   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/prover/src/prover.rs                   | 120   | +1   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/prover/zkvm/interface/pico/src/main.rs | 70    | +8   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/prover/zkvm/interface/sp1/src/main.rs  | 76    | +7   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/prover/zkvm/interface/src/lib.rs       | 194   | +1   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/sequencer/block_producer.rs            | 123   | +9   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/sequencer/configs.rs                   | 52    | +5   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/sequencer/l1_committer.rs              | 510   | +4   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/sequencer/proof_coordinator.rs         | 303   | +12  |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/utils/error.rs                         | 25    | +3   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/l2/utils/test_data_io.rs                  | 90    | +3   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/networking/rpc/clients/eth/mod.rs         | 1115  | +16  |
+---------------------------------------------------------+-------+------+
| ethrex/crates/networking/rpc/engine/fork_choice.rs      | 394   | +1   |
+---------------------------------------------------------+-------+------+
| ethrex/crates/networking/rpc/eth/fee_market.rs          | 235   | +1   |
+---------------------------------------------------------+-------+------+

@tomip01 tomip01 changed the title L2/add configs toml feat(l1,l2): config eth client through .toml Apr 21, 2025
@tomip01 tomip01 self-assigned this Apr 22, 2025
@tomip01 tomip01 added the L2 Rollup client label Apr 22, 2025
@tomip01 tomip01 changed the title feat(l1,l2): config eth client through .toml feat(l2): config eth client through .toml Apr 22, 2025
@tomip01 tomip01 marked this pull request as ready for review April 22, 2025 20:20
@tomip01 tomip01 requested a review from a team as a code owner April 22, 2025 20:20
@tomip01 tomip01 requested a review from jrchatruc April 29, 2025 12:26
Copy link
Contributor

@ilitteri ilitteri left a comment

Choose a reason for hiding this comment

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

Left some refator suggestions

@ilitteri ilitteri added this pull request to the merge queue May 12, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks May 12, 2025
@tomip01 tomip01 added this pull request to the merge queue May 12, 2025
@jrchatruc jrchatruc removed this pull request from the merge queue due to a manual request May 12, 2025
@jrchatruc jrchatruc added this pull request to the merge queue May 12, 2025
Merged via the queue into main with commit 2a6c44c May 12, 2025
30 checks passed
@jrchatruc jrchatruc deleted the l2/add-configs-toml branch May 12, 2025 21:40
fmoletta pushed a commit that referenced this pull request May 15, 2025
**Motivation**

Here we want to be able to configure some constant values in our L2.
These changes aim to improve flexibility in the L2 and provide better
control.

**Description**

* Added `elasticity_multiplier` to `BuildPayloadArgs` and passed it to
`calculate_base_fee_per_gas`.
* Incorporated `elasticity_multiplier` into `BlockProducer`.
* Introduced new fields (`max_number_of_retries`, `backoff_factor`,
`min_retry_delay`, `max_retry_delay`) in `EthClient`.

Closes #2479

---------

Co-authored-by: Javier Rodríguez Chatruc <49622509+jrchatruc@users.noreply.github.com>
pedrobergamini pushed a commit to pedrobergamini/ethrex that referenced this pull request Aug 24, 2025
**Motivation**

Here we want to be able to configure some constant values in our L2.
These changes aim to improve flexibility in the L2 and provide better
control.

**Description**

* Added `elasticity_multiplier` to `BuildPayloadArgs` and passed it to
`calculate_base_fee_per_gas`.
* Incorporated `elasticity_multiplier` into `BlockProducer`.
* Introduced new fields (`max_number_of_retries`, `backoff_factor`,
`min_retry_delay`, `max_retry_delay`) in `EthClient`.

Closes lambdaclass#2479

---------

Co-authored-by: Javier Rodríguez Chatruc <49622509+jrchatruc@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
L2 Rollup client
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Move elasticity multiplier and exponential backoff parameters to be configuration values
3 participants