mirror of https://github.com/milvus-io/milvus.git
enhance: Reduce ListImportTasks log content (#28605)
In proxy `ListImportTasks` may print all task information from rootcoord, this may cause log content too large to process This PR make this log print taskID and importState only Signed-off-by: Congqi Xia <congqi.xia@zilliz.com>pull/28627/head
parent
faf38ed8dd
commit
e47fe4e4d1
|
@ -3954,7 +3954,9 @@ func (node *Proxy) ListImportTasks(ctx context.Context, req *milvuspb.ListImport
|
|||
|
||||
log.Debug("successfully received list import tasks response",
|
||||
zap.String("collection", req.CollectionName),
|
||||
zap.Any("tasks", resp.Tasks))
|
||||
zap.Any("tasks", lo.SliceToMap(resp.GetTasks(), func(state *milvuspb.GetImportStateResponse) (int64, commonpb.ImportState) {
|
||||
return state.GetId(), state.GetState()
|
||||
})))
|
||||
metrics.ProxyFunctionCall.WithLabelValues(strconv.FormatInt(paramtable.GetNodeID(), 10), method, metrics.SuccessLabel).Inc()
|
||||
metrics.ProxyReqLatency.WithLabelValues(strconv.FormatInt(paramtable.GetNodeID(), 10), method).Observe(float64(tr.ElapseSpan().Milliseconds()))
|
||||
return resp, err
|
||||
|
|
Loading…
Reference in New Issue