From 44d7e03e56ec9532c9568585c63bf6841ba93005 Mon Sep 17 00:00:00 2001 From: SimFG Date: Mon, 3 Jun 2024 21:09:47 +0800 Subject: [PATCH] fix: reset the RootCoordQuotaStates metric before recording this metric (#33553) - issue: #33539 Signed-off-by: SimFG --- internal/rootcoord/quota_center.go | 1 + 1 file changed, 1 insertion(+) diff --git a/internal/rootcoord/quota_center.go b/internal/rootcoord/quota_center.go index 0e09943893..c16c5dbca9 100644 --- a/internal/rootcoord/quota_center.go +++ b/internal/rootcoord/quota_center.go @@ -1487,6 +1487,7 @@ func (q *QuotaCenter) sendRatesToProxy() error { // recordMetrics records metrics of quota states. func (q *QuotaCenter) recordMetrics() { + metrics.RootCoordQuotaStates.Reset() dbIDs := make(map[int64]string, q.dbs.Len()) collectionIDs := make(map[int64]string, q.collections.Len()) q.dbs.Range(func(name string, id int64) bool {