From: Joao Eduardo Luis Date: Thu, 8 Jan 2015 22:40:24 +0000 (+0000) Subject: mon: paxos: queue next proposal after waking up callbacks X-Git-Tag: v0.93~275^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=5461368968a97087d053b53de5cc15ed15b9245e;p=ceph.git mon: paxos: queue next proposal after waking up callbacks Signed-off-by: Joao Eduardo Luis --- diff --git a/src/mon/Paxos.cc b/src/mon/Paxos.cc index b677d01cc57..6f3a5441990 100644 --- a/src/mon/Paxos.cc +++ b/src/mon/Paxos.cc @@ -572,6 +572,8 @@ void Paxos::handle_last(MMonPaxos *last) finish_contexts(g_ceph_context, waiting_for_active); finish_contexts(g_ceph_context, waiting_for_readable); finish_contexts(g_ceph_context, waiting_for_writeable); + + queue_next(); } } } @@ -920,6 +922,8 @@ void Paxos::commit_finish() finish_contexts(g_ceph_context, waiting_for_active); finish_contexts(g_ceph_context, waiting_for_readable); finish_contexts(g_ceph_context, waiting_for_writeable); + + queue_next(); } } @@ -1053,11 +1057,15 @@ void Paxos::commit_proposal() void Paxos::finish_round() { + dout(10) << __func__ << dendl; assert(mon->is_leader()); // ok, now go active! state = STATE_ACTIVE; +} +void Paxos::queue_next() +{ dout(10) << __func__ << " state " << state << " proposals left " << proposals.size() << dendl; @@ -1070,6 +1078,7 @@ void Paxos::finish_round() } } + // peon void Paxos::handle_lease(MMonPaxos *lease) { diff --git a/src/mon/Paxos.h b/src/mon/Paxos.h index dcba45805b0..8025f06a080 100644 --- a/src/mon/Paxos.h +++ b/src/mon/Paxos.h @@ -1070,6 +1070,7 @@ private: void commit_proposal(); void finish_round(); + void queue_next(); public: /**