Skip to content

Conversation

jrchatruc
Copy link
Collaborator

@jrchatruc jrchatruc commented Sep 25, 2025

Motivation

Our current snap sync implementation stops downloading an account's storage leaves if there's a pivot jump. This is a big deal because in every network there are very few contracts that have almost all of the storage; this means in big networks like Sepolia or Mainnet we currently heal most of the storage tries in their entirety.

This PR makes it so the snap sync step that downloads storage leaves keeps track of big accounts to resume their download when a pivot jump occurs.

Description

Closes #issue_number

@jrchatruc jrchatruc requested a review from a team as a code owner September 25, 2025 00:26
@github-actions github-actions bot added the L1 Ethereum client label Sep 25, 2025
Copy link

github-actions bot commented Sep 25, 2025

Lines of code report

Total lines added: 106
Total lines removed: 20
Total lines changed: 126

Detailed view
+------------------------------------------------------+-------+------+
| File                                                 | Lines | Diff |
+------------------------------------------------------+-------+------+
| ethrex/crates/networking/p2p/peer_handler.rs         | 1769  | +101 |
+------------------------------------------------------+-------+------+
| ethrex/crates/networking/p2p/sync.rs                 | 1218  | +2   |
+------------------------------------------------------+-------+------+
| ethrex/crates/networking/p2p/sync/state_healing.rs   | 365   | +3   |
+------------------------------------------------------+-------+------+
| ethrex/crates/networking/p2p/sync/storage_healing.rs | 559   | -20  |
+------------------------------------------------------+-------+------+

Copy link
Contributor

@fedacking fedacking left a comment

Choose a reason for hiding this comment

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

LGTM

@github-project-automation github-project-automation bot moved this to In Review in ethrex_l1 Sep 25, 2025
};
tasks_queue_not_started.push_back(task);
task_count += 1;
// TODO: DRY
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please dry this

@github-project-automation github-project-automation bot moved this from In Review to In Progress in ethrex_l1 Sep 26, 2025
@jrchatruc
Copy link
Collaborator Author

Closing since it was included in #4689

@jrchatruc jrchatruc closed this Oct 1, 2025
@github-project-automation github-project-automation bot moved this from In Progress to Done in ethrex_l1 Oct 1, 2025
@jrchatruc jrchatruc deleted the keep-downloading-big-accounts-on-pivot-jump branch October 1, 2025 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
L1 Ethereum client
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

4 participants