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
small optimization
Chris Lu07f20155fdce
diff --git a/weed/filesys/file.go b/weed/filesys/file.goindex c50ac0549d..8f58511e22 100644--- a/weed/filesys/file.go+++ b/weed/filesys/file.go@@ -144,17 +144,17 @@ func (file *File) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *ffile.dirtyMetadata = true}- if req.Valid.Mode() {+ if req.Valid.Mode() && entry.Attributes.FileMode != uint32(req.Mode){entry.Attributes.FileMode = uint32(req.Mode)file.dirtyMetadata = true}- if req.Valid.Uid() {+ if req.Valid.Uid() && entry.Attributes.Uid != req.Uid {entry.Attributes.Uid = req.Uidfile.dirtyMetadata = true}- if req.Valid.Gid() {+ if req.Valid.Gid() && entry.Attributes.Gid != req.Gid {entry.Attributes.Gid = req.Gidfile.dirtyMetadata = true}@@ -164,7 +164,7 @@ func (file *File) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *ffile.dirtyMetadata = true}- if req.Valid.Mtime() {+ if req.Valid.Mtime() && entry.Attributes.Mtime != req.Mtime.Unix() {entry.Attributes.Mtime = req.Mtime.Unix()file.dirtyMetadata = true}