aws logo
AWS Classic v5.41.0, May 15 23

aws.autoscaling.Policy

Explore with Pulumi AI

Provides an AutoScaling Scaling Policy resource.

NOTE: You may want to omit desired_capacity attribute from attached aws.autoscaling.Group when using autoscaling policies. It’s good practice to pick either manual or dynamic (policy-based) scaling.

Example Usage

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() => 
{
    var bar = new Aws.AutoScaling.Group("bar", new()
    {
        AvailabilityZones = new[]
        {
            "us-east-1a",
        },
        MaxSize = 5,
        MinSize = 2,
        HealthCheckGracePeriod = 300,
        HealthCheckType = "ELB",
        ForceDelete = true,
        LaunchConfiguration = aws_launch_configuration.Foo.Name,
    });

    var bat = new Aws.AutoScaling.Policy("bat", new()
    {
        ScalingAdjustment = 4,
        AdjustmentType = "ChangeInCapacity",
        Cooldown = 300,
        AutoscalingGroupName = bar.Name,
    });

});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/autoscaling"
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ec2"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		bar, err := autoscaling.NewGroup(ctx, "bar", &autoscaling.GroupArgs{
			AvailabilityZones: pulumi.StringArray{
				pulumi.String("us-east-1a"),
			},
			MaxSize:                pulumi.Int(5),
			MinSize:                pulumi.Int(2),
			HealthCheckGracePeriod: pulumi.Int(300),
			HealthCheckType:        pulumi.String("ELB"),
			ForceDelete:            pulumi.Bool(true),
			LaunchConfiguration:    pulumi.Any(aws_launch_configuration.Foo.Name),
		})
		if err != nil {
			return err
		}
		_, err = autoscaling.NewPolicy(ctx, "bat", &autoscaling.PolicyArgs{
			ScalingAdjustment:    pulumi.Int(4),
			AdjustmentType:       pulumi.String("ChangeInCapacity"),
			Cooldown:             pulumi.Int(300),
			AutoscalingGroupName: bar.Name,
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.autoscaling.Group;
import com.pulumi.aws.autoscaling.GroupArgs;
import com.pulumi.aws.autoscaling.Policy;
import com.pulumi.aws.autoscaling.PolicyArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var bar = new Group("bar", GroupArgs.builder()        
            .availabilityZones("us-east-1a")
            .maxSize(5)
            .minSize(2)
            .healthCheckGracePeriod(300)
            .healthCheckType("ELB")
            .forceDelete(true)
            .launchConfiguration(aws_launch_configuration.foo().name())
            .build());

        var bat = new Policy("bat", PolicyArgs.builder()        
            .scalingAdjustment(4)
            .adjustmentType("ChangeInCapacity")
            .cooldown(300)
            .autoscalingGroupName(bar.name())
            .build());

    }
}
import pulumi
import pulumi_aws as aws

bar = aws.autoscaling.Group("bar",
    availability_zones=["us-east-1a"],
    max_size=5,
    min_size=2,
    health_check_grace_period=300,
    health_check_type="ELB",
    force_delete=True,
    launch_configuration=aws_launch_configuration["foo"]["name"])
bat = aws.autoscaling.Policy("bat",
    scaling_adjustment=4,
    adjustment_type="ChangeInCapacity",
    cooldown=300,
    autoscaling_group_name=bar.name)
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const bar = new aws.autoscaling.Group("bar", {
    availabilityZones: ["us-east-1a"],
    maxSize: 5,
    minSize: 2,
    healthCheckGracePeriod: 300,
    healthCheckType: "ELB",
    forceDelete: true,
    launchConfiguration: aws_launch_configuration.foo.name,
});
const bat = new aws.autoscaling.Policy("bat", {
    scalingAdjustment: 4,
    adjustmentType: "ChangeInCapacity",
    cooldown: 300,
    autoscalingGroupName: bar.name,
});
resources:
  bat:
    type: aws:autoscaling:Policy
    properties:
      scalingAdjustment: 4
      adjustmentType: ChangeInCapacity
      cooldown: 300
      autoscalingGroupName: ${bar.name}
  bar:
    type: aws:autoscaling:Group
    properties:
      availabilityZones:
        - us-east-1a
      maxSize: 5
      minSize: 2
      healthCheckGracePeriod: 300
      healthCheckType: ELB
      forceDelete: true
      launchConfiguration: ${aws_launch_configuration.foo.name}

Create target tarcking scaling policy using metric math

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() => 
{
    var example = new Aws.AutoScaling.Policy("example", new()
    {
        AutoscalingGroupName = "my-test-asg",
        PolicyType = "TargetTrackingScaling",
        TargetTrackingConfiguration = new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationArgs
        {
            CustomizedMetricSpecification = new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationArgs
            {
                Metrics = new[]
                {
                    new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs
                    {
                        Id = "m1",
                        Label = "Get the queue size (the number of messages waiting to be processed)",
                        MetricStat = new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatArgs
                        {
                            Metric = new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricArgs
                            {
                                Dimensions = new[]
                                {
                                    new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArgs
                                    {
                                        Name = "QueueName",
                                        Value = "my-queue",
                                    },
                                },
                                MetricName = "ApproximateNumberOfMessagesVisible",
                                Namespace = "AWS/SQS",
                            },
                            Stat = "Sum",
                        },
                        ReturnData = false,
                    },
                    new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs
                    {
                        Id = "m2",
                        Label = "Get the group size (the number of InService instances)",
                        MetricStat = new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatArgs
                        {
                            Metric = new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricArgs
                            {
                                Dimensions = new[]
                                {
                                    new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArgs
                                    {
                                        Name = "AutoScalingGroupName",
                                        Value = "my-asg",
                                    },
                                },
                                MetricName = "GroupInServiceInstances",
                                Namespace = "AWS/AutoScaling",
                            },
                            Stat = "Average",
                        },
                        ReturnData = false,
                    },
                    new Aws.AutoScaling.Inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs
                    {
                        Expression = "m1 / m2",
                        Id = "e1",
                        Label = "Calculate the backlog per instance",
                        ReturnData = true,
                    },
                },
            },
            TargetValue = 100,
        },
    });

});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/autoscaling"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := autoscaling.NewPolicy(ctx, "example", &autoscaling.PolicyArgs{
			AutoscalingGroupName: pulumi.String("my-test-asg"),
			PolicyType:           pulumi.String("TargetTrackingScaling"),
			TargetTrackingConfiguration: &autoscaling.PolicyTargetTrackingConfigurationArgs{
				CustomizedMetricSpecification: &autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationArgs{
					Metrics: autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArray{
						&autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs{
							Id:    pulumi.String("m1"),
							Label: pulumi.String("Get the queue size (the number of messages waiting to be processed)"),
							MetricStat: &autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatArgs{
								Metric: &autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricArgs{
									Dimensions: autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArray{
										&autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArgs{
											Name:  pulumi.String("QueueName"),
											Value: pulumi.String("my-queue"),
										},
									},
									MetricName: pulumi.String("ApproximateNumberOfMessagesVisible"),
									Namespace:  pulumi.String("AWS/SQS"),
								},
								Stat: pulumi.String("Sum"),
							},
							ReturnData: pulumi.Bool(false),
						},
						&autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs{
							Id:    pulumi.String("m2"),
							Label: pulumi.String("Get the group size (the number of InService instances)"),
							MetricStat: &autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatArgs{
								Metric: &autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricArgs{
									Dimensions: autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArray{
										&autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArgs{
											Name:  pulumi.String("AutoScalingGroupName"),
											Value: pulumi.String("my-asg"),
										},
									},
									MetricName: pulumi.String("GroupInServiceInstances"),
									Namespace:  pulumi.String("AWS/AutoScaling"),
								},
								Stat: pulumi.String("Average"),
							},
							ReturnData: pulumi.Bool(false),
						},
						&autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs{
							Expression: pulumi.String("m1 / m2"),
							Id:         pulumi.String("e1"),
							Label:      pulumi.String("Calculate the backlog per instance"),
							ReturnData: pulumi.Bool(true),
						},
					},
				},
				TargetValue: pulumi.Float64(100),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.autoscaling.Policy;
import com.pulumi.aws.autoscaling.PolicyArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyTargetTrackingConfigurationArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new Policy("example", PolicyArgs.builder()        
            .autoscalingGroupName("my-test-asg")
            .policyType("TargetTrackingScaling")
            .targetTrackingConfiguration(PolicyTargetTrackingConfigurationArgs.builder()
                .customizedMetricSpecification(PolicyTargetTrackingConfigurationCustomizedMetricSpecificationArgs.builder()
                    .metrics(                    
                        PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs.builder()
                            .id("m1")
                            .label("Get the queue size (the number of messages waiting to be processed)")
                            .metricStat(PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatArgs.builder()
                                .metric(PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricArgs.builder()
                                    .dimensions(PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArgs.builder()
                                        .name("QueueName")
                                        .value("my-queue")
                                        .build())
                                    .metricName("ApproximateNumberOfMessagesVisible")
                                    .namespace("AWS/SQS")
                                    .build())
                                .stat("Sum")
                                .build())
                            .returnData(false)
                            .build(),
                        PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs.builder()
                            .id("m2")
                            .label("Get the group size (the number of InService instances)")
                            .metricStat(PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatArgs.builder()
                                .metric(PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricArgs.builder()
                                    .dimensions(PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArgs.builder()
                                        .name("AutoScalingGroupName")
                                        .value("my-asg")
                                        .build())
                                    .metricName("GroupInServiceInstances")
                                    .namespace("AWS/AutoScaling")
                                    .build())
                                .stat("Average")
                                .build())
                            .returnData(false)
                            .build(),
                        PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs.builder()
                            .expression("m1 / m2")
                            .id("e1")
                            .label("Calculate the backlog per instance")
                            .returnData(true)
                            .build())
                    .build())
                .targetValue(100)
                .build())
            .build());

    }
}
import pulumi
import pulumi_aws as aws

