speed startup: don't wait a full recovery interval if we've already waited
authorRusty Russell <rusty@rustcorp.com.au>
Tue, 22 Jun 2010 13:20:35 +0000 (22:50 +0930)
committerRusty Russell <rusty@rustcorp.com.au>
Tue, 22 Jun 2010 13:20:35 +0000 (22:50 +0930)
commitfabeea6197b8ec1477022a26c9c2707193d4d697
tree74fa07967730ad2c6c90be0f70602fb79849bad5
parenteb61b11497014fcf70ceac21cb2573b760458dd1
speed startup: don't wait a full recovery interval if we've already waited

We currently sleep for one second, whether or not we've already slept.
Change this to sleep for the remainder of the second, if at all.

Seconds between ctdbd first log message and node healthy:
BEFORE: 18.09
AFTER: 17.08

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(This used to be ctdb commit fde760b5f39c77172308a583da4c2443b71541c9)
ctdb/server/ctdb_recoverd.c