]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mon/ConfigKeyService: wait for quorum 13617/head
authorSage Weil <sage@redhat.com>
Thu, 30 Mar 2017 16:42:31 +0000 (12:42 -0400)
committerSage Weil <sage@redhat.com>
Thu, 30 Mar 2017 21:57:35 +0000 (17:57 -0400)
Among other things, this prevents a mgr activation stall if it
happens to request config-keys from a mon that is out of
quorum.

Signed-off-by: Sage Weil <sage@redhat.com>
src/mon/ConfigKeyService.cc
src/mon/Monitor.h

index df180b7a636dfa5820d82bdfc2fb98d7d4efbbd0..8d083199331edb0ec6560759984043b56071227d 100644 (file)
@@ -91,7 +91,8 @@ bool ConfigKeyService::service_dispatch(MonOpRequestRef op)
   dout(10) << __func__ << " " << *m << dendl;
 
   if (!in_quorum()) {
-    dout(1) << __func__ << " not in quorum -- ignore message" << dendl;
+    dout(1) << __func__ << " not in quorum -- waiting" << dendl;
+    paxos->wait_for_readable(op, new Monitor::C_RetryMessage(mon, op));
     return false;
   }
 
index 77741ad6e4ddf3e754b16d03217b28cf63ba0621..0a6bc310b0f7d69c05ed7e349147fa33c3046365 100644 (file)
@@ -655,6 +655,7 @@ public:
   friend class MonmapMonitor;
   friend class PGMonitor;
   friend class LogMonitor;
+  friend class ConfigKeyService;
 
   QuorumService *health_monitor;
   QuorumService *config_key_service;