filer: speed up filer.meta.save by parallelizing

This commit is contained in:
Chris Lu
2019-12-06 22:20:59 -08:00
parent f38f90b7ea
commit f81d43442b
3 changed files with 111 additions and 12 deletions

View File

@@ -50,7 +50,7 @@ func (c *commandFsMetaNotify) Do(args []string, commandEnv *CommandEnv, writer i
var dirCount, fileCount uint64
err = doTraverse(ctx, writer, client, filer2.FullPath(path), func(parentPath filer2.FullPath, entry *filer_pb.Entry) error {
err = doTraverseBFS(ctx, writer, client, filer2.FullPath(path), func(parentPath filer2.FullPath, entry *filer_pb.Entry) error {
if entry.IsDirectory {
dirCount++