-
Notifications
You must be signed in to change notification settings - Fork 371
Limit number of blocks per level (2nd attempt) #1559
Conversation
Co-authored-by: Bastian Köcher <[email protected]>
|
(Updated) Following #1559 (comment), let's recap the problems to be solved:
I don't see a direct support from the Backend to solve the issues, let's see if we can somehow work around the limitations.
A block descendants can be recovered using the leaves can be found using the So the main question here is: how to get the blocks list at one level? I'm open to more simple suggestions :-) |
Confident to merge this very soon. I just need to add a small safety net |
|
bot rebase |
|
Error: Command 'Command { std: "git" "merge" "origin/master" "--no-ff" "--no-edit", kill_on_drop: false }' failed with status Some(1); output: no output |
* Implemented explicit recovery for announced candidate blocks * Removed magic number * Apply suggestions from code review Co-authored-by: Bastian Köcher <[email protected]> * Introduce a random delay before attempting blocks explicit recovery * Richer recovery request message * Rename 'pending_candidates' PoVEntry to 'candidates' * Refactory * Some comments wrt the chosen recovery delay * Prevent recovery of imported blocks * Added test to excercise explicit block recovery request * Trivial cleanup * Fix ancestry assumption that may break recovery * Apply code review suggestion Co-authored-by: Bastian Köcher <[email protected]>
|
@davxy can we merge this? |
|
bot merge |
|
Error: Github API says #1559 is not mergeable |
Closes #432
This PR prevents the
StateDbError::TooManySiblingBlockserror from being triggered by eagerly removing leaves from the backend on block import and before the error condition is met.⚠ SUPERSEEDS: #1544
The main difference is this is a portable solution WRT the leaves order read from the backend.