]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mon: notify PaxosService of any paxos state changes
authorSage Weil <sage@newdream.net>
Fri, 5 Dec 2008 22:00:59 +0000 (14:00 -0800)
committerSage Weil <sage@newdream.net>
Fri, 5 Dec 2008 22:33:03 +0000 (14:33 -0800)
src/mon/Monitor.cc

index 85b289ba1e2728c72433a90c3ca2bdb78da0ab7b..636878056fdd027de5452f5a23b018ce55b82433 100644 (file)
@@ -389,7 +389,12 @@ bool Monitor::dispatch_impl(Message *m)
 
        // send it to the right paxos instance
        assert(pm->machine_id < PAXOS_NUM);
-       paxos[pm->machine_id]->dispatch(m);
+       Paxos *p = paxos[pm->machine_id];
+       p->dispatch(m);
+
+       // make sure service finds out about any state changes
+       if (p->is_active())
+         paxos_service[pm->machine_id]->update_from_paxos();
       }
       break;