]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mon: remove some upgrade-specific bits of PGStatService
authorSage Weil <sage@redhat.com>
Sat, 26 Aug 2017 19:13:01 +0000 (15:13 -0400)
committerSage Weil <sage@redhat.com>
Wed, 6 Sep 2017 14:18:02 +0000 (10:18 -0400)
Signed-off-by: Sage Weil <sage@redhat.com>
src/mon/OSDMonitor.cc
src/mon/PGStatService.h

index 68ac3a3957954ad3dd80fbbe6248f485b41d8d4d..256d03abe8ee405d6fb428d391e4197e3577ecf0 100644 (file)
@@ -651,14 +651,6 @@ OSDMonitor::update_pending_pgs(const OSDMap::Incremental& inc)
   }
   // check for new or old pools
   if (pending_creatings.last_scan_epoch < inc.epoch) {
-    if (osdmap.get_epoch() &&
-       osdmap.require_osd_release < CEPH_RELEASE_LUMINOUS) {
-      auto added =
-       mon->pgservice->maybe_add_creating_pgs(creating_pgs.last_scan_epoch,
-                                              osdmap.get_pools(),
-                                              &pending_creatings);
-      dout(7) << __func__ << " " << added << " pgs added from pgmap" << dendl;
-    }
     unsigned queued = 0;
     queued += scan_for_creating_pgs(osdmap.get_pools(),
                                    inc.old_pools,
@@ -1172,12 +1164,6 @@ void OSDMonitor::encode_pending(MonitorDBStore::TransactionRef t)
   if (mon->monmap->get_required_features().contains_all(
        ceph::features::mon::FEATURE_LUMINOUS)) {
     auto pending_creatings = update_pending_pgs(pending_inc);
-    if (osdmap.get_epoch() &&
-       osdmap.require_osd_release < CEPH_RELEASE_LUMINOUS) {
-      dout(7) << __func__ << " in the middle of upgrading, "
-             << " trimming pending creating_pgs using pgmap" << dendl;
-      mon->pgservice->maybe_trim_creating_pgs(&pending_creatings);
-    }
     bufferlist creatings_bl;
     ::encode(pending_creatings, creatings_bl);
     t->put(OSD_PG_CREATING_PREFIX, "creating", creatings_bl);
index 1354ed3d4cbb9aea627badfae7186f50c41a2c82..f179b9c767f0b239749025c2104667d645216005 100644 (file)
@@ -96,24 +96,7 @@ class MonPGStatService : virtual public PGStatService {
 public:
   MonPGStatService() : PGStatService() {}
   virtual ~MonPGStatService() {}
-  /**
-   * For upgrades. If the PGMap has newer data than the monitor's new
-   * creating_pgs (scan_epoch), insert them into the passed pending_creates.
-   */
-  virtual unsigned maybe_add_creating_pgs(epoch_t scan_epoch,
-     const mempool::osdmap::map<int64_t,pg_pool_t>& pools,
-     creating_pgs_t *pending_creates) const {
-    ceph_abort();
-    return 0;
-  }
-  /**
-   * For upgrades. If some PGs are created before all OSDs are luminous
-   * and start sending MOSDPGCreated, we need to be sync with pgmap
-   *
-   */
-  virtual void maybe_trim_creating_pgs(creating_pgs_t *creates) const {
-    ceph_abort();
-  }
+
   virtual int reweight_by_utilization(const OSDMap &osd_map,
                              int oload,
                              double max_changef,