fix group nq metrics (#24918)

Signed-off-by: Wei Liu <wei.liu@zilliz.com>
This commit is contained in:
wei liu 2023-06-15 19:50:39 +08:00 committed by GitHub
parent 4d8d34e370
commit 75adf1df98
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -238,8 +238,8 @@ func (t *SearchTask) Done(err error) {
collector.Counter.Dec(metricsinfo.ExecuteQueueType, 1) collector.Counter.Dec(metricsinfo.ExecuteQueueType, 1)
if len(t.others) > 0 { if len(t.others) > 0 {
metrics.QueryNodeSearchGroupSize.WithLabelValues(fmt.Sprint(paramtable.GetNodeID())).Observe(float64(len(t.others) + 1)) metrics.QueryNodeSearchGroupSize.WithLabelValues(fmt.Sprint(paramtable.GetNodeID())).Observe(float64(len(t.others) + 1))
metrics.QueryNodeSearchGroupNQ.WithLabelValues(fmt.Sprint(paramtable.GetNodeID())).Observe(float64(t.originNqs[0])) metrics.QueryNodeSearchGroupNQ.WithLabelValues(fmt.Sprint(paramtable.GetNodeID())).Observe(float64(t.nq))
metrics.QueryNodeSearchGroupTopK.WithLabelValues(fmt.Sprint(paramtable.GetNodeID())).Observe(float64(t.originTopks[0])) metrics.QueryNodeSearchGroupTopK.WithLabelValues(fmt.Sprint(paramtable.GetNodeID())).Observe(float64(t.topk))
} }
select { select {
case t.notifier <- err: case t.notifier <- err: