argoproj / argo-workflows

Workflow Engine for Kubernetes
https://argo-workflows.readthedocs.io/
Apache License 2.0
15.06k stars 3.2k forks source link

Add "reason" parameter when terminating and resuming a Workflow #12602

Open lrochette opened 9 months ago

lrochette commented 9 months ago

Summary

Allow additional parameter when a workflow is terminated or resumed

Use Cases

When a workflow is terminated by an external system, there is no indication on why it was terminated Having some kind of additional data that could be show as an output parameter on the task where the workflow is suspended would enhance communication


Message from the maintainers:

Love this enhancement proposal? Give it a 👍. We prioritize the proposals with the most 👍.

Joibel commented 9 months ago

Could you explain your use case better please?

You could already add annotations to the workflow to hold any metadata you would like, including this.

lrochette commented 9 months ago

By allowing a "reason" element to the API, we could turn it into an output parameter for the "pause" task My exact use case right now is a CI build who is paused until a Change Request has been approved in ServiceNow. The resume/terminate is issues from the ServiceNow instance and a reason is added for the decision This can then be used later on for logic. Annotation would make it more complex for worflows with multiple pauses (aka on per environment)