2019-08-16 17:13:04 +00:00
|
|
|
package sync
|
|
|
|
|
2019-08-28 15:14:22 +00:00
|
|
|
import (
|
|
|
|
"github.com/prometheus/client_golang/prometheus"
|
|
|
|
"github.com/prometheus/client_golang/prometheus/promauto"
|
|
|
|
)
|
|
|
|
|
2019-08-16 17:13:04 +00:00
|
|
|
// TODO(3147): Add metrics for RPC & subscription success/error.
|
2019-08-28 15:14:22 +00:00
|
|
|
|
|
|
|
var (
|
|
|
|
messageReceivedCounter = promauto.NewCounterVec(
|
|
|
|
prometheus.CounterOpts{
|
|
|
|
Name: "p2p_message_recieved_total",
|
|
|
|
Help: "Count of messages received.",
|
|
|
|
},
|
|
|
|
[]string{"topic"},
|
|
|
|
)
|
2019-09-17 21:14:51 +00:00
|
|
|
messageReceivedBeforeChainStartCounter = promauto.NewCounterVec(
|
|
|
|
prometheus.CounterOpts{
|
|
|
|
Name: "p2p_message_recieved_before_chain_start",
|
|
|
|
Help: "Count of messages received before chain started.",
|
|
|
|
},
|
|
|
|
[]string{"topic"},
|
|
|
|
)
|
2019-08-28 15:14:22 +00:00
|
|
|
)
|