]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mds/Beacon: wake up the thread in shutdown() 61513/head
authorMax Kellermann <max.kellermann@ionos.com>
Fri, 11 Oct 2024 20:06:42 +0000 (22:06 +0200)
committerMilind Changire <mchangir@redhat.com>
Sat, 25 Jan 2025 01:45:44 +0000 (07:15 +0530)
This eliminates the `wait_for()` delay and speeds up MDS shutdown.

Fixes: https://tracker.ceph.com/issues/68759
Signed-off-by: Max Kellermann <max.kellermann@ionos.com>
(cherry picked from commit 0276ab4eb9dd09b0bd8e39389a75e960390ceaeb)

src/mds/Beacon.cc

index 7338b11d005e07dbd4d6530eb48a81be7cf50a0e..a6c8cef244ecddc467dd4bb3face47963d691865 100644 (file)
@@ -60,6 +60,7 @@ void Beacon::shutdown()
   std::unique_lock<std::mutex> lock(mutex);
   if (!finished) {
     finished = true;
+    cvar.notify_all();
     lock.unlock();
     if (sender.joinable())
       sender.join();