From: Yehuda Sadeh Date: Wed, 15 Feb 2017 00:18:53 +0000 (-0800) Subject: rgw: log unlink_instance mtime as object's mtime X-Git-Tag: v10.2.11~30^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F21213%2Fhead;p=ceph.git rgw: log unlink_instance mtime as object's mtime This is needed so that when squashing entries during data sync we get a consistent mtime for that object. Signed-off-by: Yehuda Sadeh (cherry picked from commit bef22609de95843008b5d02eb075252bb97fbe90) --- diff --git a/src/cls/rgw/cls_rgw.cc b/src/cls/rgw/cls_rgw.cc index f7bfd48da8887..dff3cc065f43d 100644 --- a/src/cls/rgw/cls_rgw.cc +++ b/src/cls/rgw/cls_rgw.cc @@ -1710,7 +1710,7 @@ static int rgw_bucket_unlink_instance(cls_method_context_t hctx, bufferlist *in, rgw_bucket_entry_ver ver; ver.epoch = (op.olh_epoch ? op.olh_epoch : olh.get_epoch()); - real_time mtime = real_clock::now(); /* mtime has no real meaning in instance removal context */ + real_time mtime = obj.mtime(); /* mtime has no real meaning in instance removal context */ ret = log_index_operation(hctx, op.key, CLS_RGW_OP_UNLINK_INSTANCE, op.op_tag, mtime, ver, CLS_RGW_STATE_COMPLETE, header.ver, header.max_marker,