mount metacache add ttl (#6360)
* fix:mount deadlock * fix * feat: metaCache ttl * Update weed/command/mount.go Co-authored-by: Chris Lu <chrislusf@users.noreply.github.com> * fix InodeEntry --------- Co-authored-by: zemul <zhouzemiao@ihuman.com> Co-authored-by: Chris Lu <chrislusf@users.noreply.github.com>
This commit is contained in:
@@ -42,6 +42,7 @@ type Option struct {
|
||||
CacheDirForRead string
|
||||
CacheSizeMBForRead int64
|
||||
CacheDirForWrite string
|
||||
CacheMetaTTlSec int
|
||||
DataCenter string
|
||||
Umask os.FileMode
|
||||
Quota int64
|
||||
@@ -89,7 +90,7 @@ func NewSeaweedFileSystem(option *Option) *WFS {
|
||||
RawFileSystem: fuse.NewDefaultRawFileSystem(),
|
||||
option: option,
|
||||
signature: util.RandomInt32(),
|
||||
inodeToPath: NewInodeToPath(util.FullPath(option.FilerMountRootPath)),
|
||||
inodeToPath: NewInodeToPath(util.FullPath(option.FilerMountRootPath), option.CacheMetaTTlSec),
|
||||
fhMap: NewFileHandleToInode(),
|
||||
dhMap: NewDirectoryHandleToInode(),
|
||||
fhLockTable: util.NewLockTable[FileHandleId](),
|
||||
|
||||
Reference in New Issue
Block a user