From: Seena Fallah Date: Fri, 25 Oct 2024 23:57:24 +0000 (+0200) Subject: rgw: fix json output for bucket layout X-Git-Tag: v20.0.0~528^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=30b9c4b615f33a998be05faad8b0d4eb86771672;p=ceph.git rgw: fix json output for bucket layout f19347d43b7cd4bb1e009e66305f6e736c4c5d89 has broken the bucket layout JSON output by printing `judge_reshard_lock_time` inside the logs array. Fixes: https://tracker.ceph.com/issues/68726 Signed-off-by: Seena Fallah --- diff --git a/src/rgw/rgw_bucket_layout.cc b/src/rgw/rgw_bucket_layout.cc index f8c485d89c33..1f8db396a0d1 100644 --- a/src/rgw/rgw_bucket_layout.cc +++ b/src/rgw/rgw_bucket_layout.cc @@ -376,9 +376,9 @@ void encode_json_impl(const char *name, const BucketLayout& l, ceph::Formatter * for (const auto& log : l.logs) { encode_json("log", log, f); } + f->close_section(); // logs[] utime_t jt(l.judge_reshard_lock_time); encode_json("judge_reshard_lock_time", jt, f); - f->close_section(); // logs[] f->close_section(); } void decode_json_obj(BucketLayout& l, JSONObj *obj)