example = aws.autoscaling.Policy("example",
    autoscaling_group_name="my-test-asg",
    policy_type="TargetTrackingScaling",
    target_tracking_configuration=aws.autoscaling.PolicyTargetTrackingConfigurationArgs(
        customized_metric_specification=aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationArgs(
            metrics=[
                aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs(
                    id="m1",
                    label="Get the queue size (the number of messages waiting to be processed)",
                    metric_stat=aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatArgs(
                        metric=aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricArgs(
                            dimensions=[aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArgs(
                                name="QueueName",
                                value="my-queue",
                            )],
                            metric_name="ApproximateNumberOfMessagesVisible",
                            namespace="AWS/SQS",
                        ),
                        stat="Sum",
                    ),
                    return_data=False,
                ),
                aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs(
                    id="m2",
                    label="Get the group size (the number of InService instances)",
                    metric_stat=aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatArgs(
                        metric=aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricArgs(
                            dimensions=[aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimensionArgs(
                                name="AutoScalingGroupName",
                                value="my-asg",
                            )],
                            metric_name="GroupInServiceInstances",
                            namespace="AWS/AutoScaling",
                        ),
                        stat="Average",
                    ),
                    return_data=False,
                ),
                aws.autoscaling.PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricArgs(
                    expression="m1 / m2",
                    id="e1",
                    label="Calculate the backlog per instance",
                    return_data=True,
                ),
            ],
        ),
        target_value=100,
    ))
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.autoscaling.Policy("example", {
    autoscalingGroupName: "my-test-asg",
    policyType: "TargetTrackingScaling",
    targetTrackingConfiguration: {
        customizedMetricSpecification: {
            metrics: [
                {
                    id: "m1",
                    label: "Get the queue size (the number of messages waiting to be processed)",
                    metricStat: {
                        metric: {
                            dimensions: [{
                                name: "QueueName",
                                value: "my-queue",
                            }],
                            metricName: "ApproximateNumberOfMessagesVisible",
                            namespace: "AWS/SQS",
                        },
                        stat: "Sum",
                    },
                    returnData: false,
                },
                {
                    id: "m2",
                    label: "Get the group size (the number of InService instances)",
                    metricStat: {
                        metric: {
                            dimensions: [{
                                name: "AutoScalingGroupName",
                                value: "my-asg",
                            }],
                            metricName: "GroupInServiceInstances",
                            namespace: "AWS/AutoScaling",
                        },
                        stat: "Average",
                    },
                    returnData: false,
                },
                {
                    expression: "m1 / m2",
                    id: "e1",
                    label: "Calculate the backlog per instance",
                    returnData: true,
                },
            ],
        },
        targetValue: 100,
    },
});
resources:
  example:
    type: aws:autoscaling:Policy
    properties:
      autoscalingGroupName: my-test-asg
      policyType: TargetTrackingScaling
      targetTrackingConfiguration:
        customizedMetricSpecification:
          metrics:
            - id: m1
              label: Get the queue size (the number of messages waiting to be processed)
              metricStat:
                metric:
                  dimensions:
                    - name: QueueName
                      value: my-queue
                  metricName: ApproximateNumberOfMessagesVisible
                  namespace: AWS/SQS
                stat: Sum
              returnData: false
            - id: m2
              label: Get the group size (the number of InService instances)
              metricStat:
                metric:
                  dimensions:
                    - name: AutoScalingGroupName
                      value: my-asg
                  metricName: GroupInServiceInstances
                  namespace: AWS/AutoScaling
                stat: Average
              returnData: false
            - expression: m1 / m2
              id: e1
              label: Calculate the backlog per instance
              returnData: true
        targetValue: 100

Create predictive scaling policy using customized metrics

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() => 
{
    var example = new Aws.AutoScaling.Policy("example", new()
    {
        AutoscalingGroupName = "my-test-asg",
        PolicyType = "PredictiveScaling",
        PredictiveScalingConfiguration = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationArgs
        {
            MetricSpecification = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationArgs
            {
                CustomizedCapacityMetricSpecification = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationArgs
                {
                    MetricDataQueries = new[]
                    {
                        new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryArgs
                        {
                            Expression = "SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))",
                            Id = "capacity_sum",
                        },
                    },
                },
                CustomizedLoadMetricSpecification = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationArgs
                {
                    MetricDataQueries = new[]
                    {
                        new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryArgs
                        {
                            Expression = "SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 3600))",
                            Id = "load_sum",
                        },
                    },
                },
                CustomizedScalingMetricSpecification = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs
                {
                    MetricDataQueries = new[]
                    {
                        new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs
                        {
                            Expression = "SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))",
                            Id = "capacity_sum",
                            ReturnData = false,
                        },
                        new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs
                        {
                            Expression = "SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 300))",
                            Id = "load_sum",
                            ReturnData = false,
                        },
                        new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs
                        {
                            Expression = "load_sum / (capacity_sum * PERIOD(capacity_sum) / 60)",
                            Id = "weighted_average",
                        },
                    },
                },
                TargetValue = 10,
            },
        },
    });

});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/autoscaling"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := autoscaling.NewPolicy(ctx, "example", &autoscaling.PolicyArgs{
			AutoscalingGroupName: pulumi.String("my-test-asg"),
			PolicyType:           pulumi.String("PredictiveScaling"),
			PredictiveScalingConfiguration: &autoscaling.PolicyPredictiveScalingConfigurationArgs{
				MetricSpecification: &autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationArgs{
					CustomizedCapacityMetricSpecification: &autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationArgs{
						MetricDataQueries: autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryArray{
							&autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryArgs{
								Expression: pulumi.String("SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))"),
								Id:         pulumi.String("capacity_sum"),
							},
						},
					},
					CustomizedLoadMetricSpecification: &autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationArgs{
						MetricDataQueries: autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryArray{
							&autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryArgs{
								Expression: pulumi.String("SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 3600))"),
								Id:         pulumi.String("load_sum"),
							},
						},
					},
					CustomizedScalingMetricSpecification: &autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs{
						MetricDataQueries: autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArray{
							&autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs{
								Expression: pulumi.String("SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))"),
								Id:         pulumi.String("capacity_sum"),
								ReturnData: pulumi.Bool(false),
							},
							&autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs{
								Expression: pulumi.String("SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 300))"),
								Id:         pulumi.String("load_sum"),
								ReturnData: pulumi.Bool(false),
							},
							&autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs{
								Expression: pulumi.String("load_sum / (capacity_sum * PERIOD(capacity_sum) / 60)"),
								Id:         pulumi.String("weighted_average"),
							},
						},
					},
					TargetValue: pulumi.Float64(10),
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.autoscaling.Policy;
import com.pulumi.aws.autoscaling.PolicyArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyPredictiveScalingConfigurationArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyPredictiveScalingConfigurationMetricSpecificationArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new Policy("example", PolicyArgs.builder()        
            .autoscalingGroupName("my-test-asg")
            .policyType("PredictiveScaling")
            .predictiveScalingConfiguration(PolicyPredictiveScalingConfigurationArgs.builder()
                .metricSpecification(PolicyPredictiveScalingConfigurationMetricSpecificationArgs.builder()
                    .customizedCapacityMetricSpecification(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationArgs.builder()
                        .metricDataQueries(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryArgs.builder()
                            .expression("SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))")
                            .id("capacity_sum")
                            .build())
                        .build())
                    .customizedLoadMetricSpecification(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationArgs.builder()
                        .metricDataQueries(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryArgs.builder()
                            .expression("SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 3600))")
                            .id("load_sum")
                            .build())
                        .build())
                    .customizedScalingMetricSpecification(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs.builder()
                        .metricDataQueries(                        
                            PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs.builder()
                                .expression("SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))")
                                .id("capacity_sum")
                                .returnData(false)
                                .build(),
                            PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs.builder()
                                .expression("SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 300))")
                                .id("load_sum")
                                .returnData(false)
                                .build(),
                            PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs.builder()
                                .expression("load_sum / (capacity_sum * PERIOD(capacity_sum) / 60)")
                                .id("weighted_average")
                                .build())
                        .build())
                    .targetValue(10)
                    .build())
                .build())
            .build());

    }
}
import pulumi
import pulumi_aws as aws

