feat(s3): Port hive.s3.min-part-size and enforce minimum part size#16935
Open
czentgr wants to merge 1 commit intofacebookincubator:mainfrom
Open
feat(s3): Port hive.s3.min-part-size and enforce minimum part size#16935czentgr wants to merge 1 commit intofacebookincubator:mainfrom
czentgr wants to merge 1 commit intofacebookincubator:mainfrom
Conversation
✅ Deploy Preview for meta-velox canceled.
|
This PR introduces the hive.s3.min-part-size option available in Presto Java. It defines the minimum size of a buffer before multipart uploads are used. As a result files less than the min-part-size are sent in a single PUT request. Previously, even smaller files were sent through the multi-part upload. However, AWS limits the minimum size of a part to 5MB. As a result, some S3 backends such as Apache Ozone ignored uploads of parts with less than 5MB leading to errors when finishing the multi-part upload. The default part size is 10MB to match the existing hard coded value. Every part is of size min-part-size to conform to other S3 backends where each part size must be exactly the same size except the last part. As a result min-part-size is also the effective part size. Therefore, this change may affect performance with the default configuration.
2231e30 to
f3dcfb6
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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 PR introduces the hive.s3.min-part-size option available in Presto Java. It defines the minimum size of a buffer before multipart uploads are used. As a result files less than the min-part-size are sent in a single PUT request. Previously, even smaller files were sent through the multi-part upload. However, AWS limits the minimum size of a part to 5MB.
As a result, some S3 backends such as Apache Ozone ignored uploads of parts with less than 5MB leading to errors when finishing the multi-part upload.
The default part size is 10MB to match the existing hard coded value. Every part is of size min-part-size to conform to other S3 backends where each part size must be exactly the same size except the last part. As a result min-part-size is also the effective part size. Therefore, this change may affect performance with the default configuration.