mount: rename to dirListCacheLimit to configure cache for long format directory list

This commit is contained in:
Chris Lu
2019-12-13 10:22:24 -08:00
parent 3e0cd122d8
commit f59119cd1d
3 changed files with 7 additions and 7 deletions

View File

@@ -27,7 +27,7 @@ type Option struct {
TtlSec int32
ChunkSizeLimit int64
DataCenter string
DirListingLimit int64
DirListCacheLimit int64
EntryCacheTtl time.Duration
Umask os.FileMode
@@ -61,7 +61,7 @@ type statsCache struct {
func NewSeaweedFileSystem(option *Option) *WFS {
wfs := &WFS{
option: option,
listDirectoryEntriesCache: ccache.New(ccache.Configure().MaxSize(option.DirListingLimit * 3).ItemsToPrune(100)),
listDirectoryEntriesCache: ccache.New(ccache.Configure().MaxSize(option.DirListCacheLimit * 3).ItemsToPrune(100)),
pathToHandleIndex: make(map[string]int),
bufPool: sync.Pool{
New: func() interface{} {