]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: enable RGWReshard thread on any zone that supports it
authorCasey Bodley <cbodley@redhat.com>
Tue, 12 Oct 2021 16:45:29 +0000 (12:45 -0400)
committerCasey Bodley <cbodley@redhat.com>
Fri, 27 May 2022 19:47:33 +0000 (15:47 -0400)
enable the background dynamic resharding thread based on
RGWSI_Zone::can_reshard(), which takes the zonegroup features into
account

Fixes: https://tracker.ceph.com/issues/52877
Signed-off-by: Casey Bodley <cbodley@redhat.com>
src/rgw/rgw_rados.cc

index 7e27c1e67f55a6469b42371d35c1c1a607449c66..5623f589242d41853ba25bf8908d1c473955e0aa 100644 (file)
@@ -1337,8 +1337,9 @@ int RGWRados::init_complete(const DoutPrefixProvider *dpp)
 
   reshard = new RGWReshard(this->store);
 
-  /* only the master zone in the zonegroup reshards buckets */
-  run_reshard_thread = run_reshard_thread && (zonegroup.master_zone == zone.id);
+  // disable reshard thread based on zone/zonegroup support
+  run_reshard_thread = run_reshard_thread && svc.zone->can_reshard();
+
   if (run_reshard_thread)  {
     reshard->start_processor();
   }