fix: lost DroppedAt field when DropCollection (#33766)

issue: #33097

Signed-off-by: chyezh <chyezh@outlook.com>
pull/33805/head
chyezh 2024-06-12 20:21:56 +08:00 committed by GitHub
parent be3559e022
commit b3ee1a4bd5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 0 deletions

View File

@ -1803,6 +1803,9 @@ func updateSegStateAndPrepareMetrics(segToUpdate *SegmentInfo, targetState commo
zap.Int64("# of rows", segToUpdate.GetNumOfRows()))
metricMutation.append(segToUpdate.GetState(), targetState, segToUpdate.GetLevel(), segToUpdate.GetNumOfRows())
segToUpdate.State = targetState
if targetState == commonpb.SegmentState_Dropped {
segToUpdate.DroppedAt = uint64(time.Now().UnixNano())
}
}
func (m *meta) ListCollections() []int64 {