From: Sage Weil Date: Thu, 20 Jun 2013 22:39:23 +0000 (-0700) Subject: mon/PaxosService: allow paxos service writes while paxos is updating X-Git-Tag: v0.67-rc1~175^2~13 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=d31ed95064c229610398f57b5bd6ce40b94b4edd;p=ceph.git mon/PaxosService: allow paxos service writes while paxos is updating In commit f985de28f86675e974ac7842a49922a35fe24c6c I mistakenly made is_writeable() false while paxos was updating due to a misread of Paxos::propose_new_value() (I didn't see that it would queue). This is problematic because it narrows the window during which each service is writeable for no reason. Allow service to be writeable both when paxos is active and updating. Signed-off-by: Sage Weil --- diff --git a/src/mon/PaxosService.h b/src/mon/PaxosService.h index d92824f6dd6..5975cb94e49 100644 --- a/src/mon/PaxosService.h +++ b/src/mon/PaxosService.h @@ -559,7 +559,7 @@ public: * * - we are not proposing a new version; * - we are ready to be written to -- i.e., we have a pending value. - * - paxos is writeable + * - paxos is (active or updating) * * @returns true if writeable; false otherwise */ @@ -567,7 +567,7 @@ public: return !is_proposing() && is_write_ready() && - paxos->is_writeable(); + (paxos->is_active() || paxos->is_updating()); } /**