Documentation ¶
Index ¶
- Variables
- func CreateKubeService(client kubernetes.Interface, namespace string, services ...*corev1.Service) error
- func Replicas(n int) []byte
- func WaitReady(store store.Storer, a *v1.AppService, timeout time.Duration, ...) error
- func WaitStop(store store.Storer, a *v1.AppService, timeout time.Duration, ...) error
- func WaitUpgradeReady(store store.Storer, a *v1.AppService, timeout time.Duration, ...) error
- type Controller
- type Manager
- type TypeController
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrWaitCancel = fmt.Errorf("Wait cancel")
ErrWaitCancel wait cancel
View Source
var ErrWaitTimeOut = fmt.Errorf("Wait time out")
ErrWaitTimeOut wait time out
Functions ¶
func CreateKubeService ¶
func CreateKubeService(client kubernetes.Interface, namespace string, services ...*corev1.Service) error
CreateKubeService create kube service
func WaitReady ¶
func WaitReady(store store.Storer, a *v1.AppService, timeout time.Duration, logger event.Logger, cancel chan struct{}) error
WaitReady wait ready
Types ¶
type Controller ¶
type Controller interface { Begin() Stop() error }
Controller service operating controller interface
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager controller manager
func NewManager ¶
func NewManager(store store.Storer, client kubernetes.Interface, runtimeClient client.Client) *Manager
NewManager new manager
func (*Manager) GetControllerSize ¶
GetControllerSize get running controller number
func (*Manager) StartController ¶
func (m *Manager) StartController(controllerType TypeController, apps ...v1.AppService) error
StartController create and start service controller
type TypeController ¶
type TypeController string
TypeController controller type
var TypeApplyConfigController TypeController = "apply_config"
TypeApplyConfigController -
var TypeApplyRuleController TypeController = "apply_rule"
TypeApplyRuleController -
var TypeControllerRefreshHPA TypeController = "refreshhpa"
TypeControllerRefreshHPA -
var TypeRestartController TypeController = "restart"
TypeRestartController restart service type
var TypeScalingController TypeController = "scaling"
TypeScalingController start service type
var TypeStartController TypeController = "start"
TypeStartController start service type
var TypeStopController TypeController = "stop"
TypeStopController start service type
var TypeUpgradeController TypeController = "upgrade"
TypeUpgradeController start service type
Click to show internal directories.
Click to hide internal directories.