]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: is_single_zonegroup doesn't use store or cct
authorOrit Wasserman <owasserm@redhat.com>
Thu, 22 Jun 2017 07:17:37 +0000 (10:17 +0300)
committerNathan Cutler <ncutler@suse.com>
Tue, 12 Sep 2017 06:59:04 +0000 (08:59 +0200)
Signed-off-by: Orit Wasserman <owasserm@redhat.com>
(cherry picked from commit 0b0090cee249c5380efa4bb416d724a7e2dbfc08)

src/rgw/rgw_rados.cc
src/rgw/rgw_rados.h

index f66dc2312cd9e1e10ddaf5cc09f3e0880338c969..b82bc2ee70819f29ace66c3525f3dde6214042ce 100644 (file)
@@ -1,3 +1,4 @@
+
 // -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*-
 // vim: ts=8 sw=2 smarttab
 
@@ -915,11 +916,6 @@ int RGWPeriod::get_zonegroup(RGWZoneGroup& zonegroup, const string& zonegroup_id
   return -ENOENT;
 }
 
-bool RGWPeriod::is_single_zonegroup(CephContext *cct, RGWRados *store)
-{
-  return (period_map.zonegroups.size() == 1);
-}
-
 const string& RGWPeriod::get_latest_epoch_oid()
 {
   if (cct->_conf->rgw_period_latest_epoch_info_oid.empty()) {
@@ -7389,7 +7385,7 @@ bool RGWRados::is_syncing_bucket_meta(rgw_bucket& bucket)
   }
 
   /* single zonegroup and a single zone */
-  if (current_period.is_single_zonegroup(cct, this) && get_zonegroup().zones.size() == 1) {
+  if (current_period.is_single_zonegroup() && get_zonegroup().zones.size() == 1) {
     return false;
   }
 
index 80f11622ef63bdff533bfa64bb81cba743fa4836..9c3de8fdb2338110c585ca67b7e2e3c6b8e5efdc 100644 (file)
@@ -1496,7 +1496,10 @@ public:
   int get_zonegroup(RGWZoneGroup& zonegroup,
                    const string& zonegroup_id);
 
-  bool is_single_zonegroup(CephContext *cct, RGWRados *store);
+  bool is_single_zonegroup()
+  {
+      return (period_map.zonegroups.size() == 1);
+  }
 
   /*
     returns true if there are several zone groups with a least one zone