Documentation ¶
Index ¶
- Variables
- func SetDeploymentScaleAnnotation(deployment *appsv1.Deployment, scaleAnnotation *ScaleAnnotation) error
- func SetScaleAnnotation(annotations map[string]string, scaleAnnotation *ScaleAnnotation) (map[string]string, error)
- type AnnotationScaleManager
- type DeploymentReconciler
- type ScaleAnnotation
- type Step
- type StepState
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func SetDeploymentScaleAnnotation ¶
func SetDeploymentScaleAnnotation(deployment *appsv1.Deployment, scaleAnnotation *ScaleAnnotation) error
func SetScaleAnnotation ¶
Types ¶
type AnnotationScaleManager ¶
type AnnotationScaleManager struct {
// contains filtered or unexported fields
}
func NewAnnotationScaleManager ¶
func NewAnnotationScaleManager(log *logr.Logger, match *metav1.LabelSelector, config *rest.Config, syncPeriod time.Duration) (*AnnotationScaleManager, error)
func (*AnnotationScaleManager) Start ¶
func (m *AnnotationScaleManager) Start() error
func (*AnnotationScaleManager) Stop ¶
func (m *AnnotationScaleManager) Stop()
func (*AnnotationScaleManager) Stopping ¶
func (m *AnnotationScaleManager) Stopping() bool
type DeploymentReconciler ¶
func (*DeploymentReconciler) InjectClient ¶
func (r *DeploymentReconciler) InjectClient(c client.Client) error
type ScaleAnnotation ¶
type ScaleAnnotation struct { Steps []Step `json:"steps,omitempty"` CurrentStepIndex int `json:"current_step_index,omitempty"` CurrentStepState StepState `json:"current_step_state,omitempty"` Message string `json:"message,omitempty"` MaxWaitAvailableSecond int `json:"max_wait_available_second,omitempty"` LastUpdateTime time.Time `json:"last_update_time,omitempty"` }
func NewScaleAnnotation ¶
func NewScaleAnnotation() ScaleAnnotation
func ReadScaleAnnotation ¶
func ReadScaleAnnotation(annotations map[string]string) (*ScaleAnnotation, error)
func (*ScaleAnnotation) StepDeadline ¶
func (sa *ScaleAnnotation) StepDeadline() time.Time
func (*ScaleAnnotation) String ¶
func (sa *ScaleAnnotation) String() string
Click to show internal directories.
Click to hide internal directories.