Quantcast
Channel: StackExchange Replication Questions
Viewing all articles
Browse latest Browse all 17268

How to set laravel redis M/S replication through cache facade

$
0
0

How could I make the configuration for cache in laravel to accept master slave replication

I tried to make a direct predis client, and it worked but I want to apply the replication to the whole project through the cache facade

The configuration file is look like the following

'redis' => [
        'default' => [
            'host1' => [
            'host' => host1,
            'port' => port1,
            'alias' => 'master',
            ],
            'host2' =>[
                'host' => host2,
                'port' => port2,
                'alias' => 'slave-01',
            ],
            'options' => [
                'replication' => true,
            ],
        ],
    ],

but it didn't work


Viewing all articles
Browse latest Browse all 17268

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>