diff --git a/internal/proxy/meta_cache.go b/internal/proxy/meta_cache.go index c0749d9db0093e4b7f5c181271fcb98b751276d2..b3b8e6ddbd7216ffc1ca93c19b16b41910f9679e 100644 --- a/internal/proxy/meta_cache.go +++ b/internal/proxy/meta_cache.go @@ -289,7 +289,7 @@ func (m *MetaCache) GetCollectionName(ctx context.Context, database string, coll } } - method := "GeCollectionName" + method := "GetCollectionName" if collInfo == nil || !collInfo.isCollectionCached() { metrics.ProxyCacheStatsCounter.WithLabelValues(fmt.Sprint(paramtable.GetNodeID()), method, metrics.CacheMissLabel).Inc() tr := timerecord.NewTimeRecorder("UpdateCache") diff --git a/internal/proxy/task_search.go b/internal/proxy/task_search.go index 554baae2f6243f7a9459f14277661f18806aa204..8f943ea3a7759fc133d363512870b1d16677f4de 100644 --- a/internal/proxy/task_search.go +++ b/internal/proxy/task_search.go @@ -221,7 +221,11 @@ func (t *searchTask) PreExecute(ctx context.Context) error { t.SearchRequest.DbID = 0 // todo t.SearchRequest.CollectionID = collID - t.schema, _ = globalMetaCache.GetCollectionSchema(ctx, t.request.GetDbName(), collectionName) + t.schema, err = globalMetaCache.GetCollectionSchema(ctx, t.request.GetDbName(), collectionName) + if err != nil { + log.Warn("get collection schema failed", zap.Error(err)) + return err + } partitionKeyMode, err := isPartitionKeyMode(ctx, t.request.GetDbName(), collectionName) if err != nil {