Skip to content

Conversation

@fmoletta
Copy link
Contributor

Motivation
In a similar fashion to #2288, this PR aims to reduce the time spent writing data to the DB by writing data in batches. In this case the nodes received during storage healing are written all at once using the write_node_batch method introduced in #2288

Description

  • Refactor state healer code to write all nodes for a trie in a single operation

Closes #issue_number

@github-actions
Copy link

github-actions bot commented Mar 25, 2025

Lines of code report

Total lines added: 1
Total lines removed: 0
Total lines changed: 1

Detailed view
+----------------------------------------------------+-------+------+
| File                                               | Lines | Diff |
+----------------------------------------------------+-------+------+
| ethrex/crates/networking/p2p/sync/state_healing.rs | 119   | +1   |
+----------------------------------------------------+-------+------+

@fmoletta fmoletta marked this pull request as ready for review March 27, 2025 16:11
@fmoletta fmoletta requested a review from a team as a code owner March 27, 2025 16:11
fmoletta and others added 4 commits March 27, 2025 18:09
Co-authored-by: Rodrigo Oliveri <rodrigooliveri10@gmail.com>
…atches' into state-healing-write-nodes-in-batches
Base automatically changed from storage-healing-write-nodes-in-batches to main March 28, 2025 21:32
@fmoletta fmoletta enabled auto-merge March 31, 2025 14:23
@fmoletta fmoletta added this pull request to the merge queue Mar 31, 2025
Merged via the queue into main with commit f3063f1 Mar 31, 2025
25 checks passed
@fmoletta fmoletta deleted the state-healing-write-nodes-in-batches branch March 31, 2025 14:53
pedrobergamini pushed a commit to pedrobergamini/ethrex that referenced this pull request Aug 24, 2025
…ass#2309)

**Motivation**
In a similar fashion to lambdaclass#2288, this PR aims to reduce the time spent
writing data to the DB by writing data in batches. In this case the
nodes received during storage healing are written all at once using the
`write_node_batch` method introduced in lambdaclass#2288
<!-- Why does this pull request exist? What are its goals? -->

**Description**
* Refactor state healer code to write all nodes for a trie in a single
operation
<!-- A clear and concise general description of the changes this PR
introduces -->

<!-- Link to issues: Resolves lambdaclass#111, Resolves lambdaclass#222 -->

Closes #issue_number

---------

Co-authored-by: Rodrigo Oliveri <rodrigooliveri10@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.

5 participants