From cbe25074ba07eed9863eef791c3603bb8b0689d9 Mon Sep 17 00:00:00 2001 From: John Spray Date: Thu, 9 Nov 2017 09:14:44 -0500 Subject: [PATCH] doc: update mgr module guide for have_mon_connection Signed-off-by: John Spray --- doc/mgr/plugins.rst | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/doc/mgr/plugins.rst b/doc/mgr/plugins.rst index 809e589a74b..5069fa2a078 100644 --- a/doc/mgr/plugins.rst +++ b/doc/mgr/plugins.rst @@ -107,6 +107,22 @@ function. This will result in a circular locking exception. .. automethod:: MgrModule.get_metadata .. automethod:: MgrModule.get_counter +What if the mons are down? +-------------------------- + +The manager daemon gets much of its state (such as the cluster maps) +from the monitor. If the monitor cluster is inaccessible, whichever +manager was active will continue to run, with the latest state it saw +still in memory. + +However, if you are creating a module that shows the cluster state +to the user then you may well not want to mislead them by showing +them that out of date state. + +To check if the manager daemon currently has a connection to +the monitor cluster, use this function: + +.. automethod:: MgrModule.have_mon_connection Sending commands ---------------- -- 2.47.3