Skip to content

Commit 61b7f6c

Browse files
Fix docs
1 parent 3f64690 commit 61b7f6c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

cluster.markdown

+3-3
Original file line numberDiff line numberDiff line change
@@ -60,14 +60,14 @@ By default, RedisCluster will only ever send commands to master nodes, but can b
6060

6161
<pre>
6262
// The default option, only send commands to master nodes
63-
$obj_cluster->setOption(RedisCluster::OPT_FAILOVER, RedisCluster::FAILOVER_NONE);
63+
$obj_cluster->setOption(RedisCluster::OPT_SLAVE_FAILOVER, RedisCluster::FAILOVER_NONE);
6464

6565
// In the event we can't reach a master, and it has slaves, failover for read commands
66-
$obj_cluster->setOption(RedisCluster::OPT_FAILOVER, RedisCluster::FAILOVER_ERROR);
66+
$obj_cluster->setOption(RedisCluster::OPT_SLAVE_FAILOVER, RedisCluster::FAILOVER_ERROR);
6767

6868
// Always distribute readonly commands between masters and slaves, at random
6969
$obj_cluster->setOption(
70-
RedisCluster::OPT_FAILOVER, RedisCluster::FAILOVER_DISTRIBUTE
70+
RedisCluster::OPT_SLAVE_FAILOVER, RedisCluster::FAILOVER_DISTRIBUTE
7171
);
7272
</pre>
7373

0 commit comments

Comments
 (0)