mon/Paxos: set state to RECOVERING during restart

This ensures that the paxos state is not active when the PaxosService
restart() methods run right afterwards, and that EAGAIN waiters will get
requeued appropriately.

Signed-off-by: Sage Weil <sage@inktank.com>
This commit is contained in:
Sage Weil 2013-03-19 10:15:41 -07:00
parent bee5046333
commit efc4b1268e

View File

@ -1125,6 +1125,7 @@ void Paxos::restart()
if (!proposals.empty())
proposals.clear();
state = STATE_RECOVERING;
going_to_bootstrap = false;
finish_contexts(g_ceph_context, waiting_for_commit, -EAGAIN);