Skip to content

Commit

Permalink
Added more verbosity to CN logs (#1202)
Browse files Browse the repository at this point in the history
* Add reason log for cn

* Update ConsensusService.cs
  • Loading branch information
shargon committed Nov 8, 2019
1 parent 85c0013 commit f70a76d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions neo/Consensus/ConsensusService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -615,11 +615,11 @@ private void RequestChangeView(ChangeViewReason reason)
ChangeTimer(TimeSpan.FromMilliseconds(Blockchain.MillisecondsPerBlock << (expectedView + 1)));
if ((context.CountCommitted + context.CountFailed) > context.F)
{
Log($"Skip requesting change view to nv={expectedView} because nc={context.CountCommitted} nf={context.CountFailed}");
Log($"skip requesting change view: height={context.Block.Index} view={context.ViewNumber} nv={expectedView} nc={context.CountCommitted} nf={context.CountFailed} reason={reason}");
RequestRecovery();
return;
}
Log($"request change view: height={context.Block.Index} view={context.ViewNumber} nv={expectedView} nc={context.CountCommitted} nf={context.CountFailed}");
Log($"request change view: height={context.Block.Index} view={context.ViewNumber} nv={expectedView} nc={context.CountCommitted} nf={context.CountFailed} reason={reason}");
localNode.Tell(new LocalNode.SendDirectly { Inventory = context.MakeChangeView(reason) });
CheckExpectedView(expectedView);
}
Expand Down

0 comments on commit f70a76d

Please sign in to comment.