You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using php artisan queue:work --sleep=3 --tries=3 the attempts attribute will not be updated so the job will be retried for an infinite amount of time. If we set --tries to 1, the job will be processed once
How should we fix this?
The text was updated successfully, but these errors were encountered:
Normally the attempt is stored in the job object itself. This is a problem in kafka, because the jobs are immutable. We can store an attempt elsewhere for example a cache.
But using kafka where the queue is persistent we should be able to complete all jobs without failing.
@petermein I checked the RabbitMQ library for Laravel and I found a solution to fix this. Since this library is based on the RabbitMQ, using the same solution fixes the issue (I changed the code and fixed the bug in my own project)
When using
php artisan queue:work --sleep=3 --tries=3
the attempts attribute will not be updated so the job will be retried for an infinite amount of time. If we set --tries to 1, the job will be processed onceHow should we fix this?
The text was updated successfully, but these errors were encountered: