]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
librbd: remove unused journal replay canceled callback
authorJason Dillaman <dillaman@redhat.com>
Wed, 27 Jul 2016 00:57:40 +0000 (20:57 -0400)
committerMykola Golub <mgolub@mirantis.com>
Fri, 19 Aug 2016 19:59:06 +0000 (22:59 +0300)
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit f453554edcb16ec72714b2456c08bab9e339b1eb)

src/librbd/journal/Policy.h
src/librbd/journal/StandardPolicy.cc
src/librbd/journal/StandardPolicy.h
src/test/librbd/mock/MockJournalPolicy.h
src/tools/rbd_mirror/ImageDeleter.cc
src/tools/rbd_mirror/image_replayer/OpenLocalImageRequest.cc

index 85373cd1abc564e9bfa9342e25b3443fa4279e7d..2ef21e6fe0e8a88aed5a9e8bdfc19f7f34c8fd8d 100644 (file)
@@ -16,7 +16,6 @@ struct Policy {
 
   virtual bool append_disabled() const = 0;
   virtual void allocate_tag_on_lock(Context *on_finish) = 0;
-  virtual void cancel_external_replay(Context *on_finish) = 0;
 };
 
 } // namespace journal
index 9e718288706e8b5f1ed5300a87685e80e400951a..5cba7c02011264bc0e1ea9a0fafe1e803eda2956 100644 (file)
@@ -25,10 +25,5 @@ void StandardPolicy::allocate_tag_on_lock(Context *on_finish) {
   m_image_ctx->journal->allocate_local_tag(on_finish);
 }
 
-void StandardPolicy::cancel_external_replay(Context *on_finish) {
-  // external replay is only handled by rbd-mirror
-  assert(false);
-}
-
 } // namespace journal
 } // namespace librbd
index e2b1ad7bc8359cfad6ff166505745962180d4a2a..c2c997c8aecc36e3f589147e5a0dce23da170e56 100644 (file)
@@ -21,7 +21,6 @@ public:
     return false;
   }
   virtual void allocate_tag_on_lock(Context *on_finish);
-  virtual void cancel_external_replay(Context *on_finish);
 
 private:
   ImageCtx *m_image_ctx;
index c10fd6fbf1f878ea39da53626d1205082c69f1a6..8ad6ff60952ee7647a0cf8d444d30a0d3cb0dbcb 100644 (file)
@@ -13,7 +13,6 @@ struct MockJournalPolicy : public journal::Policy {
 
   MOCK_CONST_METHOD0(append_disabled, bool());
   MOCK_METHOD1(allocate_tag_on_lock, void(Context*));
-  MOCK_METHOD1(cancel_external_replay, void(Context*));
 
 };
 
index 7c5caee640a238f55a7310f2b533595ad26ae857..234c2401ffde9aaf6f9b60dbfadefe6b9519baa0 100644 (file)
@@ -81,10 +81,6 @@ struct DeleteJournalPolicy : public librbd::journal::Policy {
   virtual void allocate_tag_on_lock(Context *on_finish) {
     on_finish->complete(0);
   }
-
-  virtual void cancel_external_replay(Context *on_finish) {
-    on_finish->complete(0);
-  }
 };
 
 } // anonymous namespace
index 0286e522664c4346e5f33a1df08ef4b631b29100..f023f39ac6d75c4553232e6299551f2964aea10d 100644 (file)
@@ -52,13 +52,6 @@ struct MirrorJournalPolicy : public librbd::journal::Policy {
     // rbd-mirror will manually create tags by copying them from the peer
     work_queue->queue(on_finish, 0);
   }
-
-  virtual void cancel_external_replay(Context *on_finish) {
-    // TODO: journal is being closed due to a comms error.  This means
-    // the journal is being closed and the exclusive lock is being released.
-    // ImageReplayer needs to restart.
-  }
-
 };
 
 } // anonymous namespace