example = aws.autoscaling.Policy("example",
    autoscaling_group_name="my-test-asg",
    policy_type="PredictiveScaling",
    predictive_scaling_configuration=aws.autoscaling.PolicyPredictiveScalingConfigurationArgs(
        metric_specification=aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationArgs(
            customized_capacity_metric_specification=aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationArgs(
                metric_data_queries=[aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryArgs(
                    expression="SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))",
                    id="capacity_sum",
                )],
            ),
            customized_load_metric_specification=aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationArgs(
                metric_data_queries=[aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryArgs(
                    expression="SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 3600))",
                    id="load_sum",
                )],
            ),
            customized_scaling_metric_specification=aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs(
                metric_data_queries=[
                    aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs(
                        expression="SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))",
                        id="capacity_sum",
                        return_data=False,
                    ),
                    aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs(
                        expression="SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 300))",
                        id="load_sum",
                        return_data=False,
                    ),
                    aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs(
                        expression="load_sum / (capacity_sum * PERIOD(capacity_sum) / 60)",
                        id="weighted_average",
                    ),
                ],
            ),
            target_value=10,
        ),
    ))
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.autoscaling.Policy("example", {
    autoscalingGroupName: "my-test-asg",
    policyType: "PredictiveScaling",
    predictiveScalingConfiguration: {
        metricSpecification: {
            customizedCapacityMetricSpecification: {
                metricDataQueries: [{
                    expression: "SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))",
                    id: "capacity_sum",
                }],
            },
            customizedLoadMetricSpecification: {
                metricDataQueries: [{
                    expression: "SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 3600))",
                    id: "load_sum",
                }],
            },
            customizedScalingMetricSpecification: {
                metricDataQueries: [
                    {
                        expression: "SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName=\"GroupInServiceIntances\" my-test-asg', 'Average', 300))",
                        id: "capacity_sum",
                        returnData: false,
                    },
                    {
                        expression: "SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName=\"CPUUtilization\" my-test-asg', 'Sum', 300))",
                        id: "load_sum",
                        returnData: false,
                    },
                    {
                        expression: "load_sum / (capacity_sum * PERIOD(capacity_sum) / 60)",
                        id: "weighted_average",
                    },
                ],
            },
            targetValue: 10,
        },
    },
});
resources:
  example:
    type: aws:autoscaling:Policy
    properties:
      autoscalingGroupName: my-test-asg
      policyType: PredictiveScaling
      predictiveScalingConfiguration:
        metricSpecification:
          customizedCapacityMetricSpecification:
            metricDataQueries:
              - expression: SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName="GroupInServiceIntances" my-test-asg', 'Average', 300))
                id: capacity_sum
          customizedLoadMetricSpecification:
            metricDataQueries:
              - expression: SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName="CPUUtilization" my-test-asg', 'Sum', 3600))
                id: load_sum
          customizedScalingMetricSpecification:
            metricDataQueries:
              - expression: SUM(SEARCH('{AWS/AutoScaling,AutoScalingGroupName} MetricName="GroupInServiceIntances" my-test-asg', 'Average', 300))
                id: capacity_sum
                returnData: false
              - expression: SUM(SEARCH('{AWS/EC2,AutoScalingGroupName} MetricName="CPUUtilization" my-test-asg', 'Sum', 300))
                id: load_sum
                returnData: false
              - expression: load_sum / (capacity_sum * PERIOD(capacity_sum) / 60)
                id: weighted_average
          targetValue: 10

Create predictive scaling policy using customized scaling and predefined load metric

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() => 
{
    var example = new Aws.AutoScaling.Policy("example", new()
    {
        AutoscalingGroupName = "my-test-asg",
        PolicyType = "PredictiveScaling",
        PredictiveScalingConfiguration = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationArgs
        {
            MetricSpecification = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationArgs
            {
                CustomizedScalingMetricSpecification = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs
                {
                    MetricDataQueries = new[]
                    {
                        new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs
                        {
                            Id = "scaling",
                            MetricStat = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatArgs
                            {
                                Metric = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricArgs
                                {
                                    Dimensions = new[]
                                    {
                                        new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricDimensionArgs
                                        {
                                            Name = "AutoScalingGroupName",
                                            Value = "my-test-asg",
                                        },
                                    },
                                    MetricName = "CPUUtilization",
                                    Namespace = "AWS/EC2",
                                },
                                Stat = "Average",
                            },
                        },
                    },
                },
                PredefinedLoadMetricSpecification = new Aws.AutoScaling.Inputs.PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecificationArgs
                {
                    PredefinedMetricType = "ASGTotalCPUUtilization",
                    ResourceLabel = "testLabel",
                },
                TargetValue = 10,
            },
        },
    });

});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/autoscaling"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := autoscaling.NewPolicy(ctx, "example", &autoscaling.PolicyArgs{
			AutoscalingGroupName: pulumi.String("my-test-asg"),
			PolicyType:           pulumi.String("PredictiveScaling"),
			PredictiveScalingConfiguration: &autoscaling.PolicyPredictiveScalingConfigurationArgs{
				MetricSpecification: &autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationArgs{
					CustomizedScalingMetricSpecification: &autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs{
						MetricDataQueries: autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArray{
							&autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs{
								Id: pulumi.String("scaling"),
								MetricStat: &autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatArgs{
									Metric: &autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricArgs{
										Dimensions: autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricDimensionArray{
											&autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricDimensionArgs{
												Name:  pulumi.String("AutoScalingGroupName"),
												Value: pulumi.String("my-test-asg"),
											},
										},
										MetricName: pulumi.String("CPUUtilization"),
										Namespace:  pulumi.String("AWS/EC2"),
									},
									Stat: pulumi.String("Average"),
								},
							},
						},
					},
					PredefinedLoadMetricSpecification: &autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecificationArgs{
						PredefinedMetricType: pulumi.String("ASGTotalCPUUtilization"),
						ResourceLabel:        pulumi.String("testLabel"),
					},
					TargetValue: pulumi.Float64(10),
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.autoscaling.Policy;
import com.pulumi.aws.autoscaling.PolicyArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyPredictiveScalingConfigurationArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyPredictiveScalingConfigurationMetricSpecificationArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs;
import com.pulumi.aws.autoscaling.inputs.PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecificationArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new Policy("example", PolicyArgs.builder()        
            .autoscalingGroupName("my-test-asg")
            .policyType("PredictiveScaling")
            .predictiveScalingConfiguration(PolicyPredictiveScalingConfigurationArgs.builder()
                .metricSpecification(PolicyPredictiveScalingConfigurationMetricSpecificationArgs.builder()
                    .customizedScalingMetricSpecification(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs.builder()
                        .metricDataQueries(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs.builder()
                            .id("scaling")
                            .metricStat(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatArgs.builder()
                                .metric(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricArgs.builder()
                                    .dimensions(PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricDimensionArgs.builder()
                                        .name("AutoScalingGroupName")
                                        .value("my-test-asg")
                                        .build())
                                    .metricName("CPUUtilization")
                                    .namespace("AWS/EC2")
                                    .build())
                                .stat("Average")
                                .build())
                            .build())
                        .build())
                    .predefinedLoadMetricSpecification(PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecificationArgs.builder()
                        .predefinedMetricType("ASGTotalCPUUtilization")
                        .resourceLabel("testLabel")
                        .build())
                    .targetValue(10)
                    .build())
                .build())
            .build());

    }
}
import pulumi
import pulumi_aws as aws

example = aws.autoscaling.Policy("example",
    autoscaling_group_name="my-test-asg",
    policy_type="PredictiveScaling",
    predictive_scaling_configuration=aws.autoscaling.PolicyPredictiveScalingConfigurationArgs(
        metric_specification=aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationArgs(
            customized_scaling_metric_specification=aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationArgs(
                metric_data_queries=[aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryArgs(
                    id="scaling",
                    metric_stat=aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatArgs(
                        metric=aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricArgs(
                            dimensions=[aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricDimensionArgs(
                                name="AutoScalingGroupName",
                                value="my-test-asg",
                            )],
                            metric_name="CPUUtilization",
                            namespace="AWS/EC2",
                        ),
                        stat="Average",
                    ),
                )],
            ),
            predefined_load_metric_specification=aws.autoscaling.PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecificationArgs(
                predefined_metric_type="ASGTotalCPUUtilization",
                resource_label="testLabel",
            ),
            target_value=10,
        ),
    ))
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.autoscaling.Policy("example", {
    autoscalingGroupName: "my-test-asg",
    policyType: "PredictiveScaling",
    predictiveScalingConfiguration: {
        metricSpecification: {
            customizedScalingMetricSpecification: {
                metricDataQueries: [{
                    id: "scaling",
                    metricStat: {
                        metric: {
                            dimensions: [{
                                name: "AutoScalingGroupName",
                                value: "my-test-asg",
                            }],
                            metricName: "CPUUtilization",
                            namespace: "AWS/EC2",
                        },
                        stat: "Average",
                    },
                }],
            },
            predefinedLoadMetricSpecification: {
                predefinedMetricType: "ASGTotalCPUUtilization",
                resourceLabel: "testLabel",
            },
            targetValue: 10,
        },
    },
});
resources:
  example:
    type: aws:autoscaling:Policy
    properties:
      autoscalingGroupName: my-test-asg
      policyType: PredictiveScaling
      predictiveScalingConfiguration:
        metricSpecification:
          customizedScalingMetricSpecification:
            metricDataQueries:
              - id: scaling
                metricStat:
                  metric:
                    dimensions:
                      - name: AutoScalingGroupName
                        value: my-test-asg
                    metricName: CPUUtilization
                    namespace: AWS/EC2
                  stat: Average
          predefinedLoadMetricSpecification:
            predefinedMetricType: ASGTotalCPUUtilization
            resourceLabel: testLabel
          targetValue: 10

