]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/osd: the ClientRequest::do_recover_missing() takes oid externally.
authorRadoslaw Zarzynski <rzarzyns@redhat.com>
Thu, 18 Mar 2021 09:34:54 +0000 (09:34 +0000)
committerRadoslaw Zarzynski <rzarzyns@redhat.com>
Mon, 10 May 2021 16:01:32 +0000 (18:01 +0200)
This refactor is a first step towards sharing the recovery bits
with `InternalClientRequest`.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
src/crimson/osd/osd_operations/client_request.cc
src/crimson/osd/osd_operations/client_request.h

index d8936232e35b9e0a04e6fddb2b45d3f55e8aebd8..2a1e652e137faa9407155a49aaeef327e04657d6 100644 (file)
@@ -166,7 +166,7 @@ ClientRequest::process_op(Ref<PG> &pg)
       handle.enter(pp(*pg).recover_missing))
   .then_interruptible(
     [this, pg]() mutable {
-    return do_recover_missing(pg);
+    return do_recover_missing(pg, m->get_hobj());
   }).then_interruptible([this, pg]() mutable {
     return pg->already_complete(m->get_reqid()).then_unpack_interruptible(
       [this, pg](bool completed, int ret) mutable
@@ -201,10 +201,9 @@ ClientRequest::process_op(Ref<PG> &pg)
 }
 
 ClientRequest::interruptible_future<>
-ClientRequest::do_recover_missing(Ref<PG>& pg)
+ClientRequest::do_recover_missing(Ref<PG>& pg, const hobject_t& soid)
 {
   eversion_t ver;
-  const hobject_t& soid = m->get_hobj();
   logger().debug("{} check for recovery, {}", *this, soid);
   if (!pg->is_unreadable_object(soid, &ver) &&
       !pg->is_degraded_or_backfilling_object(soid)) {
index 2cf75164056f8dc88de6ab95f78976151a031082..f361838bb3fa71102613a7e692c8a46f25dbd238 100644 (file)
@@ -62,7 +62,7 @@ public:
   seastar::future<> start();
 
 private:
-  interruptible_future<> do_recover_missing(Ref<PG>& pgref);
+  interruptible_future<> do_recover_missing(Ref<PG>& pgref, const hobject_t& soid);
   interruptible_future<> do_process(
     Ref<PG>& pg,
     crimson::osd::ObjectContextRef obc);