After run command:
php artisan horizon
Return the message: Horizon started successfully
And after 2 seconds return:
In QueueManager.php line 172:
No connector for [redis]
This error returned periodically in the console. In Horizon dashboard status is active
ENV:
QUEUE_DRIVER=redis
REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379
database.php
'redis' => [
'client' => 'predis',
'default' => [
'host' => env('REDIS_HOST', '127.0.0.1'),
'password' => env('REDIS_PASSWORD', null),
'port' => env('REDIS_PORT', 6379),
'database' => 0,
],
]
queue.php
'redis' => [
'driver' => 'redis',
'connection' => 'default',
'queue' => 'default',
'retry_after' => 90,
]
horizon.php
'GetMedia' => [
'connection' => 'redis',
'queue' => ['getmedia'],
'balance' => 'simple',
'processes' => 2,
'tries' => 2,
]
Where is the probleme? No connector for [redis]?
And is it not clear to me if Horizon monitor and processing jobs or just monitor it?
if you change the horizon config to queue default do you still have the same problem?
.env
APP_ENV=qa
horizon.php
'qa' => [
'connection' => 'redis',
'queue' => ['default'],
'balance' => 'simple',
'processes' => 3,
'tries' => 3,
]
I used APP_ENV=local and horizon environments local:
'environments' => [
'local' => [connection' => 'redis',
'queue' => ['default'],
Same problem..
Did either of you ever get to the bottom of this? I'm having the same issue!
I'm sure the originator of this issue has now solved this issue but I had the same recently and wanted to quickly share the cause in case it helps someone else.
Another package we had installed (AWS Worker thingy by Dusterio) was resolving an instance of the QueueManager singleton in its own service provider. This was blowing away all the connectors that had been loaded into the QueueManager originally which causes the 'No connector for [redis] error'. The issue was clear when I could see connectors loaded and then the array suddenly becoming empty. in debugging.
A project-wide search for QueueManager revealed the problem vendor package.
Hope this helps someone.
Closing this issue because it's already solved, old or not relevant anymore. Feel free to reply if you're still experiencing this issue.
Most helpful comment
I'm sure the originator of this issue has now solved this issue but I had the same recently and wanted to quickly share the cause in case it helps someone else.
Another package we had installed (AWS Worker thingy by Dusterio) was resolving an instance of the QueueManager singleton in its own service provider. This was blowing away all the connectors that had been loaded into the QueueManager originally which causes the 'No connector for [redis] error'. The issue was clear when I could see connectors loaded and then the array suddenly becoming empty. in debugging.
A project-wide search for QueueManager revealed the problem vendor package.
Hope this helps someone.