Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

Bernard123's avatar

The queue:work Jobs Are Not Running Properly

Hello, I want to ask why my queue:work command always times out and shows a message in Telescope like 'App\Jobs\Mailing has timed out.' Yesterday or a few days ago, it was running properly without any timeouts. Are there any possible solutions?

0 likes
6 replies
Glukinho's avatar

What is inside App\Jobs\Mailing class?

The most obvious thing is you connect to unreachable mail server without timeout, infinitely.

Bernard123's avatar

Thanks for your comment on my forum post.

The App\Jobs\Mailing class simply calls Mail::to($receiver)->send($mail).

However, it worked before using the same mailing environment

Glukinho's avatar

@Bernard123 Again, what is inside App\Jobs\Mailing class? Can you show it?

If queue worker timeouts a job, it means this job does something for too long (longer than worker allows). To investigate what takes so long, we need to see job class content.

Also, do you set any options on php artisan queue:work? --timeout option can affect too.

Glukinho's avatar

@Bernard123

The App\Jobs\Mailing class simply calls Mail::to($receiver)->send($mail)

Try to execute the same in php artisan tinker and see does sending actually occur and how long it takes. I still think your mail server does not respond which produces timeout.

Bernard123's avatar

@Glukinho Umm, I don't think there's anything making it take longer. It's just a simple query on a 10–20 row database, and none of my queued jobs are being processed. I haven't set any timeout options — I'm just running it with php artisan queue:work database --queue=mailing

Please or to participate in this conversation.