PHP code example of etitov-cm / yii2-redis

1. Go to this page and download the library: Download etitov-cm/yii2-redis library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

etitov-cm / yii2-redis example snippets


return [
    //....
    'components' => [
        'redis' => [
            'class' => 'etitov\redis\Connection',
            'master' => [
                '10.155.20.169:6379',
                '10.155.20.167:6391',
                '10.155.20.168:6379',
                '10.155.20.167:6380',
//                'localhost:6379',
            ],
            'database' => 0,
        ],


    ]
];