]> git.saurik.com Git - redis.git/commit
Sentinel: abort failover if no good slave is available.
authorantirez <antirez@gmail.com>
Wed, 25 Jul 2012 09:32:19 +0000 (11:32 +0200)
committerantirez <antirez@gmail.com>
Wed, 25 Jul 2012 09:32:19 +0000 (11:32 +0200)
commit672102c2ceb4bfc24fcbec96f0cd79118a873d72
treea69896edc5c9acf99a6eb8b65f2f1727f4ab124b
parent9e5bef38e6cb43d8d5ee12ab1114e424ae69d693
Sentinel: abort failover if no good slave is available.

The previous behavior of the state machine was to wait some time and
retry the slave selection, but this is not robust enough against drastic
changes in the conditions of the monitored instances.

What we do now when the slave selection fails is to abort the failover
and return back monitoring the master. If the ODOWN condition is still
present a new failover will be triggered and so forth.

This commit also refactors the code we use to abort a failover.
src/sentinel.c