-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
Update epoch slots to include all missing slots #8276
Conversation
Codecov Report
@@ Coverage Diff @@
## master #8276 +/- ##
========================================
+ Coverage 80.6% 80.6% +<.1%
========================================
Files 253 253
Lines 55247 55386 +139
========================================
+ Hits 44550 44683 +133
- Misses 10697 10703 +6 |
core/src/cluster_info.rs
Outdated
.expect("expected to find at least one slot"); | ||
let last_slot = incomplete_slots | ||
.iter() | ||
.last() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because this iterator implements DoubleEndedIterator
, next_back()
is a more efficient way to get the last item without iterating over the entire set
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LMK when you are done with the review. I'll update the PR with the required changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you guys are fast!
Pull request has been modified.
@carllin , the latest patch should start limiting the cache size, instead of limiting it based on roots. @aeyakovenko , there are two separate changes we can make down the line.
|
@pgarg66 we just need to do 1. And replace the oldest stash. This would also reduce the churn in gossip |
* Update epoch slots to include all missing slots * new test for compress/decompress * address review comments * limit cache based on size, instead of comparing roots (cherry picked from commit 0d5c123) # Conflicts: # Cargo.lock
* Update epoch slots to include all missing slots * new test for compress/decompress * address review comments * limit cache based on size, instead of comparing roots
* Update epoch slots to include all missing slots * new test for compress/decompress * address review comments * limit cache based on size, instead of comparing roots
Problem
Some shreds could be missing across the cluster (e.g. due to turbine failure). Such shreds will be repaired by all/most nodes. Need a mechanism to detect that most of the cluster is missing shreds/slots, so that the such shreds could be pushed thru turbine again.
Summary of Changes
This change augments epoch_slots information that's pushed thru gossip. It'll include information about all incomplete slots in the current epoch. Since the list could be large, it's getting compressed using gzip.