diff --git a/src/rgw/rgw_op.cc b/src/rgw/rgw_op.cc index d166a22a457be..9d2de94970b34 100644 --- a/src/rgw/rgw_op.cc +++ b/src/rgw/rgw_op.cc @@ -2283,8 +2283,9 @@ void RGWGetObj::execute(optional_yield y) if (m.get_tier_type() == "cloud-s3") { /* XXX: Instead send presigned redirect or read-through */ op_ret = -ERR_INVALID_OBJECT_STATE; - ldpp_dout(this, 0) << "ERROR: Cannot get cloud tiered object. Failing with " - << op_ret << dendl; + s->err.message = "This object was transitioned to cloud-s3"; + ldpp_dout(this, 4) << "Cannot get cloud tiered object. Failing with " + << op_ret << dendl; goto done_err; } } catch (const buffer::end_of_buffer&) { @@ -4090,7 +4091,8 @@ void RGWPutObj::execute(optional_yield y) decode(m, bl); if (m.get_tier_type() == "cloud-s3") { op_ret = -ERR_INVALID_OBJECT_STATE; - ldpp_dout(this, 0) << "ERROR: Cannot copy cloud tiered object. Failing with " + s->err.message = "This object was transitioned to cloud-s3"; + ldpp_dout(this, 4) << "Cannot copy cloud tiered object. Failing with " << op_ret << dendl; return; } @@ -5547,7 +5549,8 @@ void RGWCopyObj::execute(optional_yield y) decode(m, bl); if (m.get_tier_type() == "cloud-s3") { op_ret = -ERR_INVALID_OBJECT_STATE; - ldpp_dout(this, 0) << "ERROR: Cannot copy cloud tiered object. Failing with " + s->err.message = "This object was transitioned to cloud-s3"; + ldpp_dout(this, 4) << "Cannot copy cloud tiered object. Failing with " << op_ret << dendl; return; }