Skip to content

Commit

Permalink
refactor: align S3 multi-part size to fetch part
Browse files Browse the repository at this point in the history
To optimize latency on fetching, AWS recommends for upload part to be the same as ranges to download: https://docs.aws.amazon.com/whitepapers/latest/s3-optimizing-performance-best-practices/use-byte-range-fetches.html
  • Loading branch information
jeqo committed Sep 28, 2023
1 parent 816db12 commit de06ecc
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public class S3StorageConfig extends AbstractConfig {
+ "Valid values: between 5MiB and 2GiB";
static final int S3_MULTIPART_UPLOAD_PART_SIZE_MIN = 5 * 1024 * 1024; // 5MiB
static final int S3_MULTIPART_UPLOAD_PART_SIZE_MAX = Integer.MAX_VALUE;
static final int S3_MULTIPART_UPLOAD_PART_SIZE_DEFAULT = S3_MULTIPART_UPLOAD_PART_SIZE_MIN;
static final int S3_MULTIPART_UPLOAD_PART_SIZE_DEFAULT = 16 * 1024 * 1024; // 16MiB

private static final String S3_API_CALL_TIMEOUT_CONFIG = "s3.api.call.timeout";
private static final String S3_API_CALL_TIMEOUT_DOC = "AWS S3 API call timeout in milliseconds";
Expand Down

0 comments on commit de06ecc

Please sign in to comment.