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

rgw: AbortMultipart request returns NoSuchUpload error if the meta obj doesn't exist #12793

Merged
merged 1 commit into from Mar 14, 2017

Conversation

Projects
None yet
3 participants
@zhangsw
Copy link
Contributor

zhangsw commented Jan 5, 2017

In abort multipart request, we delete the meta obj after we delete all uploaded parts. If the meta obj doesn't exist, we return NoSuchUpload.

Signed-off-by: Zhang Shaowen zhangshaowen@cmss.chinamobile.com

@zhangsw

This comment has been minimized.

Copy link
Contributor Author

zhangsw commented Feb 16, 2017

@cbodley please help review this ,thanks~

@cbodley cbodley self-assigned this Feb 16, 2017

@cbodley

This comment has been minimized.

Copy link
Contributor

cbodley commented Feb 16, 2017

hi @zhangsw, can you explain how you're able to reproduce these errors? it looks like RGWAbortMultipart::execute() is first calling get_multipart_info() to read this object. so a failure to delete it later means that there was a race somewhere. are you sending multiple abort requests at once?

@zhangsw

This comment has been minimized.

Copy link
Contributor Author

zhangsw commented Feb 17, 2017

@cbodley Actually I haven't met this problem. I find this when I read the code about multipart upload. I think if sending multipart requests at once or lifecycle supports the multipart expiraton, it may occur.

@cbodley

This comment has been minimized.

Copy link
Contributor

cbodley commented Feb 17, 2017

@zhangsw in either of those cases, i think that returning an error is the right thing to do. 404 NoSuchBucket seems like an odd choice, though - NoSuchUpload is what i'd expect as a client if i sent two abort requests for the same upload

@zhangsw

This comment has been minimized.

Copy link
Contributor Author

zhangsw commented Feb 20, 2017

@cbodley I first compare this with delete object request that won't return error if the object doesn't exist. But the abort multipart upload is a little different. I think NoSuchUpload is the better choice.

rgw: AbortMultipart request returns NoSuchUpload if the meta obj doesn't
exist.

Signed-off-by: Zhang Shaowen <zhangshaowen@cmss.chinamobile.com>

@zhangsw zhangsw force-pushed the zhangsw:fix-rgw-abortmultipart branch from 990a6b7 to b1525e6 Feb 20, 2017

@zhangsw zhangsw changed the title rgw: AbortMultipart request needn't return error if the meta obj doesn't exist rgw: AbortMultipart request returns NoSuchUpload error if the meta obj doesn't exist Feb 20, 2017

@zhangsw

This comment has been minimized.

Copy link
Contributor Author

zhangsw commented Feb 20, 2017

@cbodley I've updated it.

@cbodley cbodley merged commit 67ffcf8 into ceph:master Mar 14, 2017

3 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodifed Submodules submodules for project are unmodified
Details
default Build finished.
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.