Repository navigation
s3: respect partSize if size unknown - #289
Merged
Merged
Conversation
GiedriusS
force-pushed
the
respect-partsize
branch
3 times, most recently
from
October 9, 2026 11:16
3669d24 to
a404500
Compare
MichaHoffmann
approved these changes
Oct 9, 2026
If the size of the upload is unknown then with the current version partSize is also ignored. This causes a problem where I am streaming results (e.g. thanos-parquet-gateway) and know that the resulting file will never be that huge to exceed the limit of part size * number of parts. Now it allocates a lot of memory conservatively to get the maximum possible object size. See https://github.com/minio/minio-go/blob/master/docs/API.md#PutObject.md and this https://github.com/minio/minio-go/blob/master/api-put-object-common.go#L90-L92. Cleanup one linter message while going through this function. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
GiedriusS
force-pushed
the
respect-partsize
branch
from
October 9, 2026 12:40
a404500 to
3952d53
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.
If the size of the upload is unknown then with the current version partSize is also ignored. This causes a problem where I am streaming results (e.g. thanos-parquet-gateway) and know that the resulting file will never be that huge to exceed the limit of part size * number of parts. Now it allocates a lot of memory conservatively to get the maximum possible object size. See
https://github.com/minio/minio-go/blob/master/docs/API.md#PutObject.md and this
https://github.com/minio/minio-go/blob/master/api-put-object-common.go#L90-L92.
Cleanup one linter message while going through this function.