Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ForeachController ¶
func ForeachController(fn func(controller Controller))
ForeachController is helper function to operator all controllers.
func RegisterController ¶
func RegisterController(ctrl Controller) error
RegisterController register controller to the controller manager.
Types ¶
type Controller ¶
type Controller interface {
Name() string
Initialize(opt *ControllerOption) error
// Run run the controller
Run(stopCh <-chan struct{})
}
Controller is the interface of all controllers.
type ControllerOption ¶
type ControllerOption struct {
KubeClient kubernetes.Interface
VolcanoClient vcclientset.Interface
SchedulerNames []string
WorkerNum uint32
CronJobWorkerNum uint32
MaxRequeueNum int
InheritOwnerAnnotations bool
WorkerThreadsForPG uint32
WorkerThreadsForQueue uint32
WorkerThreadsForGC uint32
// Config holds the common attributes that can be passed to a Kubernetes client
// and controllers registered by the users can use it.
Config *rest.Config
}
ControllerOption is the main context object for the controllers.
Click to show internal directories.
Click to hide internal directories.