Recovery from snapshot#1656
Merged
Merged
Conversation
added 20 commits
August 28, 2020 09:58
jumaffre
commented
Sep 25, 2020
jumaffre
commented
Sep 25, 2020
jumaffre
commented
Sep 25, 2020
jumaffre
commented
Sep 25, 2020
|
recovery_from_snapshot@13241 aka 20200929.10 vs master ewma over 50 builds from 12699 to 13236 |
ashamis
reviewed
Sep 25, 2020
| if (view_history) | ||
| { | ||
| view_history = d.deserialise_view_history(); | ||
| view_history_ = d.deserialise_view_history(); |
Contributor
There was a problem hiding this comment.
minor: can you simplify the code by passing view_history by reference (into the funtion) as you always want to return the view history and then just deserializing into view_history?
Contributor
Author
There was a problem hiding this comment.
I don't think we want to pass a reference here as we don't necessarily want to deserialise the view history. If the source KV store doesn't have a consensus, then the view history won't be included in the snapshot. This is useful to test snapshots on the KV in isolation of other components.
ashamis
reviewed
Sep 25, 2020
ashamis
reviewed
Sep 25, 2020
ashamis
reviewed
Sep 25, 2020
ashamis
reviewed
Sep 25, 2020
achamayou
reviewed
Sep 28, 2020
achamayou
reviewed
Sep 28, 2020
|
|
||
| // This should really be a reference but because there are two ecalls, | ||
| // this is currently not possible: | ||
| // https://github.com/microsoft/CCF/issues/857 |
Member
There was a problem hiding this comment.
Maybe it's time for 857 then.
achamayou
approved these changes
Sep 28, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Resolves #1303
This PR adds support for resuming from a snapshot on recovery, making the whole recovery procedure a lot faster (from 1 minute to 11 seconds in this example):
Implementation details:
cchoston recovery (just like when joining a new network).Notes:
recovery_snapshot_teste2e test with corresponding changes to the Python infra.start_test_network.shcan recover from a snapshot.