yiisoft / yii2-redis

Yii 2 Redis extension.
http://www.yiiframework.com
BSD 3-Clause "New" or "Revised" License
452 stars 183 forks source link

How to configure the Connection for redis cluster?@samdark@hofrob #197

Open zzqlleo opened 4 years ago

zzqlleo commented 4 years ago

for example: 'redis' => [ 'class' => 'yii\redis\Connection', 'servers'=>[ ['hostname' => '127.0.0.1','port'=> 6379], ['hostname' => '127.0.0.1','port'=> 6380], ['hostname' => '127.0.0.1','port'=> 6381], ] ],

samdark commented 4 years ago

https://www.yiiframework.com/extension/yiisoft/yii2-redis/doc/api/2.0/yii-redis-cache#$replicas-detail

I think it could be added to docs as well...