SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.
Go blob-storagecloud-drivedistributed-file-systemdistributed-storageerasure-codingfusehadoop-hdfshdfskuberneteslancelancedbobject-storageposixs3s3-storageseaweedfstiered-file-systemvector-search
fix: cache successful volume lookups instead of failed ones (#7698)
Chris Luae7333d28e77
diff --git a/weed/operation/lookup.go b/weed/operation/lookup.goindex 9e9c719b5a..12ad373306 100644--- a/weed/operation/lookup.go+++ b/weed/operation/lookup.go@@ -4,12 +4,13 @@ import ("context""errors""fmt"- "github.com/seaweedfs/seaweedfs/weed/pb"- "google.golang.org/grpc""math/rand/v2""strings""time"+ "github.com/seaweedfs/seaweedfs/weed/pb"+ "google.golang.org/grpc"+"github.com/seaweedfs/seaweedfs/weed/pb/master_pb")@@ -101,7 +102,7 @@ func LookupVolumeIds(masterFn GetMasterFn, grpcDialOption grpc.DialOption, vidsGrpcPort: int(loc.GrpcPort),})}- if vidLocations.Error != "" {+ if vidLocations.Error == "" {vc.Set(vidLocations.VolumeOrFileId, locations, 10*time.Minute)}ret[vidLocations.VolumeOrFileId] = &LookupResult{