speed startup: alter recovery loop
authorRusty Russell <rusty@rustcorp.com.au>
Tue, 22 Jun 2010 13:20:23 +0000 (22:50 +0930)
committerMichael Adam <obnox@samba.org>
Mon, 26 Aug 2013 11:34:21 +0000 (13:34 +0200)
commit24493d052d66ab4309f33983aaa78ddaa565cdad
treefccdb4712d279f99b45786c71e428dab33610608
parent9eeab362666dbb3099096eb09ccf8ca6efe2e12f
speed startup: alter recovery loop

We do a recovery on startup.  But the code does:
   Sleep for ctdb->tunable.recover_interval.
   Check for recovery.

We want to do it in the other order.  This is best done by extracting
the loop into a separate "main_loop" function.

Seconds between ctdbd first log message and node healthy:
BEFORE: 24.09
AFTER: 23.58

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(cherry picked from commit 097046025176b9fcb670839d1a9f100f890e7ed2)
server/ctdb_recoverd.c