Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] - CompleteMultipartUpload lower limit of uploading parts size #960

Open
0x180 opened this issue Nov 20, 2024 · 0 comments · May be fixed by #988
Open

[Bug] - CompleteMultipartUpload lower limit of uploading parts size #960

0x180 opened this issue Nov 20, 2024 · 0 comments · May be fixed by #988
Labels
bug Something isn't working

Comments

@0x180
Copy link
Contributor

0x180 commented Nov 20, 2024

Describe the bug
When initiating a multipart upload, all uploaded parts should have the same size (except for the last part) and must be between 5 MiB and 5 GiB. If more than two parts are uploaded and any part is smaller than 5 MiB, the CompleteMultipartUpload operation should fail.

To Reproduce

aws s3api create-bucket --bucket test

aws s3api create-multipart-upload --bucket test --key obj

// file_1 should be smaller than 5Mib
aws s3api upload-part --bucket test --key obj --upload-id <mp_upload_id> --part-number 1 --body file_1

// file_2 should be smaller than 5Mib
aws s3api upload-part --bucket test --key obj --upload-id <mp_upload_id> --part-number 2 --body file_2

aws s3api complete-multipart-upload --bucket test --key obj --upload-id <mp_upload_id> --multipart-upload '{"Parts": [{"ETag": "<file_1_ETag>", "PartNumber": 1}, {"ETag": "file_2_ETag", "PartNumber": 2}]}'

Expected behavior
CompleteMultipartUpload should return the following error:

An error occurred (EntityTooSmall) when calling the CompleteMultipartUpload operation: Your proposed upload is smaller than the minimum allowed size
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: No status
Development

Successfully merging a pull request may close this issue.

1 participant