mirror of
https://github.com/predis/predis.git
synced 2026-08-30 20:21:31 +00:00
Filter out available slaves based on master-link-status flag (#1440)
This commit is contained in:
committed by
GitHub
parent
d44f07339a
commit
45b18eb2e0
@@ -426,6 +426,11 @@ class SentinelReplication implements ReplicationInterface
|
||||
continue;
|
||||
}
|
||||
|
||||
// ensure `master-link-status` is ok
|
||||
if (isset($slave[31]) && $slave[31] === 'err') {
|
||||
continue;
|
||||
}
|
||||
|
||||
$slaves[] = [
|
||||
'host' => $slave[3],
|
||||
'port' => $slave[5],
|
||||
|
||||
Reference in New Issue
Block a user