fix: Deprecated shard leader cache while deprecating collection (#30446)

Resolves: #30445

Signed-off-by: Congqi Xia <congqi.xia@zilliz.com>
pull/30464/head
congqixia 2024-02-02 09:11:05 +08:00 committed by GitHub
parent e0ed5647b3
commit 1c1dd48b71
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 0 deletions

View File

@ -122,6 +122,7 @@ func (node *Proxy) InvalidateCollectionMetaCache(ctx context.Context, request *p
case commonpb.MsgType_DropCollection, commonpb.MsgType_RenameCollection, commonpb.MsgType_DropAlias, commonpb.MsgType_AlterAlias:
if collectionName != "" {
globalMetaCache.RemoveCollection(ctx, request.GetDbName(), collectionName) // no need to return error, though collection may be not cached
globalMetaCache.DeprecateShardCache(request.GetDbName(), collectionName)
}
if request.CollectionID != UniqueID(0) {
aliasName = globalMetaCache.RemoveCollectionsByID(ctx, collectionID)