-
Notifications
You must be signed in to change notification settings - Fork 700
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
fix UpdateJobStatusInApiServer when gang-scheduling is enabled #1549
Conversation
Pull Request Test Coverage Report for Build 1996436561
💛 - Coveralls |
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.
/lgtm
That's a nice catch. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: gaocegege, zw0610 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 |
I have one comment on this. Since we don't use webhook, it's a little bit hard to mutate obj prior reconciliation. We do have similar cases like below. The tricky thing is we should invoke these method in the right place. In this cases, it definitely operate object before initialization which bring the problems.
training-operator/pkg/controller.v1/tensorflow/util.go Lines 99 to 105 in 4b5d651
|
Should we involve a webhook for the operator? |
Isn't this to be handled by a webhook? |
When
--enable-gang-scheduling
is enabled, for jobs with PodGroup in pending phase, the operator will update the JobStatus with only itsLastReconcileTime
being changed. That means thejobStatus.replicaStatues
could be nil when being pushed to the APIServer, triggering an error message.This PR add a fix procedure for all controllers to give an empty value for
jobStatus.replicaStatues
if nil.