PHP code example of farmani / laravel-openswoole-redis-pool

1. Go to this page and download the library: Download farmani/laravel-openswoole-redis-pool 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/ */

    

farmani / laravel-openswoole-redis-pool example snippets


'default' => [
    'url' => env('REDIS_URL'),
    'host' => env('REDIS_HOST', 'redis.waptap.dev'),
    'password' => env('REDIS_PASSWORD', null),
    'port' => env('REDIS_PORT', '6379'),
    'database' => env('REDIS_DB', '0'),
    'read_timeout' => 3.0,
    'timeout' => 15.0,
    'retry_interval' => 0,
    'reserved' => '',
    'pool' => [
        'min' => 128,
        'max' => 128,
        'idle_time' => -1,
        'idle_interval' => 1000,
        'heartbeat' => 3000,
        'retry_interval' => 10,
        'retry_times' => 3,
    ],
],

'redis_pool' => [
    'driver' => 'redis',
    'connection' => 'default',
],