|
|
@@ -97,6 +97,10 @@ return [
|
|
|
*/
|
|
|
|
|
|
'waits' => [
|
|
|
+ 'redis:payment-reconcile' => 30,
|
|
|
+ 'redis:notifications' => 60,
|
|
|
+ 'redis:broadcastable' => 60,
|
|
|
+ 'redis:api-logs' => 120,
|
|
|
'redis:default' => 60,
|
|
|
],
|
|
|
|
|
|
@@ -132,7 +136,7 @@ return [
|
|
|
*/
|
|
|
|
|
|
'silenced' => [
|
|
|
- // App\Jobs\ExampleJob::class,
|
|
|
+ \Webkul\BagistoApi\Jobs\LogApiRequestJob::class,
|
|
|
],
|
|
|
|
|
|
'silenced_tags' => [
|
|
|
@@ -190,40 +194,87 @@ return [
|
|
|
| Queue Worker Configuration
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
|
|
- | Here you may define the queue worker settings used by your application
|
|
|
- | in all environments. These supervisors and settings handle all your
|
|
|
- | queued jobs and will be provisioned by Horizon during deployment.
|
|
|
+ | Supervisors are split so a slow index or image conversion on `default`
|
|
|
+ | cannot block payment reconciliation or outbound alerts. Horizon's
|
|
|
+ | supervisor `tries` and `timeout` override the same properties on a job.
|
|
|
+ |
|
|
|
+ | `timeout` must stay below the Redis connection `retry_after`
|
|
|
+ | (config/queue.php, REDIS_QUEUE_RETRY_AFTER). The longest timeout here
|
|
|
+ | is 120 seconds, so retry_after is 150.
|
|
|
+ |
|
|
|
+ | APP_ENV must be `production` or `local`. Any other value falls back to
|
|
|
+ | `defaults` (one process per supervisor).
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
'defaults' => [
|
|
|
- 'supervisor-1' => [
|
|
|
+ 'payments' => [
|
|
|
'connection' => 'redis',
|
|
|
- 'queue' => ['default'],
|
|
|
- 'balance' => 'auto',
|
|
|
- 'autoScalingStrategy' => 'time',
|
|
|
+ 'queue' => ['payment-reconcile'],
|
|
|
+ 'balance' => 'simple',
|
|
|
'maxProcesses' => 1,
|
|
|
'maxTime' => 0,
|
|
|
'maxJobs' => 0,
|
|
|
'memory' => 128,
|
|
|
- 'tries' => 1,
|
|
|
+ 'tries' => 3,
|
|
|
'timeout' => 60,
|
|
|
+ 'sleep' => 1,
|
|
|
+ 'nice' => 0,
|
|
|
+ ],
|
|
|
+
|
|
|
+ 'signals' => [
|
|
|
+ 'connection' => 'redis',
|
|
|
+ 'queue' => ['notifications', 'broadcastable', 'api-logs'],
|
|
|
+ 'balance' => 'simple',
|
|
|
+ 'maxProcesses' => 1,
|
|
|
+ 'maxTime' => 0,
|
|
|
+ 'maxJobs' => 0,
|
|
|
+ 'memory' => 128,
|
|
|
+ 'tries' => 3,
|
|
|
+ 'timeout' => 30,
|
|
|
+ 'nice' => 0,
|
|
|
+ ],
|
|
|
+
|
|
|
+ 'default' => [
|
|
|
+ 'connection' => 'redis',
|
|
|
+ 'queue' => ['default'],
|
|
|
+ 'balance' => 'auto',
|
|
|
+ 'autoScalingStrategy' => 'time',
|
|
|
+ 'maxProcesses' => 1,
|
|
|
+ 'balanceMaxShift' => 1,
|
|
|
+ 'balanceCooldown' => 3,
|
|
|
+ 'maxTime' => 0,
|
|
|
+ 'maxJobs' => 500,
|
|
|
+ 'memory' => 256,
|
|
|
+ 'tries' => 3,
|
|
|
+ 'timeout' => 120,
|
|
|
'nice' => 0,
|
|
|
],
|
|
|
],
|
|
|
|
|
|
'environments' => [
|
|
|
'production' => [
|
|
|
- 'supervisor-1' => [
|
|
|
- 'maxProcesses' => 10,
|
|
|
- 'balanceMaxShift' => 1,
|
|
|
- 'balanceCooldown' => 3,
|
|
|
+ 'payments' => [
|
|
|
+ 'maxProcesses' => 2,
|
|
|
+ ],
|
|
|
+ 'signals' => [
|
|
|
+ 'maxProcesses' => 2,
|
|
|
+ ],
|
|
|
+ 'default' => [
|
|
|
+ 'minProcesses' => 1,
|
|
|
+ 'maxProcesses' => 6,
|
|
|
],
|
|
|
],
|
|
|
|
|
|
'local' => [
|
|
|
- 'supervisor-1' => [
|
|
|
- 'maxProcesses' => 3,
|
|
|
+ 'payments' => [
|
|
|
+ 'maxProcesses' => 1,
|
|
|
+ ],
|
|
|
+ 'signals' => [
|
|
|
+ 'maxProcesses' => 1,
|
|
|
+ ],
|
|
|
+ 'default' => [
|
|
|
+ 'maxProcesses' => 2,
|
|
|
],
|
|
|
],
|
|
|
],
|