]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: sync checkpoint gets num_shards from remote bilog info
authorAdam C. Emerson <aemerson@redhat.com>
Fri, 10 Sep 2021 15:00:07 +0000 (11:00 -0400)
committerAdam C. Emerson <aemerson@redhat.com>
Tue, 1 Feb 2022 22:18:17 +0000 (17:18 -0500)
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
src/rgw/rgw_sync_checkpoint.cc

index c9d350e73efe1333e531a9d1f2ce48d56bc65402..b07cec1a05a00a9228b863ef2fa38f9fe0e216f5 100644 (file)
@@ -88,8 +88,8 @@ int bucket_source_sync_checkpoint(const DoutPrefixProvider* dpp,
                                   ceph::timespan retry_delay,
                                   ceph::coarse_mono_time timeout_at)
 {
-  const auto num_shards = source_bucket_info.layout.current_index.layout.normal.num_shards;
 
+  const int num_shards = remote_markers.get().size();
   rgw_bucket_sync_status full_status;
   int r = rgw_read_bucket_full_sync_status(dpp, store, pipe, &full_status, null_yield);
   if (r < 0 && r != -ENOENT) { // retry on ENOENT