Add ability to configure io chunksize #35
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is very important for environments that have very fast bandwidth and slow disk writes because if the io chunksize is too small it starts to become the bottleneck when downloading files.
This will be used to help address this issue: boto/boto3#691 as io chunksize configuration is needed to reach the CLI-level performance on those types of environments.
The reason we just do not update the default
STREAM_CHUNK_SIZE
to 1MB is that will totally destroy the granularity of callbacks and is not great for slow connections.As more evidence for this change, the functional tests even needed the change as we would currently patch and return the value of
STREAM_CHUNKS_SIZE
in some of the functional download tests, which is a little hacky.cc @jamesls @JordonPhillips