lambooni
11 months ago
37
1
Forge

Horizion - Queue worker on forge vs. app config code (queue.php / horizion.php)

Posted 11 months ago by lambooni

I would like to get some clarification on the queue worker settings within forge vs. within my code config.

Within horizion.php

    'environments' => [
        'production' => [
            'supervisor-1' => [
                'connection' => 'redis',
                'queue' => ['default'],
                'balance' => 'simple',
                'processes' => 10,
                'tries' => 3,
            ],
            'supervisor-long-running' => [
                'connection' => 'redis',
                'queue' => ['default_long'],
                'balance' => 'simple',
                'processes' => 2,
                'tries' => 2,
                'timeout' => 900 // Timeout after 15 minutes
            ]
        ],

and queue.php

        'redis' => [
            'driver' => 'redis',
            'connection' => 'default',
            'queue' => 'default',
            'retry_after' => 90,
            'block_for' => null,
        ],

        'redis-long-running' => [
            'driver' => 'redis',
            'connection' => 'default',
            'queue' => 'default_long',
            'retry_after' => 1200, // Run for max 20 minutes
            'block_for' => null,
        ],

I can now send jobs to either queues and they seem to run fine.

Within Forge, under the site > queues tab I now have the option to start queue workers. Are these going to be any different to what I have setup within the config. Should I run both or just one of them?

Please sign in or create an account to participate in this conversation.