-
Notifications
You must be signed in to change notification settings - Fork 77
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
implement registration and listening of crd trainingjob #565
Conversation
trainingjobSynced cache.InformerSynced | ||
|
||
// TODO jobtracker keep track of every training job | ||
jobtracker map[string]interface{} |
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.
the interface will be replaced with specific type for managing training job.
if !ok { | ||
glog.Infof("create a new job tracker, key: '%s'", key) | ||
glog.Infof("received job: %+v", job) | ||
// TODO create a tracker for the job, just record its name here |
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.
TODO create a tracker for the job here
Anyway, can you please split this PR to several small PRs so that I can review. |
Thanks for your advice, I will split the pr and submit one by one. |
I will split the pr into three parts:
Is this reasonable? @typhoonzero |
@m3ngyang Sure! |
I have implemented a custom resource definition for paddle training job. The changes in this PR include:
go/pkg/controller
, responsible for the registration and listening for CRD TrainingJob, and creating a job tracker for each training job to manage its whole lifecyclego/pkg/client
, auto generated codes for CRD client and informergo/hack
, use our own boilerplate file as default rights comment in generated codesgo/cmd/operator
, a new binary component for CRD, which will be combined with the autoscaler in the near featureAbout 1st change, I leave a interface for @qizheng09 to implement the job tracker/controller.