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(webhook): add task dependson webhook #1920
feat(webhook): add task dependson webhook #1920
Conversation
Signed-off-by: shinytang6 <1074461480@qq.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you need to check if the task name in task.depedensOn is in the job?
By the way, Very well written about dag. tql.
I think it is not necessary. If there is an illegal taskName defined in dependsOn, it will not form a dag and rejected by webhook. |
/lgtm |
|
||
// topoSort uses topo sort to sort job tasks based on dependsOn field | ||
// it will return an array contains all sorted task names and a bool which indicates whether it's a valid dag | ||
func topoSort(job *batchv1alpha1.Job) ([]string, bool) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work for topoSort
and makeGraph
functions!
@renhuanyu These can be helpful for hierarchical queue check, too. Please pay attentions.
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: Thor-wl The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Signed-off-by: shinytang6 1074461480@qq.com
prior pr: #1833