When we fail to generate a block, discard pending transactions (which

likely caused the failure) so we don't fail to produce the next block.
This commit is contained in:
Eric Frias 2018-04-15 18:18:18 -04:00
parent 5bd39c4be2
commit ac9689691d

View file

@ -183,6 +183,8 @@ block_production_condition::block_production_condition_enum witness_plugin::bloc
{
elog("Got exception while generating block:\n${e}", ("e", e.to_detail_string()));
result = block_production_condition::exception_producing_block;
elog("Discarding all pending transactions in an attempt to prevent the same error from occurring the next time we try to produce a block");
database().clear_pending();
}
switch( result )