aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2020-12-21 23:19:05 -0800
committerChris Lu <chris.lu@gmail.com>2020-12-21 23:19:05 -0800
commitc74bede730be11c0c0847bbb6c5ec36aac5388d6 (patch)
tree9e35e3c52011c548bc34e71ff7d2c63be4369e12
parentadf8cb40006e94da44b9e5eabc8fc31729abb898 (diff)
downloadseaweedfs-c74bede730be11c0c0847bbb6c5ec36aac5388d6.tar.xz
seaweedfs-c74bede730be11c0c0847bbb6c5ec36aac5388d6.zip
handle listing directories
-rw-r--r--weed/filer/filerstore_wrapper.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/weed/filer/filerstore_wrapper.go b/weed/filer/filerstore_wrapper.go
index dff869c7f..ba26ca41b 100644
--- a/weed/filer/filerstore_wrapper.go
+++ b/weed/filer/filerstore_wrapper.go
@@ -183,7 +183,7 @@ func (fsw *FilerStoreWrapper) DeleteOneEntry(ctx context.Context, existingEntry
}
func (fsw *FilerStoreWrapper) DeleteFolderChildren(ctx context.Context, fp util.FullPath) (err error) {
- actualStore := fsw.getActualStore(fp)
+ actualStore := fsw.getActualStore(fp+"/")
stats.FilerStoreCounter.WithLabelValues(actualStore.GetName(), "deleteFolderChildren").Inc()
start := time.Now()
defer func() {
@@ -195,7 +195,7 @@ func (fsw *FilerStoreWrapper) DeleteFolderChildren(ctx context.Context, fp util.
}
func (fsw *FilerStoreWrapper) ListDirectoryEntries(ctx context.Context, dirPath util.FullPath, startFileName string, includeStartFile bool, limit int) ([]*Entry, error) {
- actualStore := fsw.getActualStore(dirPath)
+ actualStore := fsw.getActualStore(dirPath+"/")
stats.FilerStoreCounter.WithLabelValues(actualStore.GetName(), "list").Inc()
start := time.Now()
defer func() {
@@ -215,7 +215,7 @@ func (fsw *FilerStoreWrapper) ListDirectoryEntries(ctx context.Context, dirPath
}
func (fsw *FilerStoreWrapper) ListDirectoryPrefixedEntries(ctx context.Context, dirPath util.FullPath, startFileName string, includeStartFile bool, limit int, prefix string) ([]*Entry, error) {
- actualStore := fsw.getActualStore(dirPath)
+ actualStore := fsw.getActualStore(dirPath+"/")
stats.FilerStoreCounter.WithLabelValues(actualStore.GetName(), "prefixList").Inc()
start := time.Now()
defer func() {