FULL STOP. The single best thing you can do is go read William Vicary's article on setting up long running jobs with Laravel Horizon. It's amazing, and will walk you through a complete setup. He does it BETTER and more succinctly that I did.
https://medium.com/@williamvicary/long-running-jobs-with-laravel-horizon-7655e34752f7
Issue
Laravel Horizon Not Updating For Additional Queues
;TLDR
When adding a new queue to your app/config/queue.php file (see QUEUE image):
Make sure you ALSO add it to the app/config/horizon.php file underneath the supervisor for production and/or local depending on your needs (see HORIZON image):
Restart horizon (php artisan horizon:terminate, then php artisan horizon)
QUEUE Image:
HORIZON Image:
Background
I created a new queue within redis that is meant to hold all my jobs that are responsible for pulling data in from various external API’s, and restarted the Horizon process. I dispatched a job that used the new queue, and saw the job appear on the Horizon queue with the yellowish-orange (technical term) pause button…which means it was kicked off. Five minutes later, it was still that color…and on prior runs, this process took approximately 5 seconds.
RUH ROH RAGGY:
Solution
I couldn’t find anything in the Laravel docs regarding providing additional details on “adding more queues to Horizon” - but notably, I could have just missed them (I didn’t).
I did find a Deep Dive on Horizon by Mohamed Said, which had the following intriguing picture:
I added my ‘external-api’ queue to both entries for the horizon supervisor and rebooted Horizon. The queues initially loaded in their same state (yellow-orange pause button), but immediately changed to the green checkmark.
KISSES FINGERS LIKE CHEF: