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
reset cache for each new release
Chris Lue3e00d36c51c
diff --git a/weed/filesys/wfs.go b/weed/filesys/wfs.goindex 9f7936f004..1bd36167b9 100644--- a/weed/filesys/wfs.go+++ b/weed/filesys/wfs.go@@ -53,7 +53,7 @@ var _ = fs.FS(&WFS{})var _ = fs.FSStatfser(&WFS{})type WFS struct {- option *Option+ option *Option// contains all open handles, protected by handlesLockhandlesLock sync.Mutex@@ -76,15 +76,15 @@ type statsCache struct {func NewSeaweedFileSystem(option *Option) *WFS {wfs := &WFS{- option: option,- handles: make(map[uint64]*FileHandle),+ option: option,+ handles: make(map[uint64]*FileHandle),bufPool: sync.Pool{New: func() interface{} {return make([]byte, option.ChunkSizeLimit)},},}- cacheUniqueId := util.Md5([]byte(option.FilerGrpcAddress))[0:4]+ cacheUniqueId := util.Md5([]byte(option.FilerGrpcAddress + option.FilerMountRootPath + util.Version()))[0:4]cacheDir := path.Join(option.CacheDir, cacheUniqueId)if option.CacheSizeMB > 0 {os.MkdirAll(cacheDir, 0755)