Closed glensc closed 4 years ago
so far I've used php-resque to create jobs, and seems there the id and prefix is created by client when creating new job:
and node side encode:
seems the 'queue' being encoded as value is superfluous as well in node side.
There are no job-ids in Ruby's or Node-resuqe. That's a concept that the PHP fork introduced.
As we discussed in https://github.com/actionhero/node-resque/issues/334#issuecomment-638585235, I think adding Job IDs would be great addition to the package... but we don't have them yet.
@evantahler do you agree the queue in value is superfluous in node-resque? or it's used internally somewhere therefore needed?
I don't think so... if the job is delayed, the queue
param needs to be kept around to know the eventual work queue to move it into. Also, if the job fails, it will be useful to know which queue the failure was from... as perhaps you have different workers/apps working each queue.
Seems the queue api only returns boolean, no way to get any job id out of it, like for future polling of the job.
There isn't even any events on queue object (other than "error"), like could capture the job id via "job":
code