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: release cls lock if taken in RGWCompleteMultipart #18104

Merged
merged 1 commit into from Oct 11, 2017

Conversation

mattbenjamin
Copy link
Contributor

Follows Casey's proposal to conditionally release the lock in
::complete(), in order to avoid duplicated code in various early
return cases.

Fixes: http://tracker.ceph.com/issues/21596

Signed-off-by: Matt Benjamin mbenjamin@redhat.com

Copy link
Contributor

@cbodley cbodley left a comment

Choose a reason for hiding this comment

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

i like the MPSerializer 👍

@@ -5583,11 +5577,34 @@ void RGWCompleteMultipart::execute()
s->bucket_info, meta_obj, 0);
if (r < 0) {
ldout(store->ctx(), 0) << "WARNING: failed to remove object " << meta_obj << dendl;
r = l.unlock(&ioctx, raw_meta_oid);
Copy link
Contributor

Choose a reason for hiding this comment

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

if this delete succeeds, you can set locked=false to avoid sending the unlock

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ah, right

Follows Casey's proposal to conditionally release the lock in
::complete(), in order to avoid duplicated code in various early
return cases.

Fixes: http://tracker.ceph.com/issues/21596

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
@cbodley
Copy link
Contributor

cbodley commented Oct 4, 2017

jenkins test this please

@yuriw
Copy link
Contributor

yuriw commented Oct 10, 2017

@yuriw yuriw merged commit 86256e1 into ceph:master Oct 11, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants