我的用例是创建动态延迟作业。(我正在使用,它可以用来创建延迟的就业机会。)
基于,一些事件给延迟间隔(进一步延迟作业)添加了更多的延迟。
由于找不到任何function来更新作业的延迟间隔,所以我提出了以下步骤:
onEvent(jobId):
// queue is of Type Bull.Queue
// job is of type bull.Job
job = queue.getJob(jobId)
data = job.data
delay = job.toJSON().delay
job.remove()
queue.add("jobName&
这个问题是这个主题Repeatable jobs not getting triggered at given cron timing in Bull的续篇 我也面临着同样的问题。我应该如何指定时区?我尝试指定为repeat:{ cron:'* 7 14 *',tz:‘欧洲/柏林’} 这意味着在德国时区14:07触发作业。虽然作业在队列中列出,但作业不会被触发。 我也尝试重复:{ cron:'* 50 15 *',offset: datetime.getTimezoneOffset(),tz:‘欧洲/柏林’}
在我们从1.68.1迁移到JavaMelody 1.88之后,我们得到了这条消息。通常是在我们启动应用服务器之后?有人能帮我们吗?
java.io.IOException: Could not release [<any_path>/springe4b951a1e22fd7add5aed6f9f81d9023cca34a88.rrd], the file was never requested
at net.bull.javamelody.internal.model.JRobin.createIOException(JRobin.java:569) ~[javamelod
我想知道如何通过Queue/Bull在我的函数'myCustomMethod‘中运行代码。这样做对吗?
./models/Sport.js
export async function myCustomMethod(type, req)
{
console.log("This method should be executed via the Queue / Bull");
let computationResult = true;
return computationResult;
}
cronCustomFile.js
import { myC
var Queue = require('bull');
// Init queue
var workQueue = new Queue("workQueue", "redis://pass@ip:6379");
// Add 10 jobs to the queue
for (i=0; i<10; i++) {
workQueue.add({msg:i});
}
// Get # of jobs in queue
workQueue.count(); // <-- does not return queue job c