Documentation ¶
Index ¶
- func ContainMasterSpec(job *v1alpha1.ElasticDLJob) bool
- type ElasticDLJobReconciler
- func (r *ElasticDLJobReconciler) ControllerName() string
- func (r *ElasticDLJobReconciler) CreatePod(job interface{}, pod *corev1.Pod) error
- func (r *ElasticDLJobReconciler) CreateService(job interface{}, service *corev1.Service) error
- func (r *ElasticDLJobReconciler) DeleteJob(job interface{}) error
- func (r *ElasticDLJobReconciler) DeletePod(job interface{}, pod *corev1.Pod) error
- func (r *ElasticDLJobReconciler) DeleteService(job interface{}, name string, namespace string) error
- func (r *ElasticDLJobReconciler) GetAPIGroupVersion() schema.GroupVersion
- func (r *ElasticDLJobReconciler) GetAPIGroupVersionKind() schema.GroupVersionKind
- func (r *ElasticDLJobReconciler) GetDefaultContainerName() string
- func (r *ElasticDLJobReconciler) GetDefaultContainerPortName() string
- func (r *ElasticDLJobReconciler) GetDefaultContainerPortNumber() int32
- func (r *ElasticDLJobReconciler) GetGroupNameLabelValue() string
- func (r *ElasticDLJobReconciler) GetJobFromAPIClient(namespace, name string) (metav1.Object, error)
- func (r *ElasticDLJobReconciler) GetJobFromInformerCache(namespace, name string) (metav1.Object, error)
- func (r *ElasticDLJobReconciler) GetPodsForJob(obj interface{}) ([]*corev1.Pod, error)
- func (r *ElasticDLJobReconciler) GetReconcileOrders() []v1.ReplicaType
- func (r *ElasticDLJobReconciler) GetServicesForJob(obj interface{}) ([]*corev1.Service, error)
- func (r *ElasticDLJobReconciler) IsMasterRole(replicas map[v1.ReplicaType]*v1.ReplicaSpec, rtype v1.ReplicaType, index int) bool
- func (r *ElasticDLJobReconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)
- func (r *ElasticDLJobReconciler) SetClusterSpec(job interface{}, podTemplate *corev1.PodTemplateSpec, rtype, index string) error
- func (r *ElasticDLJobReconciler) SetupWithManager(mgr ctrl.Manager) error
- func (r *ElasticDLJobReconciler) UpdateJobStatus(job interface{}, replicas map[v1.ReplicaType]*v1.ReplicaSpec, ...) error
- func (r *ElasticDLJobReconciler) UpdateJobStatusInApiServer(job interface{}, jobStatus *v1.JobStatus) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContainMasterSpec ¶
func ContainMasterSpec(job *v1alpha1.ElasticDLJob) bool
Types ¶
type ElasticDLJobReconciler ¶
ElasticDLJobReconciler reconcile a ElastiDLJob object
func NewReconciler ¶
func NewReconciler(mgr ctrl.Manager, config job_controller.JobControllerConfiguration) *ElasticDLJobReconciler
func (*ElasticDLJobReconciler) ControllerName ¶
func (r *ElasticDLJobReconciler) ControllerName() string
func (*ElasticDLJobReconciler) CreatePod ¶
func (r *ElasticDLJobReconciler) CreatePod(job interface{}, pod *corev1.Pod) error
CreatePod creates the pod
func (*ElasticDLJobReconciler) CreateService ¶
func (r *ElasticDLJobReconciler) CreateService(job interface{}, service *corev1.Service) error
CreateService creates the service
func (*ElasticDLJobReconciler) DeleteJob ¶
func (r *ElasticDLJobReconciler) DeleteJob(job interface{}) error
DeleteJob deletes the job
func (*ElasticDLJobReconciler) DeletePod ¶
func (r *ElasticDLJobReconciler) DeletePod(job interface{}, pod *corev1.Pod) error
DeletePod deletes the pod
func (*ElasticDLJobReconciler) DeleteService ¶
func (r *ElasticDLJobReconciler) DeleteService(job interface{}, name string, namespace string) error
DeleteService deletes the service
func (*ElasticDLJobReconciler) GetAPIGroupVersion ¶
func (r *ElasticDLJobReconciler) GetAPIGroupVersion() schema.GroupVersion
GetAPIGroupVersion returns the GroupVersion of the API
func (*ElasticDLJobReconciler) GetAPIGroupVersionKind ¶
func (r *ElasticDLJobReconciler) GetAPIGroupVersionKind() schema.GroupVersionKind
GetAPIGroupVersionKind returns the GroupVersionKind of the API
func (*ElasticDLJobReconciler) GetDefaultContainerName ¶
func (r *ElasticDLJobReconciler) GetDefaultContainerName() string
GetDefaultContainerName returns the default container name in pod
func (*ElasticDLJobReconciler) GetDefaultContainerPortName ¶
func (r *ElasticDLJobReconciler) GetDefaultContainerPortName() string
GetDefaultContainerPortName Get the default container port name
func (*ElasticDLJobReconciler) GetDefaultContainerPortNumber ¶
func (r *ElasticDLJobReconciler) GetDefaultContainerPortNumber() int32
GetDefaultContainerPortNumber get the default container port number
func (*ElasticDLJobReconciler) GetGroupNameLabelValue ¶
func (r *ElasticDLJobReconciler) GetGroupNameLabelValue() string
GetGroupNameLabelValue returns the Group Name(value) in the labels of the job
func (*ElasticDLJobReconciler) GetJobFromAPIClient ¶
func (r *ElasticDLJobReconciler) GetJobFromAPIClient(namespace, name string) (metav1.Object, error)
GetJobFromAPIClient returns the Job from API server
func (*ElasticDLJobReconciler) GetJobFromInformerCache ¶
func (r *ElasticDLJobReconciler) GetJobFromInformerCache(namespace, name string) (metav1.Object, error)
GetJobFromInformerCache returns the Job from Informer Cache
func (*ElasticDLJobReconciler) GetPodsForJob ¶
func (r *ElasticDLJobReconciler) 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 (*ElasticDLJobReconciler) GetReconcileOrders ¶
func (r *ElasticDLJobReconciler) GetReconcileOrders() []v1.ReplicaType
func (*ElasticDLJobReconciler) GetServicesForJob ¶
func (r *ElasticDLJobReconciler) 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 (*ElasticDLJobReconciler) IsMasterRole ¶
func (r *ElasticDLJobReconciler) IsMasterRole(replicas map[v1.ReplicaType]*v1.ReplicaSpec, rtype v1.ReplicaType, index int) bool
func (*ElasticDLJobReconciler) SetClusterSpec ¶
func (r *ElasticDLJobReconciler) SetClusterSpec(job interface{}, podTemplate *corev1.PodTemplateSpec, rtype, index string) error
SetClusterSpec sets the cluster spec for the pod
func (*ElasticDLJobReconciler) SetupWithManager ¶
func (r *ElasticDLJobReconciler) SetupWithManager(mgr ctrl.Manager) error
func (*ElasticDLJobReconciler) UpdateJobStatus ¶
func (r *ElasticDLJobReconciler) UpdateJobStatus(job interface{}, replicas map[v1.ReplicaType]*v1.ReplicaSpec, jobStatus *v1.JobStatus, restart bool) error
UpdateJobStatus updates the job status and job conditions
func (*ElasticDLJobReconciler) UpdateJobStatusInApiServer ¶
func (r *ElasticDLJobReconciler) UpdateJobStatusInApiServer(job interface{}, jobStatus *v1.JobStatus) error
UpdateJobStatusInApiServer updates the job status in API server