Skip to content

Commit e952322

Browse files
Marko BaricevicMarko Baricevic
authored andcommitted
attempt to fix metrics
1 parent 6aecf4c commit e952322

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

p2p/peer.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,11 +329,11 @@ func (p *peer) send(chID byte, msg proto.Message, sendFunc func(byte, []byte) bo
329329
res := sendFunc(chID, msgBytes)
330330
if res {
331331
labels := []string{
332+
"message_type", metricLabelValue,
332333
"peer_id", string(p.ID()),
333334
"chID", fmt.Sprintf("%#x", chID),
334335
}
335336
p.metrics.PeerSendBytesTotal.With(labels...).Add(float64(len(msgBytes)))
336-
p.metrics.MessageSendBytesTotal.With("message_type", metricLabelValue).Add(float64(len(msgBytes)))
337337
}
338338
return res
339339
}

0 commit comments

Comments
 (0)