Skip to content
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

The global retryStrategy is only for Pod type (not Step/DAG template) #13990

Open
shuangkun opened this issue Dec 12, 2024 · 6 comments
Open
Labels
area/retryStrategy Template-level retryStrategy type/feature Feature request

Comments

@shuangkun
Copy link
Member

Summary

I hope to configure the global retryStrategy uniformly, but I don't want the Step/DAG type retry to cause the task to be re-run.

Use Cases

Very complex workflow with unified retryStrategy, do not want to configure retryStrategy in each template.
Do not want to configure memoize, which is troublesome for developers.
Do not want the retry of Steps/DAG type template to cause the completed tasks to be re-run.


Message from the maintainers:

Love this feature request? Give it a 👍. We prioritise the proposals with the most 👍.

@shuangkun shuangkun added the type/feature Feature request label Dec 12, 2024
@jswxstw
Copy link
Member

jswxstw commented Dec 12, 2024

Completely agree! Setting retryStrategy uniformly in templateDefaults is simply a disaster: #13297 (comment).

@tczhao
Copy link
Member

tczhao commented Dec 13, 2024

Maybe we can filter node type in retry expression

@tczhao tczhao added the area/retryStrategy Template-level retryStrategy label Dec 13, 2024
@shuangkun
Copy link
Member Author

Maybe we can filter node type in retry expression

Yes, I tried to do that once, but couldn't find a variable to use directly. https://argo-workflows.readthedocs.io/en/latest/variables/ Maybe we need to add a variable to each template to identify which template it is.
Another way is to add a field in the retryStratepy at the workflow level, such as retryNodeType: [Steps, DAG, Container, Script, HTTP...]

@jswxstw
Copy link
Member

jswxstw commented Dec 13, 2024

Maybe we need to add a variable to each template to identify which template it is.

if woc.retryStrategy(processedTmpl) != nil {

It seems that we only need to add a filtering condition here? Or should we add a new field or add a new retry policy in retryStrategy to control this?

processedTmpl.IsPodType() && woc.retryStrategy(processedTmpl) != nil

@shuangkun
Copy link
Member Author

Yes. Whether adding filtering conditions or adding new fields, there needs to be a condition for the user to trigger. Either use expression or use retryNodeType configuration.

@jswxstw
Copy link
Member

jswxstw commented Dec 20, 2024

Completely agree! Setting retryStrategy uniformly in templateDefaults is simply a disaster: #13297 (comment).

The global retryStrategy will also cause the entire workflow topology and state to become inconsistent when hooks are used, see #13239 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/retryStrategy Template-level retryStrategy type/feature Feature request
Projects
None yet
Development

No branches or pull requests

3 participants