-
Notifications
You must be signed in to change notification settings - Fork 511
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Version
5.57.0
Platform
NodeJS
What happened?
This code is supposed to remove the completed
and failed
tasks after 20 seconds, but this doesn't happen.
await this.renewalQueue.add(
"process-renewal", {
userId: subscription.user_id,
planId: subscription.plan_id,
planName: subscription.plan_name,
credits: subscription.plan_credits,
}, {
jobId: `renewal-${subscription.user_id}`, // Deterministic ID
priority: 1, // High priority for renewals
removeOnComplete: {
age: 20,
},
removeOnFail: {
age: 20,
},
}
)
But the instant removal works fine.
{
removeOnComplete: true,
removeOnFail: true
}
How to reproduce.
Set a removeOnComplete.age
or a removeOnFail.age
for a task.
Relevant log output
Code of Conduct
- I agree to follow this project's Code of Conduct
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working