mirror of
https://github.com/rclone/rclone.git
synced 2025-12-11 22:14:05 +01:00
chunkedreader: add --vfs-read-chunk-streams to parallel read chunks
This converts the ChunkedReader into an interface and provides two implementations one sequential and one parallel. This can be used to improve the performance of the VFS on high bandwidth or high latency links. Fixes #4760
This commit is contained in:
@@ -79,6 +79,11 @@ var OptionsInfo = fs.Options{{
|
||||
Default: fs.SizeSuffix(-1),
|
||||
Help: "If greater than --vfs-read-chunk-size, double the chunk size after each chunk read, until the limit is reached ('off' is unlimited)",
|
||||
Groups: "VFS",
|
||||
}, {
|
||||
Name: "vfs_read_chunk_streams",
|
||||
Default: 0,
|
||||
Help: "The number of parallel streams to read at once",
|
||||
Groups: "VFS",
|
||||
}, {
|
||||
Name: "dir_perms",
|
||||
Default: FileMode(0777),
|
||||
@@ -171,6 +176,7 @@ type Options struct {
|
||||
FilePerms FileMode `config:"file_perms"`
|
||||
ChunkSize fs.SizeSuffix `config:"vfs_read_chunk_size"` // if > 0 read files in chunks
|
||||
ChunkSizeLimit fs.SizeSuffix `config:"vfs_read_chunk_size_limit"` // if > ChunkSize double the chunk size after each chunk until reached
|
||||
ChunkStreams int `config:"vfs_read_chunk_streams"` // Number of download streams to use
|
||||
CacheMode CacheMode `config:"vfs_cache_mode"`
|
||||
CacheMaxAge fs.Duration `config:"vfs_cache_max_age"`
|
||||
CacheMaxSize fs.SizeSuffix `config:"vfs_cache_max_size"`
|
||||
|
||||
Reference in New Issue
Block a user