Create Policy Resource

new Policy(name: string, args: PolicyArgs, opts?: CustomResourceOptions);
@overload
def Policy(resource_name: str,
           opts: Optional[ResourceOptions] = None,
           adjustment_type: Optional[str] = None,
           autoscaling_group_name: Optional[str] = None,
           cooldown: Optional[int] = None,
           enabled: Optional[bool] = None,
           estimated_instance_warmup: Optional[int] = None,
           metric_aggregation_type: Optional[str] = None,
           min_adjustment_magnitude: Optional[int] = None,
           name: Optional[str] = None,
           policy_type: Optional[str] = None,
           predictive_scaling_configuration: Optional[PolicyPredictiveScalingConfigurationArgs] = None,
           scaling_adjustment: Optional[int] = None,
           step_adjustments: Optional[Sequence[PolicyStepAdjustmentArgs]] = None,
           target_tracking_configuration: Optional[PolicyTargetTrackingConfigurationArgs] = None)
@overload
def Policy(resource_name: str,
           args: PolicyArgs,
           opts: Optional[ResourceOptions] = None)
func NewPolicy(ctx *Context, name string, args PolicyArgs, opts ...ResourceOption) (*Policy, error)
public Policy(string name, PolicyArgs args, CustomResourceOptions? opts = null)
public Policy(String name, PolicyArgs args)
public Policy(String name, PolicyArgs args, CustomResourceOptions options)
type: aws:autoscaling:Policy
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args PolicyArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args PolicyArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args PolicyArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args PolicyArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args PolicyArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Policy Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The Policy resource accepts the following input properties:

AutoscalingGroupName string

Name of the autoscaling group.

AdjustmentType string

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

Cooldown int

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

Enabled bool

Whether the scaling policy is enabled or disabled. Default: true.

EstimatedInstanceWarmup int

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

MetricAggregationType string

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

MinAdjustmentMagnitude int

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

Name string

Name of the policy.

PolicyType string

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

PredictiveScalingConfiguration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

ScalingAdjustment int

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

StepAdjustments List<PolicyStepAdjustmentArgs>

Set of adjustments that manage group scaling. These have the following structure:

TargetTrackingConfiguration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

AutoscalingGroupName string

Name of the autoscaling group.

AdjustmentType string

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

Cooldown int

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

Enabled bool

Whether the scaling policy is enabled or disabled. Default: true.

EstimatedInstanceWarmup int

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

MetricAggregationType string

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

MinAdjustmentMagnitude int

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

Name string

Name of the policy.

PolicyType string

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

PredictiveScalingConfiguration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

ScalingAdjustment int

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

StepAdjustments []PolicyStepAdjustmentArgs

Set of adjustments that manage group scaling. These have the following structure:

TargetTrackingConfiguration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

autoscalingGroupName String

Name of the autoscaling group.

adjustmentType String

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

cooldown Integer

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

enabled Boolean

Whether the scaling policy is enabled or disabled. Default: true.

estimatedInstanceWarmup Integer

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

metricAggregationType String

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

minAdjustmentMagnitude Integer

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

name String

Name of the policy.

policyType String

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

predictiveScalingConfiguration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

scalingAdjustment Integer

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

stepAdjustments List<PolicyStepAdjustmentArgs>

Set of adjustments that manage group scaling. These have the following structure:

targetTrackingConfiguration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

autoscalingGroupName string

Name of the autoscaling group.

adjustmentType string

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

cooldown number

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

enabled boolean

Whether the scaling policy is enabled or disabled. Default: true.

estimatedInstanceWarmup number

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

metricAggregationType string

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

minAdjustmentMagnitude number

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

name string

Name of the policy.

policyType string

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

predictiveScalingConfiguration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

scalingAdjustment number

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

stepAdjustments PolicyStepAdjustmentArgs[]

Set of adjustments that manage group scaling. These have the following structure:

targetTrackingConfiguration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

autoscaling_group_name str

Name of the autoscaling group.

adjustment_type str

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

cooldown int

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

enabled bool

Whether the scaling policy is enabled or disabled. Default: true.

estimated_instance_warmup int

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

metric_aggregation_type str

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

min_adjustment_magnitude int

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

name str

Name of the policy.

policy_type str

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

predictive_scaling_configuration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

scaling_adjustment int

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

step_adjustments Sequence[PolicyStepAdjustmentArgs]

Set of adjustments that manage group scaling. These have the following structure:

target_tracking_configuration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

autoscalingGroupName String

Name of the autoscaling group.

adjustmentType String

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

cooldown Number

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

enabled Boolean

Whether the scaling policy is enabled or disabled. Default: true.

estimatedInstanceWarmup Number

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

metricAggregationType String

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

minAdjustmentMagnitude Number

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

name String

Name of the policy.

policyType String

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

predictiveScalingConfiguration Property Map

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

scalingAdjustment Number

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

stepAdjustments List<Property Map>

Set of adjustments that manage group scaling. These have the following structure:

targetTrackingConfiguration Property Map

Target tracking policy. These have the following structure:

Outputs

All input properties are implicitly available as output properties. Additionally, the Policy resource produces the following output properties:

Arn string

ARN assigned by AWS to the scaling policy.

Id string

The provider-assigned unique ID for this managed resource.

Arn string

ARN assigned by AWS to the scaling policy.

Id string

The provider-assigned unique ID for this managed resource.

arn String

ARN assigned by AWS to the scaling policy.

id String

The provider-assigned unique ID for this managed resource.

arn string

ARN assigned by AWS to the scaling policy.

id string

The provider-assigned unique ID for this managed resource.

arn str

ARN assigned by AWS to the scaling policy.

id str

The provider-assigned unique ID for this managed resource.

arn String

ARN assigned by AWS to the scaling policy.

id String

The provider-assigned unique ID for this managed resource.

Look up Existing Policy Resource

Get an existing Policy resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: PolicyState, opts?: CustomResourceOptions): Policy
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        adjustment_type: Optional[str] = None,
        arn: Optional[str] = None,
        autoscaling_group_name: Optional[str] = None,
        cooldown: Optional[int] = None,
        enabled: Optional[bool] = None,
        estimated_instance_warmup: Optional[int] = None,
        metric_aggregation_type: Optional[str] = None,
        min_adjustment_magnitude: Optional[int] = None,
        name: Optional[str] = None,
        policy_type: Optional[str] = None,
        predictive_scaling_configuration: Optional[PolicyPredictiveScalingConfigurationArgs] = None,
        scaling_adjustment: Optional[int] = None,
        step_adjustments: Optional[Sequence[PolicyStepAdjustmentArgs]] = None,
        target_tracking_configuration: Optional[PolicyTargetTrackingConfigurationArgs] = None) -> Policy
