Documentation ¶
Index ¶
- func IsJobEqual(orig, updated *execution.Job) (bool, error)
- func IsJobStatusEqual(orig, updated *execution.Job) (bool, error)
- func ObserveFirstTaskCreation(rj *execution.Job, task tasks.Task)
- func UpdateJobStatusFromTaskRefs(rj *execution.Job) (*execution.Job, error)
- type Context
- type Controller
- type ExecutionControl
- func (c *ExecutionControl) DeleteJob(ctx context.Context, rj *execution.Job, o metav1.DeleteOptions) error
- func (c *ExecutionControl) UpdateJob(ctx context.Context, rj, newRj *execution.Job) (bool, error)
- func (c *ExecutionControl) UpdateJobStatus(ctx context.Context, rj, newRj *execution.Job) (bool, error)
- type Factory
- type InformerWorker
- type Reconciler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsJobEqual ¶
IsJobEqual returns true if the Job is not equal and should be updated. This equality check is only true in the context of the JobController.
func IsJobStatusEqual ¶
IsJobStatusEqual returns true if the JobStatus is not equal for a Job.
func ObserveFirstTaskCreation ¶
ObserveFirstTaskCreation records a metric for the first task creation time of a Job.
Types ¶
type Context ¶
type Context struct { controllercontext.Context // contains filtered or unexported fields }
Context extends the common controllercontext.Context.
func NewContext ¶
func NewContext(context controllercontext.Context) *Context
NewContext returns a new Context.
func NewContextWithRecorder ¶ added in v0.1.0
func NewContextWithRecorder(context controllercontext.Context, recorder record.EventRecorder) *Context
NewContextWithRecorder returns a new Context with a custom EventRecorder.
func (*Context) GetHasSynced ¶ added in v0.1.0
func (c *Context) GetHasSynced() []cache.InformerSynced
type Controller ¶
type Controller struct { *Context // contains filtered or unexported fields }
Controller is responsible for reconciling Jobs with their downstream task executor states.
func NewController ¶
func NewController( ctrlContext controllercontext.Context, concurrency *configv1alpha1.Concurrency, ) (*Controller, error)
func (*Controller) GetHealth ¶
func (c *Controller) GetHealth() controllermanager.HealthStatus
func (*Controller) Shutdown ¶
func (c *Controller) Shutdown(ctx context.Context)
type ExecutionControl ¶
type ExecutionControl struct {
// contains filtered or unexported fields
}
ExecutionControl is a wrapper around the Execution clientset.
func NewExecutionControl ¶
func NewExecutionControl(client executionv1alpha1.ExecutionV1alpha1Interface, name string) *ExecutionControl
func (*ExecutionControl) DeleteJob ¶
func (c *ExecutionControl) DeleteJob(ctx context.Context, rj *execution.Job, o metav1.DeleteOptions) error
func (*ExecutionControl) UpdateJobStatus ¶
type Factory ¶
type Factory struct{}
func NewFactory ¶
func NewFactory() *Factory
func (*Factory) New ¶
func (f *Factory) New( ctrlContext controllercontext.Context, concurrencySpec *configv1alpha1.ExecutionControllerConcurrencySpec, ) (controllermanager.Controller, error)
type InformerWorker ¶
type InformerWorker struct {
*Context
}
InformerWorker receives events from the informer and enqueues work to be done for the controller.
func NewInformerWorker ¶
func NewInformerWorker(ctrlContext *Context) *InformerWorker
func (*InformerWorker) WorkerName ¶
func (w *InformerWorker) WorkerName() string
type Reconciler ¶
type Reconciler struct { *Context // contains filtered or unexported fields }
func NewReconciler ¶
func NewReconciler(ctrlContext *Context, concurrency *configv1alpha1.Concurrency) *Reconciler
func (*Reconciler) Concurrency ¶
func (w *Reconciler) Concurrency() int
func (*Reconciler) MaxRequeues ¶
func (w *Reconciler) MaxRequeues() int
func (*Reconciler) Name ¶
func (w *Reconciler) Name() string