Skip to content

Commit 4434812

Browse files
fix restore test
1 parent 19fbe6c commit 4434812

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

worker/backup.go

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -301,12 +301,10 @@ func ProcessBackupRequest(ctx context.Context, req *pb.BackupRequest) error {
301301

302302
for _, pred := range schema {
303303
if pred.Type == "float32vector" && len(pred.IndexSpecs) != 0 {
304-
vecPredMap[gid] = append(predMap[gid], pred.Predicate+hnsw.VecEntry, pred.Predicate+hnsw.VecKeyword,
305-
pred.Predicate+hnsw.VecDead, pred.Predicate+kmeans.CentroidPrefix)
306304
for _, spec := range pred.IndexSpecs {
307305
if spec.Name == partitioned_hnsw.PartitionedHNSW {
306+
vecPredMap[gid] = append(predMap[gid], pred.Predicate+kmeans.CentroidPrefix)
308307
for _, opt := range spec.Options {
309-
310308
if opt.Key == partitioned_hnsw.NumClustersOpt {
311309
numClusters, err := strconv.Atoi(opt.Value)
312310
if err != nil {
@@ -321,6 +319,9 @@ func ProcessBackupRequest(ctx context.Context, req *pb.BackupRequest) error {
321319
}
322320
}
323321
}
322+
} else {
323+
vecPredMap[gid] = append(predMap[gid], pred.Predicate+hnsw.VecEntry, pred.Predicate+hnsw.VecKeyword,
324+
pred.Predicate+hnsw.VecDead)
324325
}
325326
}
326327
}

0 commit comments

Comments
 (0)