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: exit early if rgw_bucket_set_attrs() fails #17041

Merged
merged 1 commit into from Aug 23, 2017
Merged

Conversation

dengxiafubi
Copy link

@dengxiafubi dengxiafubi commented Aug 16, 2017

Check for the return value of rgw_bucket_set_attrs() and exit earlier in case of
errors

Signed-off-by: dengxiafubi xhwcqupt@sina.com

Copy link
Member

@joscollin joscollin left a comment

Choose a reason for hiding this comment

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

  1. Please provide an appropriate PR Title and Commit Title that reflects your fix.

  2. What about providing an error message when rgw_bucket_set_attrs() fails.
    https://github.com/dengxiafubi/ceph/blob/ec4fe64ad7bce5bcc597a2da56ef6860ebaba1e8/src/rgw/rgw_op.cc#L4738

Signed-off-by: dengxiafubi 670318146@qq.com

Is this your correct email ID used for signing off ? Use the appropriate email ID for signing off and put this email ID in the .mailmap.

@dengxiafubi dengxiafubi changed the title rgw:the return value requires exception handling rgw:the returned value of rgw_bucket_set_attrs() reuires exception handling Aug 16, 2017
@@ -4775,6 +4775,11 @@ void RGWDeleteLC::execute()
}
}
op_ret = rgw_bucket_set_attrs(store, s->bucket_info, attrs, &s->bucket_info.objv_tracker);
if (op_ret < 0) {
dout(0) << "RGWLC::RGWDeleteLC() failed to set attrs on bucket=" << s->bucket.name
Copy link
Member

Choose a reason for hiding this comment

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

while you're at it, also move from dout-> ldout(s->cct,0)

Copy link
Member

Choose a reason for hiding this comment

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

@theanalyst Do you mean move the other dout's in execute() too ?

the returned value of rgw_bucket_set_attrs() reuires exception handling

Signed-off-by: dengxiafubi <xhwcqupt@sina.com>
@dengxiafubi dengxiafubi changed the title rgw:the returned value of rgw_bucket_set_attrs() reuires exception handling rgw:rgw_op: exit early if set attrs error in rgw_bucket_set_attrs() Aug 17, 2017
@dengxiafubi
Copy link
Author

@joscollin update

@dengxiafubi
Copy link
Author

@theanalyst update

@joscollin joscollin changed the title rgw:rgw_op: exit early if set attrs error in rgw_bucket_set_attrs() rgw: exit early if rgw_bucket_set_attrs() fails Aug 17, 2017
@dengxiafubi
Copy link
Author

@joscollin please help to review this pr ,thx

@alfredodeza
Copy link
Contributor

jenkins test docs

@yuriw yuriw merged commit 7281f59 into ceph:master Aug 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants