Documentation ¶
Index ¶
Constants ¶
View Source
const ( Webhook = "Webhook" Event = "Event" Cron = "Cron" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CronScaler ¶
type CronScaler struct {
// contains filtered or unexported fields
}
CronScaler is a crontab GPA
func (*CronScaler) GetReplicas ¶
func (s *CronScaler) GetReplicas(gpa *v1alpha1.GeneralPodAutoscaler, currentReplicas int32) (int32, error)
GetReplicas return replicas recommend by crontab GPA
func (*CronScaler) ScalerName ¶
func (s *CronScaler) ScalerName() string
ScalerName returns scaler name
type EventScaler ¶
type EventScaler struct {
// contains filtered or unexported fields
}
func (*EventScaler) GetReplicas ¶
func (e *EventScaler) GetReplicas(*autoscalingv1.GeneralPodAutoscaler, int32) (int32, error)
func (*EventScaler) Run ¶
func (e *EventScaler) Run(stopCh <-chan struct{}) error
func (*EventScaler) ScalerName ¶
func (s *EventScaler) ScalerName() string
type LongRunScaler ¶
type Scaler ¶
type Scaler interface { GetReplicas(*autoscalingv1.GeneralPodAutoscaler, int32) (int32, error) ScalerName() string }
func NewCronScaler ¶
NewCronScaler initializer crontab GPA
func NewEventScaler ¶
func NewWebhookScaler ¶
func NewWebhookScaler(modeConfig *autoscalingv1.WebhookMode) Scaler
type ScalerName ¶
type ScalerName string
type WebhookScaler ¶
type WebhookScaler struct {
// contains filtered or unexported fields
}
func (*WebhookScaler) GetReplicas ¶
func (s *WebhookScaler) GetReplicas(gpa *autoscalingv1.GeneralPodAutoscaler, currentReplicas int32) (int32, error)
func (*WebhookScaler) ScalerName ¶
func (s *WebhookScaler) ScalerName() string
Click to show internal directories.
Click to hide internal directories.