-
Notifications
You must be signed in to change notification settings - Fork 148
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Workflow.retry that takes a function to decide if retry is needed #806
Comments
Is there an ETA about when this could be tackled? :) |
@niegus We typically don't provide ETAs for feature requests. Contributions are welcomed, this is a great starter issue. |
How do you envision this feature? If there is a new function/lambda to decide if the retry is need, how it would work with the current behavior? Taking precedence over them? Validate on the creation of the |
cc: @Spikhalskiy @mfateev |
I think to have it consistent, it should be But I'm getting back the comment about the great starter issue. |
@Spikhalskiy This feature request comes from this thread: https://community.temporal.io/t/temporal-queue-activities/3095/8 to retry in certain cases, Eg.
IMHO (as a customer of this lib) it would be easier:
WDYT? Would that make sense? |
Is your feature request related to a problem? Please describe.
Workflow.retry
RetryOptions.doNotRetry is a list of strings. So any exception is converted to a string before matching. In many scenarios, the retry is based on a specific information in a specific exception down the chain or even on some other information within the workflow body.Describe the solution you'd like
An API that takes a function (or lambda) that can execute random user provided logic to decide if retry is needed.
Additional context
This only works for retries from the workflow code. The service side retries have to rely on string matching in the current architecture. An activity already can decide itself that the error is not retryable by throwing an non-retryable ApplicationFailure.
The text was updated successfully, but these errors were encountered: