Skip to content

Optimise status processing #7082

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

Conversation

michaelsproul
Copy link
Member

@michaelsproul michaelsproul commented Mar 6, 2025

Issue Addressed

This is a backport from holesky-rescue.

Part of:

Original PR to holesky-rescue:

Proposed Changes

Avoid doing database lookups for slots that lie in the hot database when processing status messages. This avoids a DoS vector during non-finality, as loading hot states to iterate block roots is very expensive.

This is a backport from `holesky-rescue`.

Co-authored-by: Jimmy Chen <[email protected]>
@michaelsproul michaelsproul added ready-for-review The code is ready for review v7.0.0 New release c. Q1 2025 v7.0.0-beta.clean Clean release post Holesky rescue labels Mar 6, 2025
@michaelsproul michaelsproul requested a review from jxs as a code owner March 6, 2025 03:18
@michaelsproul michaelsproul mentioned this pull request Mar 6, 2025
14 tasks
// chain.
if self
.chain
.block_root_at_slot(remote_finalized_slot, WhenSlotSkipped::Prev)
Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm convinced now that this is very cheap 👍

@michaelsproul michaelsproul added ready-for-merge This PR is ready to merge. and removed ready-for-review The code is ready for review labels Mar 10, 2025
mergify bot added a commit that referenced this pull request Mar 10, 2025
@mergify mergify bot merged commit 7d598ed into sigp:release-v7.0.0 Mar 10, 2025
31 checks passed
@michaelsproul michaelsproul deleted the optimise-status-processing-release-v7 branch March 10, 2025 05:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-for-merge This PR is ready to merge. v7.0.0-beta.clean Clean release post Holesky rescue v7.0.0 New release c. Q1 2025
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants