]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
messages/MOSDPGQuery: remove compat cruft
authorSage Weil <sage@redhat.com>
Wed, 12 Apr 2017 02:58:55 +0000 (22:58 -0400)
committerSage Weil <sage@redhat.com>
Fri, 21 Apr 2017 20:00:39 +0000 (16:00 -0400)
v3 was pre-firefly (8b46dd1dc009981f2fcae7b0e05155e81841c4a5).

Signed-off-by: Sage Weil <sage@redhat.com>
src/messages/MOSDPGQuery.h

index d6029d0d9f7e86fe35878e6127d083cf49c941ee..cc5db00ebae7381dc43a4ce2770f5cbb2a79f4eb 100644 (file)
@@ -25,8 +25,9 @@
 
 class MOSDPGQuery : public Message {
   static const int HEAD_VERSION = 3;
-  static const int COMPAT_VERSION = 1;
-  version_t       epoch;
+  static const int COMPAT_VERSION = 3;
+
+  version_t epoch;
 
  public:
   version_t get_epoch() const { return epoch; }
@@ -82,24 +83,14 @@ public:
     vector<pair<pg_t, pg_query_t> > _pg_list;
     ::decode(_pg_list, p);
     vector<shard_id_t> _shard_list(_pg_list.size(), shard_id_t::NO_SHARD);
-    if (header.version >= 3) {
-      _shard_list.clear();
-      ::decode(_shard_list, p);
-    }
+    _shard_list.clear();
+    ::decode(_shard_list, p);
     assert(_pg_list.size() == _shard_list.size());
     for (unsigned i = 0; i < _pg_list.size(); ++i) {
       pg_list.insert(
        make_pair(
          spg_t(_pg_list[i].first, _shard_list[i]), _pg_list[i].second));
     }
-
-    if (header.version < 2) {
-      for (map<spg_t, pg_query_t>::iterator i = pg_list.begin();
-          i != pg_list.end();
-          ++i) {
-       i->second.epoch_sent = epoch;
-      }
-    }
   }
 };