Skip to main content
Version: 2.6.0

Pod Auto-Scaler Policy

Introduction

This blueprint provides a dashboard and policy which auto-scales the targeted Kubernetes resources based on the results received by executing the provided PromQL queries for scale-in and scale-out.

info

Please see reference for the AutoScale component that is used within this blueprint.

Configuration

Blueprint name: policies/auto-scaling/pod-auto-scaler

Parameters

policy

Parameterpolicy.components
DescriptionList of additional circuit components.
TypeArray of Object (aperture.spec.v1.Component)
Default Value
Expand
[]
Parameterpolicy.dry_run
DescriptionDry run mode ensures that no scaling is invoked by this auto scaler.
TypeBoolean
Default Valuefalse
Parameterpolicy.evaluation_interval
DescriptionThe interval between successive evaluations of the Circuit.
Typestring
Default Value10s
Parameterpolicy.policy_name
DescriptionName of the policy.
Typestring
Default Value__REQUIRED_FIELD__
Parameterpolicy.promql_scale_in_controllers
DescriptionList of scale in controllers.
TypeArray of Object (promql_scale_in_controller)
Default Value
Expand
- alerter: __REQUIRED_FIELD__
gradient: __REQUIRED_FIELD__
query_string: __REQUIRED_FIELD__
setpoint: __REQUIRED_FIELD__
Parameterpolicy.promql_scale_out_controllers
DescriptionList of scale out controllers.
TypeArray of Object (promql_scale_out_controller)
Default Value
Expand
- alerter: __REQUIRED_FIELD__
gradient: __REQUIRED_FIELD__
query_string: __REQUIRED_FIELD__
setpoint: __REQUIRED_FIELD__
Parameterpolicy.resources
DescriptionList of additional resources.
TypeObject (aperture.spec.v1.Resources)
Default Value
Expand
flow_control:
classifiers: []
Parameterpolicy.scaling_backend
DescriptionScaling backend for the policy.
TypeObject (aperture.spec.v1.AutoScalerScalingBackend)
Default Value
Expand
kubernetes_replicas: __REQUIRED_FIELD__
Parameterpolicy.scaling_parameters
DescriptionParameters that define the scaling behavior.
TypeObject (aperture.spec.v1.AutoScalerScalingParameters)
Default Value
Expand
scale_in_alerter:
alert_name: Auto-scaler is scaling in
scale_out_alerter:
alert_name: Auto-scaler is scaling out

dashboard

Parameterdashboard.extra_filters
DescriptionAdditional filters to pass to each query to Grafana datasource.
TypeObject (map[string]string)
Default Value
Expand
{}
Parameterdashboard.refresh_interval
DescriptionRefresh interval for dashboard panels.
Typestring
Default Value5s
Parameterdashboard.time_from
DescriptionTime from of dashboard.
Typestring
Default Valuenow-15m
Parameterdashboard.time_to
DescriptionTime to of dashboard.
Typestring
Default Valuenow
Parameterdashboard.title
DescriptionName of the main dashboard.
Typestring
Default ValueAperture Auto-scale
dashboard.datasource
Parameterdashboard.datasource.filter_regex
DescriptionDatasource filter regex.
Typestring
Default Value
Parameterdashboard.datasource.name
DescriptionDatasource name.
Typestring
Default Value$datasource

Schemas

promql_scale_in_controller

Parameteralerter
DescriptionAlerter parameters for the controller.
TypeObject (aperture.spec.v1.AlerterParameters)
Default Value
Parametergradient
DescriptionGradient parameters for the controller.
TypeObject (aperture.spec.v1.DecreasingGradientParameters)
Default Value
Parameterquery_string
DescriptionThe Prometheus query to be run. Must return a scalar or a vector with a single element.
Typestring
Default Value
Parametersetpoint
DescriptionSetpoint for the controller.
TypeNumber (double)
Default Value

promql_scale_out_controller

Parameteralerter
DescriptionAlerter parameters for the controller.
TypeObject (aperture.spec.v1.AlerterParameters)
Default Value
Parametergradient
DescriptionGradient parameters for the controller.
TypeObject (aperture.spec.v1.IncreasingGradientParameters)
Default Value
Parameterquery_string
DescriptionThe Prometheus query to be run. Must return a scalar or a vector with a single element.
Typestring
Default Value
Parametersetpoint
DescriptionSetpoint for the controller.
TypeNumber (double)
Default Value

Dynamic Configuration

note

The following configuration parameters can be dynamically configured at runtime, without reloading the policy.

Parameters

Parameterdry_run
DescriptionDynamic configuration for setting dry run mode at runtime without restarting this policy. Dry run mode ensures that no scaling is invoked by this auto scaler. This is useful for observing the behavior of auto scaler without disrupting any real deployment.
TypeBoolean
Default Value__REQUIRED_FIELD__