mirror of
https://github.com/hibiken/asynq.git
synced 2026-04-26 07:25:56 +03:00
[GH-ISSUE #756] Error callback handler when a task exhausted the retries limit #1385
Labels
No labels
CLI
bug
designing
documentation
duplicate
enhancement
good first issue
good first issue
help wanted
idea
invalid
investigate
needs-more-info
performance
pr-welcome
pull-request
question
wontfix
work in progress
work in progress
work-around-available
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/asynq#1385
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @khun84 on GitHub (Oct 5, 2023).
Original GitHub issue: https://github.com/hibiken/asynq/issues/756
Im would like to execute a callback when a task has exhausted all its retry limit. The closet I could find is the error predicate handler func. However the retry info wasnt exposed by this func.
Do we have this feature in asynq?
@ghstahl commented on GitHub (Jan 2, 2024):
I would like this as well. However, I would like to see the retry info being exposed directly to the handler.
When you call the task handler also send operational information like.
MaxRetries
CurrentRetry
etc
The use case for me is so that I can eat the error on the last retry and return a nil error. There are some cases where I DO NOT want the tasks going to the archive. I am tracking that information in my own db.
I have tasks that are LOW value, HIGH frequency and I don't care if they succeed in the END.
There are tasks that are HIGH value, LOW frequency that I may let go to the archive queue.
If my archive fills up with junk that I don't care about then it isn't useful and just a waste of resources.