Sorry here is my code:
For the batch i am building it like this:
$batch = Bus::batch($jobs)
->allowFailures()
->then(function (Batch $batch) {
$batch->delete();
})->catch(function (Batch $batch, Throwable $e){
Log::error('The Job: ' . $batch->failedJobIds[0] . ' has failed.');
})
->name('Test Jobs for redis')
->onQueue('{redis-dev}'
->dispatch();
my queues are setup like this:
connections' => [
'redis-dev' => [
'driver' => 'redis',
'connection' => 'default',
'queue' => 'redis-dev',
'retry_after' => 1200,
'block_for' => null,
'after_commit' => false,
],
],
And my database Queue section is etup like this:
redis' => [
'client' => 'phpredis',
'options' => [
'cluster' => 'redis',
'prefix' => '{mmr}_',
'persistent' => false,
],
'default' => [
'host' => 'tls://dsfajfhsdfjkasdfh.serverless.use1.cache.amazonaws.com',
'username' => null,
'password' => null,
'port' => '6379',
'database' => '0',
'options' => [
'prefix' => '{mmr}_',
],
],
record in the porstgresql database in job_batches get created, i can see on redis where is also gets created.
but when i run php artisan queue:monitor redis-dev
what is how is:
Queue name ......................................................................................................................... Size / Status
[default_redis] redis-dev ................................................................................................................. [0] OK
Pending jobs ................................................................................................................................... 0
Delayed jobs ................................................................................................................................... 0
Reserved jobs .................................................................................................................................. 0
and the job never starts even though i can see it in redis. Also i have horizon running but no workers for this queue because i manually run the worker for this queue that is how i can see it in pending jobs.