backup: don't Close a volume after Destroy (#12225)

Co-authored-by: user.email <chrislusf@users.noreply.github.com>
This commit is contained in:
Denis Kieftanduser.email authored and GitHub committed 2026-10-29 19:00:15 -07:00
1 parent cd3e2c8b2c
commit a2f595b207
1 file changed
+2 -1
+2 -1
View File
@@ -163,7 +163,8 @@ func backupFromLocation(volumeServer pb.ServerAddress, grpcDialOption grpc.DialO
v.Close()
return fmt.Errorf("destroying volume: %w", err), false
}
v.Close() // Close the destroyed volume
// Destroy already closed v. Closing it again hangs, because Destroy
// leaves the compaction flag set.
// recreate an empty volume
v, err = storage.NewVolume(*s.dir, *s.dir, *s.collection, vid, storage.NeedleMapInMemory, replication, ttl, 0, ver, 0, 0)
if err != nil {