Documentation ¶
Index ¶
Constants ¶
View Source
const ( // Autoscaling refers to the autoscaling group. Autoscaling = "autoscaling.eventing.knative.dev" // AutoscalingClassAnnotation is the annotation for the explicit class of // scaler that a particular resource has opted into. AutoscalingClassAnnotation = Autoscaling + "/class" // AutoscalingClassDisabledAnnotationValue is the value of the AutoscalingClassAnnotation with // disabled autoscaling. AutoscalingClassDisabledAnnotationValue = "disabled" // AutoscalingMinScaleAnnotation is the annotation to specify the minimum number of replicas to scale down to. AutoscalingMinScaleAnnotation = Autoscaling + "/min-scale" // AutoscalingMaxScaleAnnotation is the annotation to specify the maximum number of replicas to scale out to. AutoscalingMaxScaleAnnotation = Autoscaling + "/max-scale" // AutoscalingPollingIntervalAnnotation is the annotation that refers to the interval in seconds the autoscaler // uses to poll metrics in order to inform its scaling decisions. AutoscalingPollingIntervalAnnotation = Autoscaling + "/polling-interval" // AutoscalingCooldownPeriodAnnotation is the annotation that refers to the period autoscaler waits until it // scales a ConsumerGroup down. AutoscalingCooldownPeriodAnnotation = Autoscaling + "/cooldown-period" // AutoscalingLagThreshold is the annotation that refers to the lag on the current // consumer group that's used for scaling (1<->N) AutoscalingLagThreshold = Autoscaling + "/lag-threshold" // AutoscalingActivationLagThreshold is the annotation that refers to the lag on the // current consumer group that's used for activation (0<->1) AutoscalingActivationLagThreshold = Autoscaling + "/activation-lag-threshold" // DefaultPollingInterval is the default value for AutoscalingPollingIntervalAnnotation. DefaultPollingInterval = 30 // DefaultCooldownPeriod is the default value for AutoscalingCooldownPeriodAnnotation. DefaultCooldownPeriod = 300 // DefaultMinReplicaCount is the default value for AutoscalingMinScaleAnnotation DefaultMinReplicaCount = 0 // DefaultMaxReplicaCount is the default value for AutoscalingMaxScaleAnnotation. DefaultMaxReplicaCount = 50 // DefaultLagThreshold is the default value for AutoscalingLagThreshold. DefaultLagThreshold = 10 // DefaultActivationLagThreshold is the default value for AutoscalingActivationLagThreshold. DefaultActivationLagThreshold = 1 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AutoscalerConfig ¶
type AutoscalerConfig struct { AutoscalerClass map[string]string AutoscalerDefaults map[string]int32 }
AutoscalerConfig contains the defaults defined in the autoscaler ConfigMap.
func NewConfigFromMap ¶
func NewConfigFromMap(data map[string]string) (*AutoscalerConfig, error)
NewConfigFromMap creates a AutoscalerConfig from the supplied map
Click to show internal directories.
Click to hide internal directories.