This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

shoguniphicus
shoguniphicus

Hi, I am having trouble setting up proper Queue with OctoberCMS. I have no problem register commands in plugin. But when it comes to executing a queue. Nothing seems to be running correctly.

I tried

 $date = Carbon::now()->addMinutes(1);
Queue::later($date, new \Ido\Notify\Console\Weekly());

The jobs' table seems to clear up after 1 minute, which is fine, but the functions within the class isn't triggered, namely, handle() or fire(). When I tried example on October's document, which is "SendEmail", it will just register in jobs and forever will be trying and forever will keep trying.

Can someone give me a pointer as to how to setup a queue handler in OctoberCMS?

Thanks!

Crazymodder
Crazymodder

Hi,

Do you provide a queue service under config/queue.php ?

Amazon, BeanStalkd, Iron or Redits need this plugin: http://octobercms.com/plugin/october-drivers

Did you start artisan queue:listen ?

Please check docu for more infos

http://octobercms.com/docs/services/queues

meetshogun10601
meetshogun10601

I think I left out the part where I had done the proper configuration and have also setup supervisor to always run the queue on separate process in the server. So that's that, because I am able to use Mail::queue that is queued properly and fired properly.

So the question is how come my attempt to use my own class fails? I tried following the example, but the queue just added as "queue:SendEmail..." that doesn't make any sense as there is no way Queue is going to resolve the dependency out of thin air. And when I pass in a class, which extends Command and implements ShouldQueue and SelfHandling, the Queue does nothing and forver is retrying, cause I can see the spike in ID's in queue table.

1-3 of 3

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.