add validators power gauges

This commit is contained in:
Anton Kaliaev
2018-06-15 14:35:36 +04:00
parent fad76e103b
commit e58d674f4c
3 changed files with 45 additions and 19 deletions

View File

@@ -4,22 +4,22 @@ import "github.com/go-kit/kit/metrics"
import "github.com/go-kit/kit/metrics/discard"
// Metrics contains metrics exposed by this package.
// see MetricsProvider for descriptions.
type Metrics struct {
// height of the chain
Height metrics.Counter
// number of validators who signed
Validators metrics.Gauge
// number of validators who did not sign
MissingValidators metrics.Gauge
// number of validators who tried to double sign
ByzantineValidators metrics.Gauge
// time between this and the last block
Validators metrics.Gauge
ValidatorsPower metrics.Gauge
MissingValidators metrics.Gauge
MissingValidatorsPower metrics.Gauge
ByzantineValidators metrics.Gauge
ByzantineValidatorsPower metrics.Gauge
BlockIntervalSeconds metrics.Histogram
// number of transactions
NumTxs metrics.Gauge
// total number of transactions
NumTxs metrics.Gauge
TotalTxs metrics.Counter
// size of the block
BlockSizeBytes metrics.Gauge
}