From 18e67b22b22f0eb27567cfe3d2a424f96d83632c Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 11 Oct 2024 22:06:42 +0200 Subject: [PATCH] mds/Beacon: wake up the thread in shutdown() This eliminates the `wait_for()` delay and speeds up MDS shutdown. Fixes: https://tracker.ceph.com/issues/68759 Signed-off-by: Max Kellermann (cherry picked from commit 0276ab4eb9dd09b0bd8e39389a75e960390ceaeb) --- src/mds/Beacon.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mds/Beacon.cc b/src/mds/Beacon.cc index 059b540feb02..b7e675c3faa5 100644 --- a/src/mds/Beacon.cc +++ b/src/mds/Beacon.cc @@ -60,6 +60,7 @@ void Beacon::shutdown() std::unique_lock lock(mutex); if (!finished) { finished = true; + cvar.notify_all(); lock.unlock(); if (sender.joinable()) sender.join(); -- 2.47.3