0

I have an issue where on production jobs do not fail when they exceed the timeout that is set in the config but they run longer and then they timeout.

The timeout for the default queue is 60 seconds, but in the horizon UI i see that jobs fail after 60 up to 220 seconds. When i put a sleep in the job on a test environment or locally it works as expected and the jobs fail after 60 seconds.

 'defaults' => [
        'supervisor-1' => [
            'connection' => 'redis',
            'queue' => ['default', 'other-queue'],
            'balance' => 'auto',
            'maxProcesses' => 1,
            'memory' => 128,
            'tries' => 1,
            'timeout' => 60,
            'retry_after' => 120,
        ],
        'supervisor-2' => [
            'connection' => 'redis',
            'queue' => ['archive'],
            'balance' => 'auto',
            'maxProcesses' => 1,
            'memory' => 128,
            'tries' => 1,
            'timeout' => 180,
            'retry_after' => 300,
        ],
    ],
    'environments' => [
        'production' => [
            'supervisor-1' => [
                'maxProcesses' => 10,
                'balanceMaxShift' => 1,
                'balanceCooldown' => 3,
            ],
            'supervisor-2' => [
                'maxProcesses' => 10,
                'balanceMaxShift' => 1,
                'balanceCooldown' => 3,
            ],
        ],
        'local' => [
            'supervisor-1' => [
                'balanceMaxShift' => 1,
                'maxProcesses' => 3,
            ],
        ],
        'acceptance' => [
            'supervisor-1' => [
                'balanceMaxShift' => 1,
                'maxProcesses' => 3,
            ],
            'supervisor-2' => [
                'balanceMaxShift' => 1,
                'maxProcesses' => 3,
            ],
        ],
    ],

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.