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

feat: Step and Task Level Global Timeout #3686

Merged
merged 31 commits into from
Sep 3, 2020

Conversation

sarabala1979
Copy link
Member

Checklist:

@simster7 simster7 self-assigned this Aug 6, 2020
@sarabala1979 sarabala1979 marked this pull request as ready for review August 24, 2020 15:44
// Max duration allows for the node execution from node StartTime.
// This duration includes node pending state also.
// This duration will not be applied on Step and DAG type Templates
TimeoutDuration *intstr.IntOrString `json:"timeoutDuration,omitempty" protobuf:"bytes,38,opt,name=timeoutDuration"`
Copy link
Member

Choose a reason for hiding this comment

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

Has @jessesuen approved this new API?

pkg/apis/workflow/v1alpha1/workflow_types.go Outdated Show resolved Hide resolved
workflow/controller/operator.go Outdated Show resolved Hide resolved
workflow/controller/operator.go Outdated Show resolved Hide resolved
workflow/controller/operator.go Outdated Show resolved Hide resolved
workflow/controller/operator.go Outdated Show resolved Hide resolved
workflow/controller/operator.go Outdated Show resolved Hide resolved
workflow/controller/operator.go Outdated Show resolved Hide resolved
workflow/controller/workflowpod.go Outdated Show resolved Hide resolved
workflow/controller/workflowpod.go Outdated Show resolved Hide resolved
Copy link
Member

@simster7 simster7 left a comment

Choose a reason for hiding this comment

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

Minor comments, please make sure @jessesuen approves the API change

Comment on lines +1704 to +1706
if node.Phase == wfv1.NodePending && time.Now().After(deadline) {
return nil, fmt.Errorf("%s %s exceeded its deadline", node.Name, node.Type)
}
Copy link
Member

Choose a reason for hiding this comment

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

Why is this only when node.Phase == wfv1.NodePending? Shouldn't this check be made regardless of phase?

Copy link
Member Author

@sarabala1979 sarabala1979 Sep 2, 2020

Choose a reason for hiding this comment

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

This code is mainly handling for nodes that are pending because of waiting for sync lock or parallelism. Rest of state will be handle in createPod function

workflow/controller/workflowpod.go Outdated Show resolved Hide resolved
workflow/controller/operator_test.go Outdated Show resolved Hide resolved
@sarabala1979 sarabala1979 merged commit 5a0c515 into argoproj:master Sep 3, 2020
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.

If step is in pending state, step timeout(active deadline seconds) is not working
4 participants