Documentation ¶
Index ¶
- func SetPodEnv(job interface{}, podTemplate *corev1.PodTemplateSpec, index string) error
- type XgboostJobReconciler
- func (r *XgboostJobReconciler) ControllerName() string
- func (r *XgboostJobReconciler) DeleteJob(job interface{}) error
- func (r *XgboostJobReconciler) GetAPIGroupVersion() schema.GroupVersion
- func (r *XgboostJobReconciler) GetAPIGroupVersionKind() schema.GroupVersionKind
- func (r *XgboostJobReconciler) GetDefaultContainerName() string
- func (r *XgboostJobReconciler) GetDefaultContainerPortName() string
- func (r *XgboostJobReconciler) GetDefaultContainerPortNumber() int32
- func (r *XgboostJobReconciler) GetGroupNameLabelValue() string
- func (r *XgboostJobReconciler) GetJobFromAPIClient(namespace, name string) (metav1.Object, error)
- func (r *XgboostJobReconciler) GetJobFromInformerCache(namespace, name string) (metav1.Object, error)
- func (r *XgboostJobReconciler) GetNodeForModelOutput(pods []*corev1.Pod) (nodeName string)
- func (r *XgboostJobReconciler) GetPodsForJob(obj interface{}) ([]*corev1.Pod, error)
- func (r *XgboostJobReconciler) GetReconcileOrders() []v1.ReplicaType
- func (r *XgboostJobReconciler) GetServicesForJob(obj interface{}) ([]*corev1.Service, error)
- func (r *XgboostJobReconciler) IsMasterRole(replicas map[v1.ReplicaType]*v1.ReplicaSpec, rtype v1.ReplicaType, index int) bool
- func (r *XgboostJobReconciler) Reconcile(_ context.Context, req reconcile.Request) (reconcile.Result, error)
- func (r *XgboostJobReconciler) SetClusterSpec(ctx context.Context, job interface{}, podTemplate *corev1.PodTemplateSpec, ...) error
- func (r *XgboostJobReconciler) SetupWithManager(mgr ctrl.Manager) error
- func (r *XgboostJobReconciler) UpdateJobStatus(job interface{}, replicas map[v1.ReplicaType]*v1.ReplicaSpec, ...) error
- func (r *XgboostJobReconciler) UpdateJobStatusInApiServer(job interface{}, jobStatus *v1.JobStatus) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type XgboostJobReconciler ¶
type XgboostJobReconciler struct { client.Client utilruntime.EmptyScaleImpl // contains filtered or unexported fields }
XgboostJobReconciler reconciles a XGBoostJob object
func NewReconciler ¶
func NewReconciler(mgr manager.Manager, config options.JobControllerConfiguration) *XgboostJobReconciler
NewReconciler returns a new reconcile.Reconciler
func (*XgboostJobReconciler) ControllerName ¶
func (r *XgboostJobReconciler) ControllerName() string
func (*XgboostJobReconciler) DeleteJob ¶
func (r *XgboostJobReconciler) DeleteJob(job interface{}) error
DeleteJob deletes the job
func (*XgboostJobReconciler) GetAPIGroupVersion ¶
func (r *XgboostJobReconciler) GetAPIGroupVersion() schema.GroupVersion
func (*XgboostJobReconciler) GetAPIGroupVersionKind ¶
func (r *XgboostJobReconciler) GetAPIGroupVersionKind() schema.GroupVersionKind
func (*XgboostJobReconciler) GetDefaultContainerName ¶
func (r *XgboostJobReconciler) GetDefaultContainerName() string
func (*XgboostJobReconciler) GetDefaultContainerPortName ¶
func (r *XgboostJobReconciler) GetDefaultContainerPortName() string
func (*XgboostJobReconciler) GetDefaultContainerPortNumber ¶
func (r *XgboostJobReconciler) GetDefaultContainerPortNumber() int32
func (*XgboostJobReconciler) GetGroupNameLabelValue ¶
func (r *XgboostJobReconciler) GetGroupNameLabelValue() string
func (*XgboostJobReconciler) GetJobFromAPIClient ¶
func (r *XgboostJobReconciler) GetJobFromAPIClient(namespace, name string) (metav1.Object, error)
GetJobFromAPIClient returns the Job from API server
func (*XgboostJobReconciler) GetJobFromInformerCache ¶
func (r *XgboostJobReconciler) GetJobFromInformerCache(namespace, name string) (metav1.Object, error)
GetJobFromInformerCache returns the Job from Informer Cache
func (*XgboostJobReconciler) GetNodeForModelOutput ¶ added in v0.4.0
func (r *XgboostJobReconciler) GetNodeForModelOutput(pods []*corev1.Pod) (nodeName string)
func (*XgboostJobReconciler) GetPodsForJob ¶
func (r *XgboostJobReconciler) GetPodsForJob(obj interface{}) ([]*corev1.Pod, error)
GetPodsForJob returns the pods managed by the job. This can be achieved by selecting pods using label key "job-name" i.e. all pods created by the job will come with label "job-name" = <this_job_name>
func (*XgboostJobReconciler) GetReconcileOrders ¶
func (r *XgboostJobReconciler) GetReconcileOrders() []v1.ReplicaType
func (*XgboostJobReconciler) GetServicesForJob ¶
func (r *XgboostJobReconciler) GetServicesForJob(obj interface{}) ([]*corev1.Service, error)
GetServicesForJob returns the services managed by the job. This can be achieved by selecting services using label key "job-name" i.e. all services created by the job will come with label "job-name" = <this_job_name>
func (*XgboostJobReconciler) IsMasterRole ¶
func (r *XgboostJobReconciler) IsMasterRole(replicas map[v1.ReplicaType]*v1.ReplicaSpec, rtype v1.ReplicaType, index int) bool
func (*XgboostJobReconciler) SetClusterSpec ¶
func (r *XgboostJobReconciler) SetClusterSpec(ctx context.Context, job interface{}, podTemplate *corev1.PodTemplateSpec, rtype, index string) error
SetClusterSpec sets the cluster spec for the pod
func (*XgboostJobReconciler) SetupWithManager ¶
func (r *XgboostJobReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager setup reconciler to the Manager with default RBAC. The Manager will set fields on the Controller and Start it when the Manager is Started.
func (*XgboostJobReconciler) UpdateJobStatus ¶
func (r *XgboostJobReconciler) UpdateJobStatus(job interface{}, replicas map[v1.ReplicaType]*v1.ReplicaSpec, jobStatus *v1.JobStatus, restart bool) error
UpdateJobStatus updates the job status and job conditions
func (*XgboostJobReconciler) UpdateJobStatusInApiServer ¶
func (r *XgboostJobReconciler) UpdateJobStatusInApiServer(job interface{}, jobStatus *v1.JobStatus) error
UpdateJobStatusInApiServer updates the job status in to cluster.