From: Matt Benjamin Date: Thu, 12 Jul 2018 20:42:29 +0000 (-0400) Subject: rgw: do not ignore EEXIST in RGWPutObj::execute X-Git-Tag: v14.0.1~881^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F23033%2Fhead;p=ceph.git rgw: do not ignore EEXIST in RGWPutObj::execute The existing logic appears able to cause propagation of a failed exclusive create to the client, when it should instead have been retried, due to disagreement about the logical write offset. (The value of ofs here could be > 0 due to the operation of a stacked write filter [e.g., compressor], when the RADOS write offset was 0 and hence an exclusive write that should be retried). Rationale for fix by Casey. http://tracker.ceph.com/issues/22790 Signed-off-by: Matt Benjamin --- diff --git a/src/rgw/rgw_op.cc b/src/rgw/rgw_op.cc index a20146222a0..cf7648a4bb7 100644 --- a/src/rgw/rgw_op.cc +++ b/src/rgw/rgw_op.cc @@ -3635,7 +3635,7 @@ void RGWPutObj::execute() op_ret = put_data_and_throttle(filter, data, ofs, need_to_wait); if (op_ret < 0) { - if (!need_to_wait || op_ret != -EEXIST) { + if (op_ret != -EEXIST) { ldpp_dout(this, 20) << "processor->thottle_data() returned ret=" << op_ret << dendl; goto done;