mardi 30 avril 2019

Run Laravel queue on production


Could you please share your best solution for run Laravel queue on production server?

For now I see next solution:

  1. First start queue:
php artisan queue:work >> /var/log/queue.log &

  1. Add to crontab:
10 2 * * * php artisan queue:restart
11 2 * * * php artisan queue:work >> /var/log/queue.log &

  1. In case of project update on server:
php artisan down
php artisan queue:restart
#do update
php artisan queue:work >> /var/log/queue.log &
php artisan up

But I'm worrying about high load case. What if some job will be stucked?
Maybe you have better solution?



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire