core/rawdb: change the mechanism to schedule freezer sync#32135
Merged
rjl493456442 merged 3 commits intoethereum:masterfrom Jul 15, 2025
Merged
core/rawdb: change the mechanism to schedule freezer sync#32135rjl493456442 merged 3 commits intoethereum:masterfrom
rjl493456442 merged 3 commits intoethereum:masterfrom
Conversation
Member
There was a problem hiding this comment.
Suggested change
| uncommit uint64 // Count of items written without flushing to file | |
| uncommitted uint64 // Count of items written without flushing to file |
be016b8 to
2c08f80
Compare
MariusVanDerWijden
approved these changes
Jul 15, 2025
howjmay
pushed a commit
to iotaledger/go-ethereum
that referenced
this pull request
Aug 27, 2025
…2135) This pull request slightly improves the freezer fsync mechanism by scheduling the Sync operation based on the number of uncommitted items and original time interval. Originally, freezer.Sync was triggered every 30 seconds, which worked well during active chain synchronization. However, once the initial state sync is complete, the fixed interval causes Sync to be scheduled too frequently. To address this, the scheduling logic has been improved to consider both the time interval and the number of uncommitted items. This additional condition helps avoid unnecessary Sync operations when the chain is idle.
gballet
pushed a commit
to gballet/go-ethereum
that referenced
this pull request
Sep 11, 2025
…2135) This pull request slightly improves the freezer fsync mechanism by scheduling the Sync operation based on the number of uncommitted items and original time interval. Originally, freezer.Sync was triggered every 30 seconds, which worked well during active chain synchronization. However, once the initial state sync is complete, the fixed interval causes Sync to be scheduled too frequently. To address this, the scheduling logic has been improved to consider both the time interval and the number of uncommitted items. This additional condition helps avoid unnecessary Sync operations when the chain is idle.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request slightly improves the freezer fsync mechanism by scheduling the
Sync operation based on the number of uncommitted items and original time interval.
Originally, freezer.Sync was triggered every 30 seconds, which worked well during
active chain synchronization. However, once the initial state sync is complete, the
fixed interval causes Sync to be scheduled too frequently.
To address this, the scheduling logic has been improved to consider both the time
interval and the number of uncommitted items. This additional condition helps avoid
unnecessary Sync operations when the chain is idle.