BaseTargetTrackingProps Struct
Base interface for target tracking props.
Contains the attributes that are common to target tracking policies, except the ones relating to the metric and to the scalable target.
This interface is reused by more specific target tracking props objects in other services.
| Source | aws-applicationautoscaling/lib/target-tracking-scaling-policy.ts |
|---|
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as cdk from 'aws-cdk-lib';
import { aws_applicationautoscaling as appscaling } from 'aws-cdk-lib';
const baseTargetTrackingProps: appscaling.BaseTargetTrackingProps = {
disableScaleIn: false,
policyName: 'policyName',
scaleInCooldown: cdk.Duration.minutes(30),
scaleOutCooldown: cdk.Duration.minutes(30),
};
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk as cdk
from aws_cdk import aws_applicationautoscaling as appscaling
base_target_tracking_props = appscaling.BaseTargetTrackingProps(
disable_scale_in=False,
policy_name="policyName",
scale_in_cooldown=cdk.Duration.minutes(30),
scale_out_cooldown=cdk.Duration.minutes(30)
)
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.*;
import software.amazon.awscdk.services.applicationautoscaling.*;
BaseTargetTrackingProps baseTargetTrackingProps = BaseTargetTrackingProps.builder()
.disableScaleIn(false)
.policyName("policyName")
.scaleInCooldown(Duration.minutes(30))
.scaleOutCooldown(Duration.minutes(30))
.build();
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK;
using Amazon.CDK.AWS.ApplicationAutoScaling;
var baseTargetTrackingProps = new BaseTargetTrackingProps {
DisableScaleIn = false,
PolicyName = "policyName",
ScaleInCooldown = Duration.Minutes(30),
ScaleOutCooldown = Duration.Minutes(30)
};
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"
baseTargetTrackingProps := &BaseTargetTrackingProps{
DisableScaleIn: jsii.Boolean(false),
PolicyName: jsii.String("policyName"),
ScaleInCooldown: cdk.Duration_Minutes(jsii.Number(30)),
ScaleOutCooldown: cdk.Duration_*Minutes(jsii.Number(30)),
}
Properties
disableScaleInoptionalbooleandisable_scale_inoptionalbooldisableScaleInoptionalBooleanDisableScaleInoptionalboolDisableScaleInoptional*bool = false #If the value is true, scale in is disabled and the target tracking policy won't remove capacity from the scalable resource. Otherwise, scale in is enabled and the target tracking policy can remove capacity from the scalable resource.
policyNameoptionalstringpolicy_nameoptionalstrpolicyNameoptionalStringPolicyNameoptionalstringPolicyNameoptional*string #Default: Automatically generated name.
scaleInCooldownoptionalDurationscale_in_cooldownoptionalDurationscaleInCooldownoptionalDurationScaleInCooldownoptionalDurationScaleInCooldownoptionalDuration #Default: Duration.seconds(300) for the following scalable targets: ECS services, Spot Fleet requests, EMR clusters, AppStream 2.0 fleets, Aurora DB clusters, Amazon SageMaker endpoint variants, Custom resources. For all other scalable targets, the default value is Duration.seconds(0): DynamoDB tables, DynamoDB global secondary indexes, Amazon Comprehend document classification endpoints, Lambda provisioned concurrency
scaleOutCooldownoptionalDurationscale_out_cooldownoptionalDurationscaleOutCooldownoptionalDurationScaleOutCooldownoptionalDurationScaleOutCooldownoptionalDuration #Default: Duration.seconds(300) for the following scalable targets: ECS services, Spot Fleet requests, EMR clusters, AppStream 2.0 fleets, Aurora DB clusters, Amazon SageMaker endpoint variants, Custom resources. For all other scalable targets, the default value is Duration.seconds(0): DynamoDB tables, DynamoDB global secondary indexes, Amazon Comprehend document classification endpoints, Lambda provisioned concurrency