This repository was archived by the owner on Aug 2, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
state-history-exit-on-write-failure-2.0.x #10332
Merged
huangminghuang
merged 3 commits into
release/2.0.x
from
huangminghuang/state-history-exit-on-write-failure-2.0.x
May 6, 2021
Merged
state-history-exit-on-write-failure-2.0.x #10332
huangminghuang
merged 3 commits into
release/2.0.x
from
huangminghuang/state-history-exit-on-write-failure-2.0.x
May 6, 2021
Conversation
This file contains 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
heifner
reviewed
May 3, 2021
} | ||
catch(const chain::plugin_exception& e) { | ||
wlog( "chain::plugin_exception: ${details}", ("details", e.to_detail_string()) ); | ||
EOS_THROW(chain::controller_emit_signal_exception, "State history encountered an Error which it cannot recover from. Please resolve the error and relaunch the process") |
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.
The idea is to derive from chain::controller_emit_signal_exception
not use it directly. See for example checkpoint_exception
.
7b1dc36
to
aa20b4c
Compare
heifner
reviewed
May 5, 2021
elog( "chain::plugin_exception: ${details}", ("details", e.to_detail_string()) ); | ||
elog("State history encountered an Error which it cannot recover from. Please resolve the error and relaunch " | ||
"the process"); | ||
appbase::app().quit(); |
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.
I think you should throw like you had before but also call app().quit()
. You don't want the block produced because on restart you need to reprocess the block so it can be written to SHiP.
9424ceb
to
b2a83f8
Compare
heifner
approved these changes
May 6, 2021
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Change Description
This PR address IS #9483 and IS #10113 so that the nodeos would exit when the state history plugin is unable to write trace/delta because of some invariant violations.
Change Type
Select ONE:
Testing Changes
Select ANY that apply:
Consensus Changes
API Changes
Documentation Additions
Add language to warn user that a nodoes node with state history plugin should not be configured as producer node because it may leave the fork db in an inconsistent state when it is unable to write traces/deltas to disk.