training-operator
training-operator copied to clipboard
Inconsistent implementation in UpdateJobStatusInApiServer method
In the following codes, they are UpdateJobStatusInApiServer method implementation in different Job. They are very similar but different. It is very confusing when programmers read the codes.
- Does
trainingoperatorcommon.ClearGeneratedFields()method need? - Does
reflect.DeepEqual()method need? - What is the difference between
reflect.DeepEqual()andequality.Semantic.DeepEqual()? - Does
jc.Log.WithValues()need? It seems did nothing.
Referring to point4 of https://github.com/kubeflow/training-operator/issues/1703
https://github.com/kubeflow/training-operator/blob/e13d262fe4fabd548ded944e5356c99f30a33b00/pkg/controller.v1/mpi/mpijob_controller.go#L646-L678
https://github.com/kubeflow/training-operator/blob/e13d262fe4fabd548ded944e5356c99f30a33b00/pkg/controller.v1/mxnet/mxjob_controller.go#L430-L451
https://github.com/kubeflow/training-operator/blob/e13d262fe4fabd548ded944e5356c99f30a33b00/pkg/controller.v1/pytorch/pytorchjob_controller.go#L483-L511
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
cc @johnugeorge @tenzen-y @kuizhiqing
/remove-lifecycle stale
Yes, we should refactor the UpdateJobStatusInApiServer.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
/lifecycle frozen