mirror of https://github.com/milvus-io/milvus.git
Fix rootcoord too frequent useless log (#20044)
Signed-off-by: longjiquan <jiquan.long@zilliz.com> Signed-off-by: longjiquan <jiquan.long@zilliz.com>pull/19893/head
parent
377cd210c2
commit
290b902ab0
|
@ -31,13 +31,19 @@ func (s *stepStack) Execute(ctx context.Context) *stepStack {
|
|||
l := len(steps)
|
||||
todo := steps[l-1]
|
||||
childSteps, err := todo.Execute(ctx)
|
||||
// TODO: maybe a interface `step.LogOnError` is better.
|
||||
_, skipLog := todo.(*waitForTsSyncedStep)
|
||||
if retry.IsUnRecoverable(err) {
|
||||
log.Warn("failed to execute step, not able to reschedule", zap.Error(err), zap.String("step", todo.Desc()))
|
||||
if !skipLog {
|
||||
log.Warn("failed to execute step, not able to reschedule", zap.Error(err), zap.String("step", todo.Desc()))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
if err != nil {
|
||||
s.steps = nil // let s can be collected.
|
||||
log.Warn("failed to execute step, wait for reschedule", zap.Error(err), zap.String("step", todo.Desc()))
|
||||
if !skipLog {
|
||||
log.Warn("failed to execute step, wait for reschedule", zap.Error(err), zap.String("step", todo.Desc()))
|
||||
}
|
||||
return &stepStack{steps: steps}
|
||||
}
|
||||
// this step is done.
|
||||
|
|
Loading…
Reference in New Issue