123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- <?php
- declare(strict_types=1);
- /**
- * This file is part of Hyperf.
- *
- * @link https://www.hyperf.io
- * @document https://hyperf.wiki
- * @contact group@hyperf.io
- * @license https://github.com/hyperf/hyperf/blob/master/LICENSE
- */
- use function Hyperf\Support\env;
- return [
- 'default' => [
- 'host' => env('REDIS_HOST', '127.0.0.1'),
- 'auth' => env('REDIS_AUTH', '123456'),
- 'port' => (int) env('REDIS_PORT', 6379),
- 'db' => (int) env('REDIS_DB', 0),
- 'pool' => [
- 'min_connections' => 1,
- 'max_connections' => 100,
- 'connect_timeout' => 100000000.0,
- 'wait_timeout' => 30000000.0,
- 'heartbeat' => -1,
- 'max_idle_time' => (float) env('REDIS_MAX_IDLE_TIME', 6000000000),
- ],
- 'driver' => Hyperf\AsyncQueue\Driver\RedisDriver::class,
- 'redis' => [
- 'pool' => 'default'
- ],
- 'channel' => '{queue:import}',
- 'timeout' => 20,
- 'retry_seconds' => 5,
- 'handle_timeout' => 10,
- 'processes' => 100,
- 'concurrent' => [
- 'limit' => 10000,
- ],
- 'max_messages' => 0,
- ],
- 'import' => [
- 'driver' => Hyperf\AsyncQueue\Driver\RedisDriver::class,
- 'redis' => [
- 'pool' => 'default'
- ],
- 'channel' => '{queue:import}',
- 'timeout' => 20,
- 'retry_seconds' => 5,
- 'handle_timeout' => 10,
- 'processes' => 100,
- 'concurrent' => [
- 'limit' => 10000,
- ],
- 'max_messages' => 0,
- ],
- ];
|