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
Chris Lu55e060cf619d
diff --git a/weed/filesys/dirty_page.go b/weed/filesys/dirty_page.goindex ab191a07a6..25f1d31c28 100644--- a/weed/filesys/dirty_page.go+++ b/weed/filesys/dirty_page.go@@ -144,3 +144,7 @@ func min(x, y int64) int64 {func (pages *ContinuousDirtyPages) ReadDirtyDataAt(data []byte, startOffset int64) (maxStop int64) {return pages.intervals.ReadDataAt(data, startOffset)}++func (pages *ContinuousDirtyPages) GetStorageOptions() (collection, replication string) {+ return pages.collection, pages.replication+}diff --git a/weed/filesys/filehandle.go b/weed/filesys/filehandle.goindex 3e0567dee6..3ccd996ae5 100644--- a/weed/filesys/filehandle.go+++ b/weed/filesys/filehandle.go@@ -267,8 +267,7 @@ func (fh *FileHandle) doFlush(ctx context.Context, header fuse.Header) error {}entry.Attributes.Mtime = time.Now().Unix()entry.Attributes.FileMode = uint32(os.FileMode(entry.Attributes.FileMode) &^ fh.f.wfs.option.Umask)- entry.Attributes.Collection = fh.dirtyPages.collection- entry.Attributes.Replication = fh.dirtyPages.replication+ entry.Attributes.Collection, entry.Attributes.Replication = fh.dirtyPages.GetStorageOptions()}request := &filer_pb.CreateEntryRequest{