Skip to content
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

feat(prune, stages): prune pipeline stage #9419

Merged
merged 14 commits into from
Jul 11, 2024
Merged

feat(prune, stages): prune pipeline stage #9419

merged 14 commits into from
Jul 11, 2024

Conversation

shekhirin
Copy link
Collaborator

@shekhirin shekhirin commented Jul 10, 2024

Closes #9270

/// The prune stage that runs the pruner with the provided prune modes.
///
/// There are two main reasons to have this stage when running a full node:
/// - Sender Recovery stage inserts a lot of data into the database that's only needed for the
/// Execution stage. Pruner will clean up the unneeded recovered senders.
/// - Pruning during the live sync can take a significant amount of time, especially history
/// segments. If we can prune as much data as possible in one go before starting the live sync, we
/// should do it.

image

@shekhirin shekhirin added C-enhancement New feature or request A-staged-sync Related to staged sync (pipelines and stages) A-pruning Related to pruning or full node labels Jul 10, 2024
@shekhirin shekhirin marked this pull request as ready for review July 10, 2024 17:07
@shekhirin shekhirin requested a review from emhane July 10, 2024 17:07
crates/prune/prune/src/builder.rs Show resolved Hide resolved
crates/prune/prune/src/builder.rs Show resolved Hide resolved
crates/prune/prune/src/pruner.rs Outdated Show resolved Hide resolved
crates/stages/stages/src/sets.rs Outdated Show resolved Hide resolved
Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

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

some questions.

will this now always log on CLI output even if archive node?
should this be optionally installed if prunemodes none?

crates/prune/prune/src/pruner.rs Show resolved Hide resolved
crates/stages/api/src/pipeline/mod.rs Outdated Show resolved Hide resolved
crates/stages/stages/src/stages/prune.rs Show resolved Hide resolved
crates/stages/types/src/id.rs Show resolved Hide resolved
Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

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

last nits

crates/prune/prune/src/pruner.rs Outdated Show resolved Hide resolved
crates/stages/stages/src/sets.rs Outdated Show resolved Hide resolved
@shekhirin shekhirin requested a review from mattsse July 11, 2024 15:15
@shekhirin shekhirin requested a review from emhane July 11, 2024 15:15
Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

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

cool, last naming nits

crates/stages/api/src/pipeline/set.rs Outdated Show resolved Hide resolved
crates/stages/stages/src/sets.rs Outdated Show resolved Hide resolved
@shekhirin shekhirin added this pull request to the merge queue Jul 11, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jul 11, 2024
@shekhirin shekhirin enabled auto-merge July 11, 2024 19:03
@shekhirin shekhirin added this pull request to the merge queue Jul 11, 2024
Merged via the queue into main with commit b040b86 Jul 11, 2024
33 checks passed
@shekhirin shekhirin deleted the alexey/prune-stage branch July 11, 2024 19:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-pruning Related to pruning or full node A-staged-sync Related to staged sync (pipelines and stages) C-enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Initial pruning should be done in the pipeline
3 participants