]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/.../client_request: bounce replica read if missing
authorSamuel Just <sjust@redhat.com>
Thu, 4 Apr 2024 01:55:52 +0000 (18:55 -0700)
committerSamuel Just <sjust@redhat.com>
Sat, 19 Oct 2024 01:40:11 +0000 (01:40 +0000)
Fixes: https://tracker.ceph.com/issues/65299
Signed-off-by: Samuel Just <sjust@redhat.com>
src/crimson/osd/osd_operations/client_request.cc

index bd1a2aa439a1e5e146f4f32ffa8b7e6af747891e..fceb98f37c981c709ea91a85e55caa7a2ae76d95 100644 (file)
@@ -190,6 +190,11 @@ ClientRequest::interruptible_future<> ClientRequest::with_pg_process_interruptib
       DEBUGDPP("{}.{}: dropping misdirected op",
               pg, *this, this_instance_id);
       co_return;
+    } else if (pg.is_unreadable_object(m->get_hobj())) {
+      DEBUGDPP("{}.{}: {} missing on replica, bouncing to primary",
+              pg, *this, this_instance_id, m->get_hobj());
+      co_await reply_op_error(pgref, -EAGAIN);
+      co_return;
     } else if (!pg.get_peering_state().can_serve_replica_read(m->get_hobj())) {
       DEBUGDPP("{}.{}: unstable write on replica, bouncing to primary",
               pg, *this, this_instance_id);