vudrok's avatar

Dispatch a Job from Queue::after( ) a Job

Hi, I've been working on creating a Job that will execute several processes out of an external API, this task is working great, but I want to execute an after job, so I am using the Queue::after( ) and trying to dispatch it from there.

The after queue Job is not firing up, I have tried to move it directly to the handle method, but it will not work either. Is it a limitation of Lumen? Can I import some library that will make this work? Please if you can help me I will be so grateful.

Regards,

0 likes
1 reply
vudrok's avatar

An update on this issue, I fixed it, It wasn't dispatching the job within the job what was failing, it was the way I was using the Queue::after() this should be used only in the Provider boot method, there is no method you could override in a Job to execute a task after succeeding or processed, I wish there was for chaining dependency jobs, like in my case interacting with several API's in which one depends on the other.

Please or to participate in this conversation.