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

Exit reconstruction early #14915

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from
Open

Exit reconstruction early #14915

wants to merge 4 commits into from

Conversation

nisdas
Copy link
Member

@nisdas nisdas commented Feb 12, 2025

What type of PR is this?

Feature Improvement

What does this PR do? Why is it needed?

In the event we have no commitments in the block or that all blobs have been seen via gossip we exit our reconstruction routine early.

Which issues(s) does this PR fix?

N.A

Other notes for review

Acknowledgements

@nisdas nisdas requested a review from a team as a code owner February 12, 2025 07:52
Comment on lines +103 to +107
// If all blobs have been seen via gossip, we can exit the reconstruction
// routine early as there is nothing to fetch from the EL.
if !blobUnseen {
return
}
Copy link
Member

Choose a reason for hiding this comment

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

I think the commitment check is fine, but I’m not a fan of the blob unseen check since it’s already handled in ReconstructBlobSidecars:

if len(kzgHashes) == 0 {
	return nil, nil
}

It feels like we’re repeating the same check.

Side note: we also can move blobExistedInDBTotal inside ReconstructBlobSidecars to not repeat the same loop

Copy link
Member Author

Choose a reason for hiding this comment

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

Do you think we should move blobRecoveredFromELTotal there too ? I looked at the reconstruction metrics and it would be wierd to move blobExistedInDBTotal but leave blobRecoveredFromELTotal there

Copy link
Member

Choose a reason for hiding this comment

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

Yes, I think that's good too

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants