Report metrics of all db columns
This commit is contained in:
parent
76be70d4cf
commit
4f5461da4f
@ -949,9 +949,11 @@ func (d *RocksDB) SetInternalState(is *common.InternalState) {
|
|||||||
|
|
||||||
// StoreInternalState stores the internal state to db
|
// StoreInternalState stores the internal state to db
|
||||||
func (d *RocksDB) StoreInternalState(is *common.InternalState) error {
|
func (d *RocksDB) StoreInternalState(is *common.InternalState) error {
|
||||||
rows, keyBytes, valueBytes := d.is.GetDBColumnStats(cfTransactions)
|
for c := 0; c < len(cfNames); c++ {
|
||||||
d.metrics.DbColumnRows.With(common.Labels{"column": cfNames[cfTransactions]}).Set(float64(rows))
|
rows, keyBytes, valueBytes := d.is.GetDBColumnStats(c)
|
||||||
d.metrics.DbColumnSize.With(common.Labels{"column": cfNames[cfTransactions]}).Set(float64(keyBytes + valueBytes))
|
d.metrics.DbColumnRows.With(common.Labels{"column": cfNames[c]}).Set(float64(rows))
|
||||||
|
d.metrics.DbColumnSize.With(common.Labels{"column": cfNames[c]}).Set(float64(keyBytes + valueBytes))
|
||||||
|
}
|
||||||
buf, err := is.Pack()
|
buf, err := is.Pack()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user