AWS::AutoScalingPlans::ScalingPlan - AWS CloudFormation


The AWS::AutoScalingPlans::ScalingPlan resource defines a scaling plan that AWS Auto Scaling uses to scale the following application resources:

  • Amazon EC2 Auto Scaling groups

  • Amazon EC2 Spot Fleet requests

  • Amazon ECS services

  • Amazon DynamoDB tables and global secondary indexes

  • Amazon Aurora Replicas

For more information, see the AWS Auto Scaling User Guide.


To declare this entity in your AWS CloudFormation template, use the following syntax:


{ "Type" : "AWS::AutoScalingPlans::ScalingPlan", "Properties" : { "ApplicationSource" : ApplicationSource, "ScalingInstructions" : [ ScalingInstruction, ... ] } }


Type: AWS::AutoScalingPlans::ScalingPlan Properties: ApplicationSource: ApplicationSource ScalingInstructions: - ScalingInstruction



A CloudFormation stack or a set of tags. You can create one scaling plan per application source.

Required: Yes

Type: ApplicationSource

Update requires: No interruption


The scaling instructions.

Required: Yes

Type: List of ScalingInstruction

Update requires: No interruption

Return Values


When you pass the logical ID of an AWS::AutoScalingPlans::ScalingPlan resource to the intrinsic Ref function, the function returns the Amazon Resource Name (ARN) of the scaling plan. The format of the ARN is as follows:


For more information about using the Ref function, see Ref.


Scaling Plan

The following example creates a scaling plan named myScalingPlan for an existing Auto Scaling group whose name you specify (along with other values) when launching the stack using this template. It specifies the TagFilters property as the application source and enables predictive scaling and dynamic scaling.


{ "AWSTemplateFormatVersion":"2010-09-09", "Parameters":{ "myTagKey":{ "Type":"String" }, "myTagValue":{ "Type":"String" }, "myASGroup":{ "Type":"String", "Description":"Name of the Auto Scaling group" }, "ASGMinCapacity":{ "Type":"Number" }, "ASGMaxCapacity":{ "Type":"Number" }, "ASGTargetUtilization":{ "Type":"Number", "Default":"50.0" }, "ASGEstimatedInstanceWarmup":{ "Type":"Number", "Default":"600" } }, "Resources":{ "myScalingPlan":{ "Type":"AWS::AutoScalingPlans::ScalingPlan", "Properties":{ "ApplicationSource":{ "TagFilters":[ { "Key":{ "Ref":"myTagKey" }, "Values":[{ "Ref":"myTagValue" }] } ] }, "ScalingInstructions":[ { "MinCapacity":{ "Ref":"ASGMinCapacity" }, "MaxCapacity":{ "Ref":"ASGMaxCapacity" }, "ServiceNamespace":"autoscaling", "ScalableDimension":"autoscaling:autoScalingGroup:DesiredCapacity", "ResourceId":{ "Fn::Join":[ "/", [ "autoScalingGroup", { "Ref":"myASGroup" } ] ] }, "TargetTrackingConfigurations":[ { "PredefinedScalingMetricSpecification":{ "PredefinedScalingMetricType":"ASGAverageCPUUtilization" }, "TargetValue":{ "Ref":"ASGTargetUtilization" }, "EstimatedInstanceWarmup":{ "Ref":"ASGEstimatedInstanceWarmup" } } ], "PredefinedLoadMetricSpecification":{ "PredefinedLoadMetricType":"ASGTotalCPUUtilization" }, "PredictiveScalingMode":"ForecastAndScale", "PredictiveScalingMaxCapacityBehavior":"SetMaxCapacityAboveForecastCapacity", "PredictiveScalingMaxCapacityBuffer":25, "ScheduledActionBufferTime":600 } ] } } } }


AWSTemplateFormatVersion: 2010-09-09 Parameters: myTagKey: Type: String myTagValue: Type: String myASGroup: Type: String Description: Name of the Auto Scaling group ASGMinCapacity: Type: Number ASGMaxCapacity: Type: Number ASGTargetUtilization: Type: Number Default: 50.0 ASGEstimatedInstanceWarmup: Type: Number Default: 600 Resources: myScalingPlan: Type: AWS::AutoScalingPlans::ScalingPlan Properties: ApplicationSource: TagFilters: - Key: !Ref myTagKey Values: - !Ref myTagValue ScalingInstructions: - MinCapacity: !Ref ASGMinCapacity MaxCapacity: !Ref ASGMaxCapacity ServiceNamespace: autoscaling ScalableDimension: autoscaling:autoScalingGroup:DesiredCapacity ResourceId: !Join - / - - autoScalingGroup - !Ref myASGroup TargetTrackingConfigurations: - PredefinedScalingMetricSpecification: PredefinedScalingMetricType: "ASGAverageCPUUtilization" TargetValue: !Ref ASGTargetUtilization EstimatedInstanceWarmup: !Ref ASGEstimatedInstanceWarmup PredefinedLoadMetricSpecification: PredefinedLoadMetricType: "ASGTotalCPUUtilization" PredictiveScalingMode: "ForecastAndScale" PredictiveScalingMaxCapacityBehavior: "SetMaxCapacityAboveForecastCapacity" PredictiveScalingMaxCapacityBuffer: 25 ScheduledActionBufferTime: 600