I have a strange behavior when a Job runs: On dev server (win 7 php 7.2.10) everything work fine, on the production server Linux centOS php 7.0.10 it throws an Exception:
Illuminate\Queue\MaxAttemptsExceededException: A queued job has been attempted too many times. The job may have previously timed out.
this happens after a job is queued ... when it starts working ... after about 30 seconds (Failed) the exception is in the failed_jobs table
I though it could be dependent by the php max_execution_time directive but when i do
php -r "echo ini_get('max_execution_time') . PHP_EOL;"
it shows me zero (no timeout ... which is correct)
the Job is queued in this way:
dispatch((new Syncronize($file))->onQueue('sync'));
The Sincronize Job has no timeout (has 1 try) and simply calls two artisan commands which work perfecly both on prod and on dev server if called from the shell.
to start jobs on the dev server I use
php artisan queue:work --queue=sync,newsletter,default
on prod server I use this
any idea of what can be the cause ?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire