diff --git a/dgraph/cmd/alpha/metrics_test.go b/dgraph/cmd/alpha/metrics_test.go index a1264711066..7d35010f14b 100644 --- a/dgraph/cmd/alpha/metrics_test.go +++ b/dgraph/cmd/alpha/metrics_test.go @@ -183,6 +183,9 @@ func TestMetrics(t *testing.T) { "badger_v3_disk_reads_total", "badger_v3_disk_writes_total", "badger_v3_gets_total", "badger_v3_memtable_gets_total", "badger_v3_puts_total", "badger_v3_read_bytes", "badger_v3_written_bytes", + // The following metrics get exposed after 1 minute from Badger, so + // they're not available in time for this test + // "badger_v3_lsm_size_bytes", "badger_v3_vlog_size_bytes", // Transaction Metrics "dgraph_txn_aborts_total", "dgraph_txn_commits_total", "dgraph_txn_discards_total", diff --git a/x/metrics.go b/x/metrics.go index 940bb586361..e14edbdd681 100644 --- a/x/metrics.go +++ b/x/metrics.go @@ -490,13 +490,13 @@ func NewBadgerCollector() prometheus.Collector { "Total number of memtable gets", nil, nil, ), - "badger_v3_lsm_size": prometheus.NewDesc( - "badger_v3_lsm_size", + "badger_v3_lsm_size_bytes": prometheus.NewDesc( + "badger_v3_lsm_size_bytes", "Size of the LSM in bytes", []string{"dir"}, nil, ), - "badger_v3_vlog_size": prometheus.NewDesc( - "badger_v3_vlog_size", + "badger_v3_vlog_size_bytes": prometheus.NewDesc( + "badger_v3_vlog_size_bytes", "Size of the value log in bytes", []string{"dir"}, nil, ),