From 58ee613feac481da53da7674aaa5736631a15307 Mon Sep 17 00:00:00 2001 From: jaime Date: Mon, 27 May 2024 01:49:41 +0800 Subject: [PATCH] enhance: remove repeated stats of loaded entity (#33255) Signed-off-by: jaime --- internal/querynodev2/segments/segment.go | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/internal/querynodev2/segments/segment.go b/internal/querynodev2/segments/segment.go index e4ad589e41..614f310221 100644 --- a/internal/querynodev2/segments/segment.go +++ b/internal/querynodev2/segments/segment.go @@ -30,7 +30,6 @@ import ( "fmt" "io" "runtime" - "strconv" "strings" "unsafe" @@ -440,15 +439,6 @@ func (s *LocalSegment) initializeSegment() error { // Update the insert count when initialize the segment and update the metrics. s.insertCount.Store(loadInfo.GetNumOfRows()) - metrics.QueryNodeNumEntities.WithLabelValues( - s.DatabaseName(), - fmt.Sprint(paramtable.GetNodeID()), - fmt.Sprint(s.Collection()), - fmt.Sprint(s.Partition()), - s.Type().String(), - strconv.FormatInt(int64(len(s.Indexes())), 10), - ).Add(float64(loadInfo.GetNumOfRows())) - return nil } @@ -808,15 +798,6 @@ func (s *LocalSegment) Insert(ctx context.Context, rowIDs []int64, timestamps [] } s.insertCount.Add(int64(numOfRow)) - metrics.QueryNodeNumEntities.WithLabelValues( - s.DatabaseName(), - fmt.Sprint(paramtable.GetNodeID()), - fmt.Sprint(s.Collection()), - fmt.Sprint(s.Partition()), - s.Type().String(), - strconv.FormatInt(int64(len(s.Indexes())), 10), - ).Add(float64(numOfRow)) - s.rowNum.Store(-1) s.memSize.Store(-1) return nil