mirror of
https://gitee.com/milvus-io/milvus.git
synced 2026-01-07 19:31:51 +08:00
Fix flush failure caused by empty stale segments (#18097)
/bug issue: #18096 Signed-off-by: Yuchen Gao <yuchen.gao@zilliz.com>
This commit is contained in:
parent
79523ff8d4
commit
d4a1e94f32
@ -641,7 +641,8 @@ func (s *Server) getStaleSegmentsInfo(ch string) []*SegmentInfo {
|
||||
return isSegmentHealthy(info) &&
|
||||
info.GetInsertChannel() == ch &&
|
||||
!info.lastFlushTime.IsZero() &&
|
||||
time.Since(info.lastFlushTime).Minutes() >= segmentTimedFlushDuration
|
||||
time.Since(info.lastFlushTime).Minutes() >= segmentTimedFlushDuration &&
|
||||
info.GetNumOfRows() != 0
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
@ -621,8 +621,7 @@ func (node *DataNode) FlushSegments(ctx context.Context, req *datapb.FlushSegmen
|
||||
log.Info("flow graph flushSegment tasks triggered",
|
||||
zap.Bool("flushed", flushed),
|
||||
zap.Int64("collection ID", req.GetCollectionID()),
|
||||
zap.Int64s("segments", segmentIDs),
|
||||
zap.Int64s("mark segments", req.GetMarkSegmentIDs()))
|
||||
zap.Int64s("segments", segmentIDs))
|
||||
return flushedSeg, noErr
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user