Published 1 week ago by Ranx99
In Laravel Horizon's settings:
'local' => [ 'supervisor-1' => [ 'connection' => 'redis', 'queue' => ['default'], 'balance' => 'simple', 'processes' => 3, 'tries' => 3, ], ],
queuesetting, as I understand this setting is for separating my queues ( Ex: uploadImageQueue, verfyEmailQueue, etc.. ) is this the right? is there a limit for the number of queues I can set?
There is no hard and fast rule on the correct number of processes, depends on how many jobs you are processing. If your noticing an unacceptable wait time then add another process.
Your server specification will ultimately determine how many processes you can run. If you CPU starts running at 100% then you need to reduce you processes, increase hardware or look at distributing your queues across multiple servers.
Queues related to the settings in
config/queue.php. You can use these to give different queues different properties like timeout. You can configure as many queues as you need.
@Ranx99 - I depends on how many registration emails you need to send. Start with one process and monitor the wait time of jobs on that queue. If it gets too large for your application then double your processes, repeat as necessary (obviously within constraints of your hardware).
You can set up a cron job to monitor wait times as per