diff options
| author | Martin Schwenke <martin@meltin.net> | 2012-12-13 12:15:32 +1100 |
|---|---|---|
| committer | Martin Schwenke <martin@meltin.net> | 2013-01-08 10:16:11 +1100 |
| commit | bcefb768841ed226cbaf72b96ce80bd2d5f0a024 (patch) | |
| tree | 617a29d01854cccc15135e1241c27ead959f18cf /ctdb/tests/src | |
| parent | 443fbb9e01abd8278313166ac3ffbf2d239ad6c5 (diff) | |
recoverd: Move failback retry loop into basic_failback() and lcp2_failback()
The retry loop is currently in ctdb_takeover_run_core(). Pushing it
into each function will make it possible to put each algorithm into a
separate top-level function. This will make the code much clearer and
more maintainable.
Also keep associated test code compatible.
Signed-off-by: Martin Schwenke <martin@meltin.net>
(This used to be ctdb commit f6ce18d011dd9043b04256690d826deb2640cd89)
Diffstat (limited to 'ctdb/tests/src')
| -rw-r--r-- | ctdb/tests/src/ctdb_takeover_tests.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/ctdb/tests/src/ctdb_takeover_tests.c b/ctdb/tests/src/ctdb_takeover_tests.c index 1e710a7971..837741e2e7 100644 --- a/ctdb/tests/src/ctdb_takeover_tests.c +++ b/ctdb/tests/src/ctdb_takeover_tests.c @@ -458,12 +458,9 @@ void ctdb_test_lcp2_failback_loop(const char nodestates[]) NODE_FLAGS_INACTIVE|NODE_FLAGS_DISABLED, all_ips, &lcp2_imbalances, &newly_healthy); -try_again: - if (lcp2_failback(ctdb, nodemap, - NODE_FLAGS_INACTIVE|NODE_FLAGS_DISABLED, - all_ips, lcp2_imbalances, newly_healthy)) { - goto try_again; - } + lcp2_failback(ctdb, nodemap, + NODE_FLAGS_INACTIVE|NODE_FLAGS_DISABLED, + all_ips, lcp2_imbalances, newly_healthy); print_ctdb_public_ip_list(all_ips); |
