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
refactor
chrislu15b66a663314
diff --git a/weed/command/filer_remote_sync_dir.go b/weed/command/filer_remote_sync_dir.goindex 00f6d74931..dd3e94be6e 100644--- a/weed/command/filer_remote_sync_dir.go+++ b/weed/command/filer_remote_sync_dir.go@@ -278,7 +278,10 @@ func updateLocalEntry(filerClient filer_pb.FilerClient, dir string, entry *filer}func isMultipartUploadFile(dir string, name string) bool {+ return isMultipartUploadDir(dir) && strings.HasSuffix(name, ".part")+}++func isMultipartUploadDir(dir string) bool {return strings.HasPrefix(dir, "/buckets/") &&- strings.Contains(dir, "/"+s3_constants.MultipartUploadsFolder+"/") &&- strings.HasSuffix(name, ".part")+ strings.Contains(dir, "/"+s3_constants.MultipartUploadsFolder+"/")}diff --git a/weed/command/filer_sync.go b/weed/command/filer_sync.goindex d84c6325c8..dc954e805d 100644--- a/weed/command/filer_sync.go+++ b/weed/command/filer_sync.go@@ -394,9 +394,11 @@ func genProcessFunction(sourcePath string, targetPath string, excludePaths []strif debug {glog.V(0).Infof("received %v", resp)}- if strings.Contains(resp.Directory, "/"+s3_constants.MultipartUploadsFolder+"/") {++ if isMultipartUploadDir(resp.Directory) {return nil}+if !strings.HasPrefix(resp.Directory, sourcePath) {return nil}