|
|
|
@ -64,7 +64,7 @@ func (node *Node) HandleMessage(content []byte, sender libp2p_peer.ID) { |
|
|
|
|
utils.Logger().Info(). |
|
|
|
|
Int64("TotalIn", node.host.GetBandwidthTotals().TotalIn). |
|
|
|
|
Float64("RateIn", node.host.GetBandwidthTotals().RateIn). |
|
|
|
|
Msg("Record Receiving Metrics!") |
|
|
|
|
Msg("[metrics][p2p] traffic in in bytes") |
|
|
|
|
|
|
|
|
|
msgCategory, err := proto.GetMessageCategory(content) |
|
|
|
|
if err != nil { |
|
|
|
@ -457,7 +457,7 @@ func (node *Node) PostConsensusProcessing( |
|
|
|
|
|
|
|
|
|
// Clear metrics after one consensus cycle
|
|
|
|
|
node.host.ResetMetrics() |
|
|
|
|
utils.Logger().Info().Msg("Metrics cleared after one consensus cycle") |
|
|
|
|
utils.Logger().Info().Msg("[metrics][p2p] Reset after 1 consensus cycle") |
|
|
|
|
|
|
|
|
|
// Update consensus keys at last so the change of leader status doesn't mess up normal flow
|
|
|
|
|
if len(newBlock.Header().ShardState()) > 0 { |
|
|
|
|