]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/PeeringState: fix missed `recheck_readable` from laggy 49304/head
author胡玮文 <huww98@outlook.com>
Fri, 7 Jan 2022 17:14:00 +0000 (01:14 +0800)
committerRadosław Zarzyński <rzarzyns@redhat.com>
Wed, 7 Dec 2022 14:52:27 +0000 (15:52 +0100)
Previously, the first `pg_lease_ack_t` after becoming laggy would not
trigger `recheck_readable`. However, every other ack would trigger it.
The logic is inverted, causing unnecessarily long laggy PG state.

Fixes: 3bb8a7210a6 (osd: requeue ops when PG is no longer laggy)
Fixes: https://tracker.ceph.com/issues/53806
Signed-off-by: 胡玮文 <huww98@outlook.com>
(cherry picked from commit caeca396e8b149cfa09ed99eda4f7a7186b005b4)

src/osd/PeeringState.cc

index 68b8d22259955dfb82455429b25b3ed8abd8fbc3..8ad0a08e9b4c2b1e4840c81681a22b796a83fc9f 100644 (file)
@@ -1220,7 +1220,7 @@ void PeeringState::proc_lease_ack(int from, const pg_lease_ack_t& a)
   if (was_min) {
     auto old_ru = readable_until;
     recalc_readable_until();
-    if (now < old_ru) {
+    if (now >= old_ru) {
       pl->recheck_readable();
     }
   }