From fe35cb1b7ebb09f2c8f2b5a58a88a7a4b94203ae Mon Sep 17 00:00:00 2001 From: Patrick Donnelly Date: Tue, 5 Nov 2019 00:15:20 -0800 Subject: [PATCH] mds: clarify comment Signed-off-by: Patrick Donnelly --- src/mds/MDSDaemon.cc | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/mds/MDSDaemon.cc b/src/mds/MDSDaemon.cc index 9e96338242b36..dca474034866d 100644 --- a/src/mds/MDSDaemon.cc +++ b/src/mds/MDSDaemon.cc @@ -917,12 +917,11 @@ void MDSDaemon::suicide() clean_up_admin_socket(); - // Inform MDS we are going away, then shut down beacon + // Notify the Monitors (MDSMonitor) that we're dying, so that it doesn't have + // to wait for us to go laggy. Only do this if we're actually in the MDSMap, + // because otherwise the MDSMonitor will drop our message. beacon.set_want_state(*mdsmap, MDSMap::STATE_DNE); if (!mdsmap->is_dne_gid(mds_gid_t(monc->get_global_id()))) { - // Notify the MDSMonitor that we're dying, so that it doesn't have to - // wait for us to go laggy. Only do this if we're actually in the - // MDSMap, because otherwise the MDSMonitor will drop our message. beacon.send_and_wait(1); } beacon.shutdown(); -- 2.39.5