Revert "Revert "Add disk type to prometheus metrics" (#4777)"

This reverts commit 9215ba24be.
This commit is contained in:
chrislu
2023-10-02 11:49:54 -07:00
parent b5070d6280
commit 567d788928
5 changed files with 10 additions and 9 deletions

View File

@@ -246,7 +246,7 @@ func (v *Volume) doClose() {
glog.Warningf("Volume Close fail to sync volume %d", v.Id)
}
v.DataBackend = nil
stats.VolumeServerVolumeCounter.WithLabelValues(v.Collection, "volume").Dec()
stats.VolumeServerVolumeCounter.WithLabelValues(v.Collection, "volume", v.DiskType().ReadableString()).Dec()
}
}