LGTM, thanks On Fri Feb 13 2015 at 12:50:21 PM 'Klaus Aehlig' via ganeti-devel < ganeti-devel@googlegroups.com> wrote:
> As the Ganeti 2.12 design allows for WConfD to be > restarted with jobs running, jobs accept WConfD not > be present and wait for to come back, retrying. > However, the time the jobs waited for WConfD to come > back was shorter than an actual restart might take. > So, increase it significantly and also back off with > the number of retries increasing to avoid flooding > WConfD after its restart. > > Signed-off-by: Klaus Aehlig <aeh...@google.com> > --- > lib/wconfd.py | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/lib/wconfd.py b/lib/wconfd.py > index 1e1e1ac..d834e68 100644 > --- a/lib/wconfd.py > +++ b/lib/wconfd.py > @@ -58,7 +58,7 @@ class Client(cl.AbstractStubClient, stub.ClientRpcStub): > cl.AbstractStubClient.__init__(self, timeouts, transport) > stub.ClientRpcStub.__init__(self) > > - retries = 10 > + retries = 12 > for try_no in range(0, retries): > try: > self._InitTransport() > @@ -68,4 +68,4 @@ class Client(cl.AbstractStubClient, stub.ClientRpcStub): > if try_no == retries -1: > raise > logging.debug("Will retry") > - time.sleep(10 * random.random()) > + time.sleep(try_no * 10 + 10 * random.random()) > -- > 2.2.0.rc0.207.ga3a616c > >