func GetPolicy(ctx *Context, name string, id IDInput, state *PolicyState, opts ...ResourceOption) (*Policy, error)
public static Policy Get(string name, Input<string> id, PolicyState? state, CustomResourceOptions? opts = null)
public static Policy get(String name, Output<String> id, PolicyState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
AdjustmentType string

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

Arn string

ARN assigned by AWS to the scaling policy.

AutoscalingGroupName string

Name of the autoscaling group.

Cooldown int

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

Enabled bool

Whether the scaling policy is enabled or disabled. Default: true.

EstimatedInstanceWarmup int

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

MetricAggregationType string

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

MinAdjustmentMagnitude int

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

Name string

Name of the policy.

PolicyType string

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

PredictiveScalingConfiguration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

ScalingAdjustment int

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

StepAdjustments List<PolicyStepAdjustmentArgs>

Set of adjustments that manage group scaling. These have the following structure:

TargetTrackingConfiguration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

AdjustmentType string

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

Arn string

ARN assigned by AWS to the scaling policy.

AutoscalingGroupName string

Name of the autoscaling group.

Cooldown int

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

Enabled bool

Whether the scaling policy is enabled or disabled. Default: true.

EstimatedInstanceWarmup int

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

MetricAggregationType string

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

MinAdjustmentMagnitude int

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

Name string

Name of the policy.

PolicyType string

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

PredictiveScalingConfiguration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

ScalingAdjustment int

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

StepAdjustments []PolicyStepAdjustmentArgs

Set of adjustments that manage group scaling. These have the following structure:

TargetTrackingConfiguration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

adjustmentType String

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

arn String

ARN assigned by AWS to the scaling policy.

autoscalingGroupName String

Name of the autoscaling group.

cooldown Integer

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

enabled Boolean

Whether the scaling policy is enabled or disabled. Default: true.

estimatedInstanceWarmup Integer

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

metricAggregationType String

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

minAdjustmentMagnitude Integer

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

name String

Name of the policy.

policyType String

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

predictiveScalingConfiguration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

scalingAdjustment Integer

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

stepAdjustments List<PolicyStepAdjustmentArgs>

Set of adjustments that manage group scaling. These have the following structure:

targetTrackingConfiguration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

adjustmentType string

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

arn string

ARN assigned by AWS to the scaling policy.

autoscalingGroupName string

Name of the autoscaling group.

cooldown number

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

enabled boolean

Whether the scaling policy is enabled or disabled. Default: true.

estimatedInstanceWarmup number

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

metricAggregationType string

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

minAdjustmentMagnitude number

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

name string

Name of the policy.

policyType string

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

predictiveScalingConfiguration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

scalingAdjustment number

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

stepAdjustments PolicyStepAdjustmentArgs[]

Set of adjustments that manage group scaling. These have the following structure:

targetTrackingConfiguration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

adjustment_type str

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

arn str

ARN assigned by AWS to the scaling policy.

autoscaling_group_name str

Name of the autoscaling group.

cooldown int

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

enabled bool

Whether the scaling policy is enabled or disabled. Default: true.

estimated_instance_warmup int

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

metric_aggregation_type str

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

min_adjustment_magnitude int

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

name str

Name of the policy.

policy_type str

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

predictive_scaling_configuration PolicyPredictiveScalingConfigurationArgs

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

scaling_adjustment int

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

step_adjustments Sequence[PolicyStepAdjustmentArgs]

Set of adjustments that manage group scaling. These have the following structure:

target_tracking_configuration PolicyTargetTrackingConfigurationArgs

Target tracking policy. These have the following structure:

adjustmentType String

Whether the adjustment is an absolute number or a percentage of the current capacity. Valid values are ChangeInCapacity, ExactCapacity, and PercentChangeInCapacity.

arn String

ARN assigned by AWS to the scaling policy.

autoscalingGroupName String

Name of the autoscaling group.

cooldown Number

Amount of time, in seconds, after a scaling activity completes and before the next scaling activity can start.

enabled Boolean

Whether the scaling policy is enabled or disabled. Default: true.

estimatedInstanceWarmup Number

Estimated time, in seconds, until a newly launched instance will contribute CloudWatch metrics. Without a value, AWS will default to the group's specified cooldown period.

metricAggregationType String

Aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".

minAdjustmentMagnitude Number

Minimum value to scale by when adjustment_type is set to PercentChangeInCapacity.

name String

Name of the policy.

policyType String

Policy type, either "SimpleScaling", "StepScaling", "TargetTrackingScaling", or "PredictiveScaling". If this value isn't provided, AWS will default to "SimpleScaling."

predictiveScalingConfiguration Property Map

Predictive scaling policy configuration to use with Amazon EC2 Auto Scaling.

scalingAdjustment Number

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

stepAdjustments List<Property Map>

Set of adjustments that manage group scaling. These have the following structure:

targetTrackingConfiguration Property Map

Target tracking policy. These have the following structure:

Supporting Types

PolicyPredictiveScalingConfiguration

MetricSpecification PolicyPredictiveScalingConfigurationMetricSpecification

This structure includes the metrics and target utilization to use for predictive scaling.

MaxCapacityBreachBehavior string

Defines the behavior that should be applied if the forecast capacity approaches or exceeds the maximum capacity of the Auto Scaling group. Valid values are HonorMaxCapacity or IncreaseMaxCapacity. Default is HonorMaxCapacity.

MaxCapacityBuffer string

Size of the capacity buffer to use when the forecast capacity is close to or exceeds the maximum capacity. Valid range is 0 to 100. If set to 0, Amazon EC2 Auto Scaling may scale capacity higher than the maximum capacity to equal but not exceed forecast capacity.

Mode string

Predictive scaling mode. Valid values are ForecastAndScale and ForecastOnly. Default is ForecastOnly.

SchedulingBufferTime string

Amount of time, in seconds, by which the instance launch time can be advanced. Minimum is 0.

MetricSpecification PolicyPredictiveScalingConfigurationMetricSpecification

This structure includes the metrics and target utilization to use for predictive scaling.

MaxCapacityBreachBehavior string

Defines the behavior that should be applied if the forecast capacity approaches or exceeds the maximum capacity of the Auto Scaling group. Valid values are HonorMaxCapacity or IncreaseMaxCapacity. Default is HonorMaxCapacity.

MaxCapacityBuffer string

Size of the capacity buffer to use when the forecast capacity is close to or exceeds the maximum capacity. Valid range is 0 to 100. If set to 0, Amazon EC2 Auto Scaling may scale capacity higher than the maximum capacity to equal but not exceed forecast capacity.

Mode string

Predictive scaling mode. Valid values are ForecastAndScale and ForecastOnly. Default is ForecastOnly.

SchedulingBufferTime string

Amount of time, in seconds, by which the instance launch time can be advanced. Minimum is 0.

metricSpecification PolicyPredictiveScalingConfigurationMetricSpecification

This structure includes the metrics and target utilization to use for predictive scaling.

maxCapacityBreachBehavior String

Defines the behavior that should be applied if the forecast capacity approaches or exceeds the maximum capacity of the Auto Scaling group. Valid values are HonorMaxCapacity or IncreaseMaxCapacity. Default is HonorMaxCapacity.

maxCapacityBuffer String

Size of the capacity buffer to use when the forecast capacity is close to or exceeds the maximum capacity. Valid range is 0 to 100. If set to 0, Amazon EC2 Auto Scaling may scale capacity higher than the maximum capacity to equal but not exceed forecast capacity.

mode String

Predictive scaling mode. Valid values are ForecastAndScale and ForecastOnly. Default is ForecastOnly.

schedulingBufferTime String

Amount of time, in seconds, by which the instance launch time can be advanced. Minimum is 0.

metricSpecification PolicyPredictiveScalingConfigurationMetricSpecification

This structure includes the metrics and target utilization to use for predictive scaling.

maxCapacityBreachBehavior string

Defines the behavior that should be applied if the forecast capacity approaches or exceeds the maximum capacity of the Auto Scaling group. Valid values are HonorMaxCapacity or IncreaseMaxCapacity. Default is HonorMaxCapacity.

maxCapacityBuffer string

Size of the capacity buffer to use when the forecast capacity is close to or exceeds the maximum capacity. Valid range is 0 to 100. If set to 0, Amazon EC2 Auto Scaling may scale capacity higher than the maximum capacity to equal but not exceed forecast capacity.

mode string

Predictive scaling mode. Valid values are ForecastAndScale and ForecastOnly. Default is ForecastOnly.

schedulingBufferTime string

Amount of time, in seconds, by which the instance launch time can be advanced. Minimum is 0.

metric_specification PolicyPredictiveScalingConfigurationMetricSpecification

This structure includes the metrics and target utilization to use for predictive scaling.

max_capacity_breach_behavior str

Defines the behavior that should be applied if the forecast capacity approaches or exceeds the maximum capacity of the Auto Scaling group. Valid values are HonorMaxCapacity or IncreaseMaxCapacity. Default is HonorMaxCapacity.

max_capacity_buffer str

Size of the capacity buffer to use when the forecast capacity is close to or exceeds the maximum capacity. Valid range is 0 to 100. If set to 0, Amazon EC2 Auto Scaling may scale capacity higher than the maximum capacity to equal but not exceed forecast capacity.

mode str

Predictive scaling mode. Valid values are ForecastAndScale and ForecastOnly. Default is ForecastOnly.

scheduling_buffer_time str

Amount of time, in seconds, by which the instance launch time can be advanced. Minimum is 0.

metricSpecification Property Map

This structure includes the metrics and target utilization to use for predictive scaling.

maxCapacityBreachBehavior String

Defines the behavior that should be applied if the forecast capacity approaches or exceeds the maximum capacity of the Auto Scaling group. Valid values are HonorMaxCapacity or IncreaseMaxCapacity. Default is HonorMaxCapacity.

maxCapacityBuffer String

Size of the capacity buffer to use when the forecast capacity is close to or exceeds the maximum capacity. Valid range is 0 to 100. If set to 0, Amazon EC2 Auto Scaling may scale capacity higher than the maximum capacity to equal but not exceed forecast capacity.

mode String

Predictive scaling mode. Valid values are ForecastAndScale and ForecastOnly. Default is ForecastOnly.

schedulingBufferTime String

Amount of time, in seconds, by which the instance launch time can be advanced. Minimum is 0.

PolicyPredictiveScalingConfigurationMetricSpecification

TargetValue double

Target value for the metric.

CustomizedCapacityMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecification

Customized capacity metric specification. The field is only valid when you use customized_load_metric_specification

CustomizedLoadMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecification

Customized load metric specification.

CustomizedScalingMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecification

Customized scaling metric specification.

PredefinedLoadMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecification

Predefined load metric specification.

PredefinedMetricPairSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedMetricPairSpecification

Metric pair specification from which Amazon EC2 Auto Scaling determines the appropriate scaling metric and load metric to use.

PredefinedScalingMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedScalingMetricSpecification

Predefined scaling metric specification.

TargetValue float64

Target value for the metric.

CustomizedCapacityMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecification

Customized capacity metric specification. The field is only valid when you use customized_load_metric_specification

CustomizedLoadMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecification

Customized load metric specification.

CustomizedScalingMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecification

Customized scaling metric specification.

PredefinedLoadMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecification

Predefined load metric specification.

PredefinedMetricPairSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedMetricPairSpecification

Metric pair specification from which Amazon EC2 Auto Scaling determines the appropriate scaling metric and load metric to use.

PredefinedScalingMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedScalingMetricSpecification

Predefined scaling metric specification.

targetValue Double

Target value for the metric.

customizedCapacityMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecification

Customized capacity metric specification. The field is only valid when you use customized_load_metric_specification

customizedLoadMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecification

Customized load metric specification.

customizedScalingMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecification

Customized scaling metric specification.

predefinedLoadMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecification

Predefined load metric specification.

predefinedMetricPairSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedMetricPairSpecification

Metric pair specification from which Amazon EC2 Auto Scaling determines the appropriate scaling metric and load metric to use.

predefinedScalingMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedScalingMetricSpecification

Predefined scaling metric specification.

targetValue number

Target value for the metric.

customizedCapacityMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecification

Customized capacity metric specification. The field is only valid when you use customized_load_metric_specification

customizedLoadMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecification

Customized load metric specification.

customizedScalingMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecification

Customized scaling metric specification.

predefinedLoadMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecification

Predefined load metric specification.

predefinedMetricPairSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedMetricPairSpecification

Metric pair specification from which Amazon EC2 Auto Scaling determines the appropriate scaling metric and load metric to use.

predefinedScalingMetricSpecification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedScalingMetricSpecification

Predefined scaling metric specification.

target_value float

Target value for the metric.

customized_capacity_metric_specification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecification

Customized capacity metric specification. The field is only valid when you use customized_load_metric_specification

customized_load_metric_specification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecification

Customized load metric specification.

customized_scaling_metric_specification PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecification

Customized scaling metric specification.

predefined_load_metric_specification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecification

Predefined load metric specification.

predefined_metric_pair_specification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedMetricPairSpecification

Metric pair specification from which Amazon EC2 Auto Scaling determines the appropriate scaling metric and load metric to use.

predefined_scaling_metric_specification PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedScalingMetricSpecification

Predefined scaling metric specification.

targetValue Number

Target value for the metric.

customizedCapacityMetricSpecification Property Map

Customized capacity metric specification. The field is only valid when you use customized_load_metric_specification

customizedLoadMetricSpecification Property Map

Customized load metric specification.

customizedScalingMetricSpecification Property Map

Customized scaling metric specification.

predefinedLoadMetricSpecification Property Map

Predefined load metric specification.

predefinedMetricPairSpecification Property Map

Metric pair specification from which Amazon EC2 Auto Scaling determines the appropriate scaling metric and load metric to use.

predefinedScalingMetricSpecification Property Map

Predefined scaling metric specification.

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecification

MetricDataQueries List<PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQuery>

List of up to 10 structures that defines custom capacity metric in predictive scaling policy

MetricDataQueries []PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQuery

List of up to 10 structures that defines custom capacity metric in predictive scaling policy

metricDataQueries List<PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQuery>

List of up to 10 structures that defines custom capacity metric in predictive scaling policy

metricDataQueries PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQuery[]

List of up to 10 structures that defines custom capacity metric in predictive scaling policy

metric_data_queries Sequence[PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQuery]

List of up to 10 structures that defines custom capacity metric in predictive scaling policy

metricDataQueries List<Property Map>

List of up to 10 structures that defines custom capacity metric in predictive scaling policy

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQuery

Id string

Short name for the metric used in predictive scaling policy.

Expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

Label string

Human-readable label for this metric or expression.

MetricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

ReturnData bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

Id string

Short name for the metric used in predictive scaling policy.

Expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

Label string

Human-readable label for this metric or expression.

MetricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

ReturnData bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id String

Short name for the metric used in predictive scaling policy.

expression String

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label String

Human-readable label for this metric or expression.

metricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

returnData Boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id string

Short name for the metric used in predictive scaling policy.

expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label string

Human-readable label for this metric or expression.

metricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

returnData boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id str

Short name for the metric used in predictive scaling policy.

expression str

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label str

Human-readable label for this metric or expression.

metric_stat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

return_data bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id String

Short name for the metric used in predictive scaling policy.

expression String

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label String

Human-readable label for this metric or expression.

metricStat Property Map

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

returnData Boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStat

Metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

Stat string

Statistic of the metrics to return.

Unit string

Unit of the metrics to return.

Metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

Stat string

Statistic of the metrics to return.

Unit string

Unit of the metrics to return.

metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat String

Statistic of the metrics to return.

unit String

Unit of the metrics to return.

metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat string

Statistic of the metrics to return.

unit string

Unit of the metrics to return.

metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat str

Statistic of the metrics to return.

unit str

Unit of the metrics to return.

metric Property Map

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat String

Statistic of the metrics to return.

unit String

Unit of the metrics to return.

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStatMetric

metricName String

Name of the metric.

namespace String

Namespace of the metric.

dimensions List<Property Map>

Dimensions of the metric.

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedCapacityMetricSpecificationMetricDataQueryMetricStatMetricDimension

Name string

Name of the dimension.

Value string

Value of the dimension.

Name string

Name of the dimension.

Value string

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

name string

Name of the dimension.

value string

Value of the dimension.

name str

Name of the dimension.

value str

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecification

MetricDataQueries List<PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQuery>

List of up to 10 structures that defines custom load metric in predictive scaling policy

MetricDataQueries []PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQuery

List of up to 10 structures that defines custom load metric in predictive scaling policy

metricDataQueries List<PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQuery>

List of up to 10 structures that defines custom load metric in predictive scaling policy

metricDataQueries PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQuery[]

List of up to 10 structures that defines custom load metric in predictive scaling policy

metric_data_queries Sequence[PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQuery]

List of up to 10 structures that defines custom load metric in predictive scaling policy

metricDataQueries List<Property Map>

List of up to 10 structures that defines custom load metric in predictive scaling policy

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQuery

Id string

Short name for the metric used in predictive scaling policy.

Expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

Label string

Human-readable label for this metric or expression.

MetricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

ReturnData bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

Id string

Short name for the metric used in predictive scaling policy.

Expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

Label string

Human-readable label for this metric or expression.

MetricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

ReturnData bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id String

Short name for the metric used in predictive scaling policy.

expression String

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label String

Human-readable label for this metric or expression.

metricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

returnData Boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id string

Short name for the metric used in predictive scaling policy.

expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label string

Human-readable label for this metric or expression.

metricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

returnData boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id str

Short name for the metric used in predictive scaling policy.

expression str

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label str

Human-readable label for this metric or expression.

metric_stat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

return_data bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id String

Short name for the metric used in predictive scaling policy.

expression String

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label String

Human-readable label for this metric or expression.

metricStat Property Map

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

returnData Boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStat

Metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

Stat string

Statistic of the metrics to return.

Unit string

Unit of the metrics to return.

Metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

Stat string

Statistic of the metrics to return.

Unit string

Unit of the metrics to return.

metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat String

Statistic of the metrics to return.

unit String

Unit of the metrics to return.

metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat string

Statistic of the metrics to return.

unit string

Unit of the metrics to return.

metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat str

Statistic of the metrics to return.

unit str

Unit of the metrics to return.

metric Property Map

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat String

Statistic of the metrics to return.

unit String

Unit of the metrics to return.

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStatMetric

metricName String

Name of the metric.

namespace String

Namespace of the metric.

dimensions List<Property Map>

Dimensions of the metric.

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedLoadMetricSpecificationMetricDataQueryMetricStatMetricDimension

Name string

Name of the dimension.

Value string

Value of the dimension.

Name string

Name of the dimension.

Value string

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

name string

Name of the dimension.

value string

Value of the dimension.

name str

Name of the dimension.

value str

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecification

MetricDataQueries List<PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQuery>

List of up to 10 structures that defines custom scaling metric in predictive scaling policy

MetricDataQueries []PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQuery

List of up to 10 structures that defines custom scaling metric in predictive scaling policy

metricDataQueries List<PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQuery>

List of up to 10 structures that defines custom scaling metric in predictive scaling policy

metricDataQueries PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQuery[]

List of up to 10 structures that defines custom scaling metric in predictive scaling policy

metric_data_queries Sequence[PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQuery]

List of up to 10 structures that defines custom scaling metric in predictive scaling policy

metricDataQueries List<Property Map>

List of up to 10 structures that defines custom scaling metric in predictive scaling policy

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQuery

Id string

Short name for the metric used in predictive scaling policy.

Expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

Label string

Human-readable label for this metric or expression.

MetricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

ReturnData bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

Id string

Short name for the metric used in predictive scaling policy.

Expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

Label string

Human-readable label for this metric or expression.

MetricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

ReturnData bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id String

Short name for the metric used in predictive scaling policy.

expression String

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label String

Human-readable label for this metric or expression.

metricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

returnData Boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id string

Short name for the metric used in predictive scaling policy.

expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label string

Human-readable label for this metric or expression.

metricStat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

returnData boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id str

Short name for the metric used in predictive scaling policy.

expression str

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label str

Human-readable label for this metric or expression.

metric_stat PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStat

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

return_data bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id String

Short name for the metric used in predictive scaling policy.

expression String

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label String

Human-readable label for this metric or expression.

metricStat Property Map

Structure that defines CloudWatch metric to be used in predictive scaling policy. You must specify either expression or metric_stat, but not both.

returnData Boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStat

Metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

Stat string

Statistic of the metrics to return.

Unit string

Unit of the metrics to return.

Metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

Stat string

Statistic of the metrics to return.

Unit string

Unit of the metrics to return.

metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat String

Statistic of the metrics to return.

unit String

Unit of the metrics to return.

metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat string

Statistic of the metrics to return.

unit string

Unit of the metrics to return.

metric PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat str

Statistic of the metrics to return.

unit str

Unit of the metrics to return.

metric Property Map

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat String

Statistic of the metrics to return.

unit String

Unit of the metrics to return.

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetric

metricName String

Name of the metric.

namespace String

Namespace of the metric.

dimensions List<Property Map>

Dimensions of the metric.

PolicyPredictiveScalingConfigurationMetricSpecificationCustomizedScalingMetricSpecificationMetricDataQueryMetricStatMetricDimension

Name string

Name of the dimension.

Value string

Value of the dimension.

Name string

Name of the dimension.

Value string

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

name string

Name of the dimension.

value string

Value of the dimension.

name str

Name of the dimension.

value str

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedLoadMetricSpecification

PredefinedMetricType string

Metric type. Valid values are ASGTotalCPUUtilization, ASGTotalNetworkIn, ASGTotalNetworkOut, or ALBTargetGroupRequestCount.

ResourceLabel string

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

PredefinedMetricType string

Metric type. Valid values are ASGTotalCPUUtilization, ASGTotalNetworkIn, ASGTotalNetworkOut, or ALBTargetGroupRequestCount.

ResourceLabel string

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefinedMetricType String

Metric type. Valid values are ASGTotalCPUUtilization, ASGTotalNetworkIn, ASGTotalNetworkOut, or ALBTargetGroupRequestCount.

resourceLabel String

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefinedMetricType string

Metric type. Valid values are ASGTotalCPUUtilization, ASGTotalNetworkIn, ASGTotalNetworkOut, or ALBTargetGroupRequestCount.

resourceLabel string

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefined_metric_type str

Metric type. Valid values are ASGTotalCPUUtilization, ASGTotalNetworkIn, ASGTotalNetworkOut, or ALBTargetGroupRequestCount.

resource_label str

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefinedMetricType String

Metric type. Valid values are ASGTotalCPUUtilization, ASGTotalNetworkIn, ASGTotalNetworkOut, or ALBTargetGroupRequestCount.

resourceLabel String

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedMetricPairSpecification

PredefinedMetricType string

Which metrics to use. There are two different types of metrics for each metric type: one is a load metric and one is a scaling metric. For example, if the metric type is ASGCPUUtilization, the Auto Scaling group's total CPU metric is used as the load metric, and the average CPU metric is used for the scaling metric. Valid values are ASGCPUUtilization, ASGNetworkIn, ASGNetworkOut, or ALBRequestCount.

ResourceLabel string

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

PredefinedMetricType string

Which metrics to use. There are two different types of metrics for each metric type: one is a load metric and one is a scaling metric. For example, if the metric type is ASGCPUUtilization, the Auto Scaling group's total CPU metric is used as the load metric, and the average CPU metric is used for the scaling metric. Valid values are ASGCPUUtilization, ASGNetworkIn, ASGNetworkOut, or ALBRequestCount.

ResourceLabel string

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefinedMetricType String

Which metrics to use. There are two different types of metrics for each metric type: one is a load metric and one is a scaling metric. For example, if the metric type is ASGCPUUtilization, the Auto Scaling group's total CPU metric is used as the load metric, and the average CPU metric is used for the scaling metric. Valid values are ASGCPUUtilization, ASGNetworkIn, ASGNetworkOut, or ALBRequestCount.

resourceLabel String

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefinedMetricType string

Which metrics to use. There are two different types of metrics for each metric type: one is a load metric and one is a scaling metric. For example, if the metric type is ASGCPUUtilization, the Auto Scaling group's total CPU metric is used as the load metric, and the average CPU metric is used for the scaling metric. Valid values are ASGCPUUtilization, ASGNetworkIn, ASGNetworkOut, or ALBRequestCount.

resourceLabel string

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefined_metric_type str

Which metrics to use. There are two different types of metrics for each metric type: one is a load metric and one is a scaling metric. For example, if the metric type is ASGCPUUtilization, the Auto Scaling group's total CPU metric is used as the load metric, and the average CPU metric is used for the scaling metric. Valid values are ASGCPUUtilization, ASGNetworkIn, ASGNetworkOut, or ALBRequestCount.

resource_label str

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefinedMetricType String

Which metrics to use. There are two different types of metrics for each metric type: one is a load metric and one is a scaling metric. For example, if the metric type is ASGCPUUtilization, the Auto Scaling group's total CPU metric is used as the load metric, and the average CPU metric is used for the scaling metric. Valid values are ASGCPUUtilization, ASGNetworkIn, ASGNetworkOut, or ALBRequestCount.

resourceLabel String

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

PolicyPredictiveScalingConfigurationMetricSpecificationPredefinedScalingMetricSpecification

PredefinedMetricType string

Describes a scaling metric for a predictive scaling policy. Valid values are ASGAverageCPUUtilization, ASGAverageNetworkIn, ASGAverageNetworkOut, or ALBRequestCountPerTarget.

ResourceLabel string

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

PredefinedMetricType string

Describes a scaling metric for a predictive scaling policy. Valid values are ASGAverageCPUUtilization, ASGAverageNetworkIn, ASGAverageNetworkOut, or ALBRequestCountPerTarget.

ResourceLabel string

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefinedMetricType String

Describes a scaling metric for a predictive scaling policy. Valid values are ASGAverageCPUUtilization, ASGAverageNetworkIn, ASGAverageNetworkOut, or ALBRequestCountPerTarget.

resourceLabel String

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefinedMetricType string

Describes a scaling metric for a predictive scaling policy. Valid values are ASGAverageCPUUtilization, ASGAverageNetworkIn, ASGAverageNetworkOut, or ALBRequestCountPerTarget.

resourceLabel string

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefined_metric_type str

Describes a scaling metric for a predictive scaling policy. Valid values are ASGAverageCPUUtilization, ASGAverageNetworkIn, ASGAverageNetworkOut, or ALBRequestCountPerTarget.

resource_label str

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

predefinedMetricType String

Describes a scaling metric for a predictive scaling policy. Valid values are ASGAverageCPUUtilization, ASGAverageNetworkIn, ASGAverageNetworkOut, or ALBRequestCountPerTarget.

resourceLabel String

Label that uniquely identifies a specific Application Load Balancer target group from which to determine the request count served by your Auto Scaling group.

PolicyStepAdjustment

ScalingAdjustment int

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

MetricIntervalLowerBound string

Lower bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as negative infinity.

MetricIntervalUpperBound string

Upper bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as positive infinity. The upper bound must be greater than the lower bound.

ScalingAdjustment int

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

MetricIntervalLowerBound string

Lower bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as negative infinity.

MetricIntervalUpperBound string

Upper bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as positive infinity. The upper bound must be greater than the lower bound.

scalingAdjustment Integer

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

metricIntervalLowerBound String

Lower bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as negative infinity.

metricIntervalUpperBound String

Upper bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as positive infinity. The upper bound must be greater than the lower bound.

scalingAdjustment number

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

metricIntervalLowerBound string

Lower bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as negative infinity.

metricIntervalUpperBound string

Upper bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as positive infinity. The upper bound must be greater than the lower bound.

scaling_adjustment int

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

metric_interval_lower_bound str

Lower bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as negative infinity.

metric_interval_upper_bound str

Upper bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as positive infinity. The upper bound must be greater than the lower bound.

scalingAdjustment Number

Number of members by which to scale, when the adjustment bounds are breached. A positive value scales up. A negative value scales down.

metricIntervalLowerBound String

Lower bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as negative infinity.

metricIntervalUpperBound String

Upper bound for the difference between the alarm threshold and the CloudWatch metric. Without a value, AWS will treat this bound as positive infinity. The upper bound must be greater than the lower bound.

PolicyTargetTrackingConfiguration

TargetValue double

Target value for the metric.

CustomizedMetricSpecification PolicyTargetTrackingConfigurationCustomizedMetricSpecification

Customized metric. Conflicts with predefined_metric_specification.

DisableScaleIn bool

Whether scale in by the target tracking policy is disabled.

PredefinedMetricSpecification PolicyTargetTrackingConfigurationPredefinedMetricSpecification

Predefined metric. Conflicts with customized_metric_specification.

TargetValue float64

Target value for the metric.

CustomizedMetricSpecification PolicyTargetTrackingConfigurationCustomizedMetricSpecification

Customized metric. Conflicts with predefined_metric_specification.

DisableScaleIn bool

Whether scale in by the target tracking policy is disabled.

PredefinedMetricSpecification PolicyTargetTrackingConfigurationPredefinedMetricSpecification

Predefined metric. Conflicts with customized_metric_specification.

targetValue Double

Target value for the metric.

customizedMetricSpecification PolicyTargetTrackingConfigurationCustomizedMetricSpecification

Customized metric. Conflicts with predefined_metric_specification.

disableScaleIn Boolean

Whether scale in by the target tracking policy is disabled.

predefinedMetricSpecification PolicyTargetTrackingConfigurationPredefinedMetricSpecification

Predefined metric. Conflicts with customized_metric_specification.

targetValue number

Target value for the metric.

customizedMetricSpecification PolicyTargetTrackingConfigurationCustomizedMetricSpecification

Customized metric. Conflicts with predefined_metric_specification.

disableScaleIn boolean

Whether scale in by the target tracking policy is disabled.

predefinedMetricSpecification PolicyTargetTrackingConfigurationPredefinedMetricSpecification

Predefined metric. Conflicts with customized_metric_specification.

target_value float

Target value for the metric.

customized_metric_specification PolicyTargetTrackingConfigurationCustomizedMetricSpecification

Customized metric. Conflicts with predefined_metric_specification.

disable_scale_in bool

Whether scale in by the target tracking policy is disabled.

predefined_metric_specification PolicyTargetTrackingConfigurationPredefinedMetricSpecification

Predefined metric. Conflicts with customized_metric_specification.

targetValue Number

Target value for the metric.

customizedMetricSpecification Property Map

Customized metric. Conflicts with predefined_metric_specification.

disableScaleIn Boolean

Whether scale in by the target tracking policy is disabled.

predefinedMetricSpecification Property Map

Predefined metric. Conflicts with customized_metric_specification.

PolicyTargetTrackingConfigurationCustomizedMetricSpecification

MetricDimensions List<PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricDimension>

Dimensions of the metric.

MetricName string

Name of the metric.

Metrics List<PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetric>

Metrics to include, as a metric data query.

Namespace string

Namespace of the metric.

Statistic string

Statistic of the metric.

Unit string

Unit of the metric.

MetricDimensions []PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricDimension

Dimensions of the metric.

MetricName string

Name of the metric.

Metrics []PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetric

Metrics to include, as a metric data query.

Namespace string

Namespace of the metric.

Statistic string

Statistic of the metric.

Unit string

Unit of the metric.

metricDimensions List<PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricDimension>

Dimensions of the metric.

metricName String

Name of the metric.

metrics List<PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetric>

Metrics to include, as a metric data query.

namespace String

Namespace of the metric.

statistic String

Statistic of the metric.

unit String

Unit of the metric.

metricDimensions PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricDimension[]

Dimensions of the metric.

metricName string

Name of the metric.

metrics PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetric[]

Metrics to include, as a metric data query.

namespace string

Namespace of the metric.

statistic string

Statistic of the metric.

unit string

Unit of the metric.

metric_dimensions Sequence[PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricDimension]

Dimensions of the metric.

metric_name str

Name of the metric.

metrics Sequence[PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetric]

Metrics to include, as a metric data query.

namespace str

Namespace of the metric.

statistic str

Statistic of the metric.

unit str

Unit of the metric.

metricDimensions List<Property Map>

Dimensions of the metric.

metricName String

Name of the metric.

metrics List<Property Map>

Metrics to include, as a metric data query.

namespace String

Namespace of the metric.

statistic String

Statistic of the metric.

unit String

Unit of the metric.

PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetric

Id string

Short name for the metric used in target tracking scaling policy.

Expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

Label string

Human-readable label for this metric or expression.

MetricStat PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStat

Structure that defines CloudWatch metric to be used in target tracking scaling policy. You must specify either expression or metric_stat, but not both.

ReturnData bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

Id string

Short name for the metric used in target tracking scaling policy.

Expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

Label string

Human-readable label for this metric or expression.

MetricStat PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStat

Structure that defines CloudWatch metric to be used in target tracking scaling policy. You must specify either expression or metric_stat, but not both.

ReturnData bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id String

Short name for the metric used in target tracking scaling policy.

expression String

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label String

Human-readable label for this metric or expression.

metricStat PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStat

Structure that defines CloudWatch metric to be used in target tracking scaling policy. You must specify either expression or metric_stat, but not both.

returnData Boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id string

Short name for the metric used in target tracking scaling policy.

expression string

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label string

Human-readable label for this metric or expression.

metricStat PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStat

Structure that defines CloudWatch metric to be used in target tracking scaling policy. You must specify either expression or metric_stat, but not both.

returnData boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id str

Short name for the metric used in target tracking scaling policy.

expression str

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label str

Human-readable label for this metric or expression.

metric_stat PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStat

Structure that defines CloudWatch metric to be used in target tracking scaling policy. You must specify either expression or metric_stat, but not both.

return_data bool

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

id String

Short name for the metric used in target tracking scaling policy.

expression String

Math expression used on the returned metric. You must specify either expression or metric_stat, but not both.

label String

Human-readable label for this metric or expression.

metricStat Property Map

Structure that defines CloudWatch metric to be used in target tracking scaling policy. You must specify either expression or metric_stat, but not both.

returnData Boolean

Boolean that indicates whether to return the timestamps and raw data values of this metric, the default is true

PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricDimension

Name string

Name of the dimension.

Value string

Value of the dimension.

Name string

Name of the dimension.

Value string

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

name string

Name of the dimension.

value string

Value of the dimension.

name str

Name of the dimension.

value str

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStat

Metric PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

Stat string

Statistic of the metrics to return.

Unit string

Unit of the metrics to return.

Metric PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

Stat string

Statistic of the metrics to return.

Unit string

Unit of the metrics to return.

metric PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat String

Statistic of the metrics to return.

unit String

Unit of the metrics to return.

metric PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat string

Statistic of the metrics to return.

unit string

Unit of the metrics to return.

metric PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetric

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat str

Statistic of the metrics to return.

unit str

Unit of the metrics to return.

metric Property Map

Structure that defines the CloudWatch metric to return, including the metric name, namespace, and dimensions.

stat String

Statistic of the metrics to return.

unit String

Unit of the metrics to return.

PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetric

MetricName string

Name of the metric.

Namespace string

Namespace of the metric.

Dimensions []PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimension

Dimensions of the metric.

metricName string

Name of the metric.

namespace string

Namespace of the metric.

dimensions PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimension[]

Dimensions of the metric.

metricName String

Name of the metric.

namespace String

Namespace of the metric.

dimensions List<Property Map>

Dimensions of the metric.

PolicyTargetTrackingConfigurationCustomizedMetricSpecificationMetricMetricStatMetricDimension

Name string

Name of the dimension.

Value string

Value of the dimension.

Name string

Name of the dimension.

Value string

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

name string

Name of the dimension.

value string

Value of the dimension.

name str

Name of the dimension.

value str

Value of the dimension.

name String

Name of the dimension.

value String

Value of the dimension.

PolicyTargetTrackingConfigurationPredefinedMetricSpecification

PredefinedMetricType string

Metric type.

ResourceLabel string

Identifies the resource associated with the metric type.

PredefinedMetricType string

Metric type.

ResourceLabel string

Identifies the resource associated with the metric type.

predefinedMetricType String

Metric type.

resourceLabel String

Identifies the resource associated with the metric type.

predefinedMetricType string

Metric type.

resourceLabel string

Identifies the resource associated with the metric type.

predefined_metric_type str

Metric type.

resource_label str

Identifies the resource associated with the metric type.

predefinedMetricType String

Metric type.

resourceLabel String

Identifies the resource associated with the metric type.

Import

AutoScaling scaling policy can be imported using the role autoscaling_group_name and name separated by /.

 $ pulumi import aws:autoscaling/policy:Policy test-policy asg-name/policy-name

Package Details

Repository
AWS Classic pulumi/pulumi-aws
License
Apache-2.0
Notes

This Pulumi package is based on the aws Terraform Provider.