filer: add option to cache small files to filer store

This commit is contained in:
Chris Lu
2020-12-04 22:39:43 -08:00
parent d171d9f988
commit 263eb29e9f
4 changed files with 6 additions and 1 deletions

View File

@@ -236,7 +236,7 @@ func (fs *FilerServer) uploadReaderToChunks(w http.ResponseWriter, r *http.Reque
break
}
}
if chunkOffset < 2048 {
if chunkOffset < fs.option.CacheToFilerLimit {
smallContent = content
}
return fileChunks, md5Hash, chunkOffset, nil, smallContent