Skip to content

s3: Add a test for attempting to complete an unstarted multipart upload#728

Open
jacquesh wants to merge 2 commits intoceph:masterfrom
jacquesh:add-complete-unstarted-multipart-upload
Open

s3: Add a test for attempting to complete an unstarted multipart upload#728
jacquesh wants to merge 2 commits intoceph:masterfrom
jacquesh:add-complete-unstarted-multipart-upload

Conversation

@jacquesh
Copy link
Copy Markdown

The AWS documentation for CompleteMultipartUpload specifies that the call will return a 404 with the text "NoSuchUpload" to indicate that the specified multipart upload does not exist. This could be the result of an invalid upload ID or a multipart upload that has been aborted or completed.

Of particular significance is the requirement that this API call return a 400-series error (indicating a client-side problem) and not a 500-series error (indicating a server-size problem).
At the time of writing, Ceph returns a 500 in this scenario which may be handled incorrectly by client SDKs and is likely to be misinterpreted by Ceph monitoring as an increase in errors that require operator intervention to fix.

Since this test currently fails, I've marked it as fails_on_rgw and created a tracker for the issue.

The AWS documentation for CompleteMultipartUpload specifies that the call will
return a 404 with the text "NoSuchUpload" to indicate that the specified
multipart upload does not exist. This could be the result of an invalid upload
ID or a multipart upload that has been aborted or completed.

Of particular significance is the requirement that this API call return a
400-series error (indicating a client-side problem) and not a 500-series error
(indicating a server-size problem).
At the time of writing, Ceph returns a 500 in this scenario which may be
handled incorrectly by client SDKs and is likely to be misinterpreted by Ceph
monitoring as an increase in errors that require operator intervention to fix.

CompleteMultipartUpload docs available at:
https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html

Signed-off-by: Jacques Heunis <jheunis@bloomberg.net>
Comment thread s3tests/functional/test_s3.py Outdated
assert status == 400
assert error_code == 'MalformedXML'

@pytest.mark.fails_on_rgw # TODO: Remove fails_on_rgw when https://tracker.ceph.com/issues/75534 is fixed
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks very much for the test case. would you kindly remove this fails_on_rgw marker so i can use this to validate the fix in ceph/ceph#68186?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gladly! Removed.

Signed-off-by: Jacques Heunis <jheunis@bloomberg.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants