diff --git a/internal/datanode/flow_graph_time_ticker.go b/internal/datanode/flow_graph_time_ticker.go index d49ff67009..a05b407091 100644 --- a/internal/datanode/flow_graph_time_ticker.go +++ b/internal/datanode/flow_graph_time_ticker.go @@ -21,7 +21,9 @@ import ( "time" "github.com/milvus-io/milvus/internal/log" + "github.com/samber/lo" "go.uber.org/zap" + "golang.org/x/exp/maps" ) type sendTimeTick func(Timestamp, []int64) error @@ -124,6 +126,11 @@ func (mt *mergedTimeTickerSender) work() { if isDiffTs { if err := mt.send(lastTs, sids); err != nil { log.Error("send hard time tick failed", zap.Error(err)) + mt.mu.Lock() + maps.Copy(mt.segmentIDs, lo.SliceToMap(sids, func(t int64) (int64, struct{}) { + return t, struct{}{} + })) + mt.mu.Unlock() } } }