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

Introduce communication channel from workflow-controller to executor through pod annotations #682

Merged
merged 1 commit into from
Jan 16, 2018

Conversation

jessesuen
Copy link
Member

@jessesuen jessesuen commented Jan 13, 2018

This change creates a downward communication channel from the controller to executor through
the use of pod annotations. Its initial use will be to terminate daemoned containers by
updating 'ExecutionControl' parameters to the executor. In this case, it updates the deadline
value to be a zero-value timestamp. The executor has been modified to now monitor updates to the annotations and will obey the updated deadline, allowing deadlines to be set/updated/unset after initial start.

In the future, ExecutionControl can be extended to support things like workflow, step, dag
level timeouts, as well as the ability to to cancel a workflow without deleting pods.

Resolves issue #499.
Partially implements support for #527.

@jessesuen
Copy link
Member Author

The contents of the new file steps.go is code which moved from operation.go but with tweaked killDeamonedChildren to use the new method updateExecutionControl().

@jessesuen jessesuen force-pushed the execution-control branch 2 times, most recently from 63c3753 to f431bfe Compare January 13, 2018 01:02
@jessesuen jessesuen mentioned this pull request Jan 15, 2018
command: [cowsay]
args: ["hello world"]
command: [sh, -c]
args: ["sleep 30"]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this needed?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a mistake. Thanks for catching this.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

…through pod annotations

This change creates a downward communication channel from the controller to executor through
the use of pod annotations. Its initial use will be to terminate daemoned containers by
updating 'ExecutionControl' parameters to the executor. In this case, it updates the deadline
value to be a zero-value timestamp. The executor now monitors updates to the annotations and
will use the updated deadline, allowing deadlines to be set/updated/unset after initial start.

In the future, ExecutionControl can be extended to support things like workflow, step, dag
level timeouts, as well as the ability to to cancel a workflow without deleting pods.
@jessesuen jessesuen merged commit a1f821d into argoproj:master Jan 16, 2018
@jessesuen jessesuen deleted the execution-control branch January 16, 2018 21:13
icecoffee531 pushed a commit to icecoffee531/argo-workflows that referenced this pull request Jan 5, 2022
* feat: Add afterStart filter to resource type eventsource

* examples

* fix testcase

* refac

* test case

* added log

* new line

* go mod tidy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants