Fork me on GitHub

Module autoscaling/v2beta1

@pulumi/kubernetes > autoscaling > v2beta1

Index

types/input.ts types/output.ts

function isCrossVersionObjectReference

isCrossVersionObjectReference(o: any): boolean

function isHorizontalPodAutoscaler

isHorizontalPodAutoscaler(o: any): boolean

function isHorizontalPodAutoscalerList

isHorizontalPodAutoscalerList(o: any): boolean

interface CrossVersionObjectReference

CrossVersionObjectReference contains enough information to let you identify the referred resource.

property apiVersion

apiVersion: string;

API version of the referent

property kind

kind: string;

Kind of the referent; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds”

property name

name: string;

Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names

interface HorizontalPodAutoscaler

HorizontalPodAutoscaler is the configuration for a horizontal pod autoscaler, which automatically manages the replica count of any resource implementing the scale subresource based on the metrics specified.

property apiVersion

apiVersion: string;

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources

property kind

kind: string;

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds

property metadata

metadata: ObjectMeta;

metadata is the standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata

property spec

spec: HorizontalPodAutoscalerSpec;

spec is the specification for the behaviour of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.

property status

status: HorizontalPodAutoscalerStatus;

status is the current information about the autoscaler.

interface HorizontalPodAutoscalerCondition

HorizontalPodAutoscalerCondition describes the state of a HorizontalPodAutoscaler at a certain point.

property lastTransitionTime

lastTransitionTime: string;

lastTransitionTime is the last time the condition transitioned from one status to another

property message

message: string;

message is a human-readable explanation containing details about the transition

property reason

reason: string;

reason is the reason for the condition’s last transition.

property status

status: string;

status is the status of the condition (True, False, Unknown)

property type

type: string;

type describes the current condition

interface HorizontalPodAutoscalerList

HorizontalPodAutoscaler is a list of horizontal pod autoscaler objects.

property apiVersion

apiVersion: string;

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources

property items

items: HorizontalPodAutoscaler[];

items is the list of horizontal pod autoscaler objects.

property kind

kind: string;

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds

property metadata

metadata: ListMeta;

metadata is the standard list metadata.

interface HorizontalPodAutoscalerSpec

HorizontalPodAutoscalerSpec describes the desired functionality of the HorizontalPodAutoscaler.

property maxReplicas

maxReplicas: number;

maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. It cannot be less that minReplicas.

property metrics

metrics: MetricSpec[];

metrics contains the specifications for which to use to calculate the desired replica count (the maximum replica count across all metrics will be used). The desired replica count is calculated multiplying the ratio between the target value and the current value by the current number of pods. Ergo, metrics used must decrease as the pod count is increased, and vice-versa. See the individual metric source types for more information about how each type of metric must respond.

property minReplicas

minReplicas: number;

minReplicas is the lower limit for the number of replicas to which the autoscaler can scale down. It defaults to 1 pod.

property scaleTargetRef

scaleTargetRef: CrossVersionObjectReference;

scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics should be collected, as well as to actually change the replica count.

interface HorizontalPodAutoscalerStatus

HorizontalPodAutoscalerStatus describes the current status of a horizontal pod autoscaler.

property conditions

conditions: HorizontalPodAutoscalerCondition[];

conditions is the set of conditions required for this autoscaler to scale its target, and indicates whether or not those conditions are met.

property currentMetrics

currentMetrics: MetricStatus[];

currentMetrics is the last read state of the metrics used by this autoscaler.

property currentReplicas

currentReplicas: number;

currentReplicas is current number of replicas of pods managed by this autoscaler, as last seen by the autoscaler.

property desiredReplicas

desiredReplicas: number;

desiredReplicas is the desired number of replicas of pods managed by this autoscaler, as last calculated by the autoscaler.

property lastScaleTime

lastScaleTime: string;

lastScaleTime is the last time the HorizontalPodAutoscaler scaled the number of pods, used by the autoscaler to control how often the number of pods is changed.

property observedGeneration

observedGeneration: number;

observedGeneration is the most recent generation observed by this autoscaler.

interface MetricSpec

MetricSpec specifies how to scale based on a single metric (only type and one other matching field should be set at once).

property object

object: ObjectMetricSource;

object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object).

property pods

pods: PodsMetricSource;

pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.

property resource

resource: ResourceMetricSource;

resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the “pods” source.

property type

type: string;

type is the type of metric source. It should match one of the fields below.

interface MetricStatus

MetricStatus describes the last-read state of a single metric.

property object

object: ObjectMetricStatus;

object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object).

property pods

pods: PodsMetricStatus;

pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.

property resource

resource: ResourceMetricStatus;

resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the “pods” source.

property type

type: string;

type is the type of metric source. It will match one of the fields below.

interface ObjectMetricSource

ObjectMetricSource indicates how to scale on a metric describing a kubernetes object (for example, hits-per-second on an Ingress object).

property metricName

metricName: string;

metricName is the name of the metric in question.

property target

target: CrossVersionObjectReference;

target is the described Kubernetes object.

property targetValue

targetValue: string;

targetValue is the target value of the metric (as a quantity).

interface ObjectMetricStatus

ObjectMetricStatus indicates the current value of a metric describing a kubernetes object (for example, hits-per-second on an Ingress object).

property currentValue

currentValue: string;

currentValue is the current value of the metric (as a quantity).

property metricName

metricName: string;

metricName is the name of the metric in question.

property target

target: CrossVersionObjectReference;

target is the described Kubernetes object.

interface PodsMetricSource

PodsMetricSource indicates how to scale on a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.

property metricName

metricName: string;

metricName is the name of the metric in question

property targetAverageValue

targetAverageValue: string;

targetAverageValue is the target value of the average of the metric across all relevant pods (as a quantity)

interface PodsMetricStatus

PodsMetricStatus indicates the current value of a metric describing each pod in the current scale target (for example, transactions-processed-per-second).

property currentAverageValue

currentAverageValue: string;

currentAverageValue is the current value of the average of the metric across all relevant pods (as a quantity)

property metricName

metricName: string;

metricName is the name of the metric in question

interface ResourceMetricSource

ResourceMetricSource indicates how to scale on a resource metric known to Kubernetes, as specified in requests and limits, describing each pod in the current scale target (e.g. CPU or memory). The values will be averaged together before being compared to the target. Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the “pods” source. Only one “target” type should be set.

property name

name: string;

name is the name of the resource in question.

property targetAverageUtilization

targetAverageUtilization: number;

targetAverageUtilization is the target value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods.

property targetAverageValue

targetAverageValue: string;

targetAverageValue is the target value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the “pods” metric source type.

interface ResourceMetricStatus

ResourceMetricStatus indicates the current value of a resource metric known to Kubernetes, as specified in requests and limits, describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the “pods” source.

property currentAverageUtilization

currentAverageUtilization: number;

currentAverageUtilization is the current value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods. It will only be present if targetAverageValue was set in the corresponding metric specification.

property currentAverageValue

currentAverageValue: string;

currentAverageValue is the current value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the “pods” metric source type. It will always be set, regardless of the corresponding metric specification.

property name

name: string;

name is the name of the resource in question.