mirror of
https://gitee.com/milvus-io/milvus.git
synced 2026-01-07 19:31:51 +08:00
fix:add exclusive lock mutex in DropSegmentsOfPartition (#41619)
issue:https://github.com/milvus-io/milvus/issues/41615 --------- Signed-off-by: Xianhui.Lin <xianhui.lin@zilliz.com>
This commit is contained in:
parent
1510dea7e3
commit
d41f6839e9
@ -2190,8 +2190,8 @@ func (m *meta) getSegmentsMetrics(collectionID int64) []*metricsinfo.Segment {
|
||||
}
|
||||
|
||||
func (m *meta) DropSegmentsOfPartition(ctx context.Context, partitionIDs []int64) error {
|
||||
m.segMu.RLock()
|
||||
defer m.segMu.RUnlock()
|
||||
m.segMu.Lock()
|
||||
defer m.segMu.Unlock()
|
||||
|
||||
// Filter out the segments of the partition to be dropped.
|
||||
metricMutation := &segMetricMutation{
|
||||
|
||||
@ -193,6 +193,10 @@ func (b *brokerMetaWriter) NotifyDropPartition(ctx context.Context, collectionID
|
||||
return false, nil
|
||||
}, b.opts...)
|
||||
if err != nil {
|
||||
if errors.Is(err, merr.ErrServiceUnimplemented) {
|
||||
log.Info("NotifyDropPartition is not supported, skip")
|
||||
return nil
|
||||
}
|
||||
log.Warn("failed to notify drop partition",
|
||||
zap.String("channel", channelName),
|
||||
zap.Int64("collectionID", collectionID),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user