使用 設定 Application Auto Scaling 資源 AWS CloudFormation - AWS CloudFormation

本文為英文版的機器翻譯版本,如內容有任何歧義或不一致之處,概以英文版為準。

使用 設定 Application Auto Scaling 資源 AWS CloudFormation

本節提供 Application Auto Scaling 擴展政策和不同 AWS 資源排程動作的 AWS CloudFormation 範本範例。

重要

當範本中包含 Application Auto Scaling 程式碼片段時,您可能需要宣告對使用 透過範本建立的特定可擴展資源的相依性DependsOn 屬性。這會覆寫預設平行處理,並指示 AWS CloudFormation 以指定的順序在資源上操作。否則,擴展組態可能會在完全設定資源前套用。

建立 AppStream 機群的擴展政策

此程式碼片段說明如何建立政策,並使用 AWS::AppStream::Fleet 資源將其套用至AWS::ApplicationAutoScaling::ScalingPolicy資源。AWS::ApplicationAutoScaling::ScalableTarget 資源宣告套用此政策的可擴展目標。Application Auto Scaling 可擴展的機群執行個體數量下限為 1 個執行個體、上限為 20 個執行個體。該政策使機群的平均容量使用率保持在 75%,擴增和縮減的冷卻時間為 300 秒 (5 分鐘)。

它使用 Fn::JoinRef 內部函數,以相同範本中指定的AWS::AppStream::Fleet資源邏輯名稱來建構 ResourceId 屬性。

JSON

{ "Resources" : { "ScalableTarget" : { "Type" : "AWS::ApplicationAutoScaling::ScalableTarget", "Properties" : { "MaxCapacity" : 20, "MinCapacity" : 1, "RoleARN" : { "Fn::Sub" : "arn:aws:iam::${AWS::AccountId}:role/aws-service-role/appstream.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_AppStreamFleet" }, "ServiceNamespace" : "appstream", "ScalableDimension" : "appstream:fleet:DesiredCapacity", "ResourceId" : { "Fn::Join" : [ "/", [ "fleet", { "Ref" : "logicalName" } ] ] } } }, "ScalingPolicyAppStreamFleet" : { "Type" : "AWS::ApplicationAutoScaling::ScalingPolicy", "Properties" : { "PolicyName" : { "Fn::Sub" : "${AWS::StackName}-target-tracking-cpu75" }, "PolicyType" : "TargetTrackingScaling", "ServiceNamespace" : "appstream", "ScalableDimension" : "appstream:fleet:DesiredCapacity", "ResourceId" : { "Fn::Join" : [ "/", [ "fleet", { "Ref" : "logicalName" } ] ] }, "TargetTrackingScalingPolicyConfiguration" : { "TargetValue" : 75, "PredefinedMetricSpecification" : { "PredefinedMetricType" : "AppStreamAverageCapacityUtilization" }, "ScaleInCooldown" : 300, "ScaleOutCooldown" : 300 } } } } }

YAML

--- Resources: ScalableTarget: Type: AWS::ApplicationAutoScaling::ScalableTarget Properties: MaxCapacity: 20 MinCapacity: 1 RoleARN: Fn::Sub: 'arn:aws:iam::${AWS::AccountId}:role/aws-service-role/appstream.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_AppStreamFleet' ServiceNamespace: appstream ScalableDimension: appstream:fleet:DesiredCapacity ResourceId: !Join - / - - fleet - !Ref logicalName ScalingPolicyAppStreamFleet: Type: AWS::ApplicationAutoScaling::ScalingPolicy Properties: PolicyName: !Sub ${AWS::StackName}-target-tracking-cpu75 PolicyType: TargetTrackingScaling ServiceNamespace: appstream ScalableDimension: appstream:fleet:DesiredCapacity ResourceId: !Join - / - - fleet - !Ref logicalName TargetTrackingScalingPolicyConfiguration: TargetValue: 75 PredefinedMetricSpecification: PredefinedMetricType: AppStreamAverageCapacityUtilization ScaleInCooldown: 300 ScaleOutCooldown: 300

為 Aurora 資料庫叢集建立擴展政策

在此程式碼片段中,您會註冊AWS::RDS::DBCluster資源。AWS::ApplicationAutoScaling::ScalableTarget 資源指出資料庫叢集應該動態擴展為具有一個到八個 Aurora 複本。您也可以使用 AWS::ApplicationAutoScaling::ScalingPolicy 資源將目標追蹤擴展政策套用至叢集。

在此組態中,RDSReaderAverageCPUUtilization預先定義的指標用於根據該 Aurora 資料庫叢集中所有 Aurora 複本的平均CPU使用率 40% 來調整 Aurora 資料庫叢集。這個組態分別提供了 10 分鐘的規模縮減冷卻時間,和 5 分鐘的橫向擴展冷卻時間。

此範例使用Fn::Sub內部 函數,以相同範本中指定的AWS::RDS::DBCluster資源邏輯名稱來建構 ResourceId 屬性。

JSON

{ "Resources" : { "ScalableTarget" : { "Type" : "AWS::ApplicationAutoScaling::ScalableTarget", "Properties" : { "MaxCapacity" : 8, "MinCapacity" : 1, "RoleARN" : { "Fn::Sub" : "arn:aws:iam::${AWS::AccountId}:role/aws-service-role/rds.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_RDSCluster" }, "ServiceNamespace" : "rds", "ScalableDimension" : "rds:cluster:ReadReplicaCount", "ResourceId" : { "Fn::Sub" : "cluster:${logicalName}" } } }, "ScalingPolicyDBCluster" : { "Type" : "AWS::ApplicationAutoScaling::ScalingPolicy", "Properties" : { "PolicyName" : { "Fn::Sub" : "${AWS::StackName}-target-tracking-cpu40" }, "PolicyType" : "TargetTrackingScaling", "ServiceNamespace" : "rds", "ScalableDimension" : "rds:cluster:ReadReplicaCount", "ResourceId" : { "Fn::Sub" : "cluster:${logicalName}" }, "TargetTrackingScalingPolicyConfiguration" : { "TargetValue" : 40, "PredefinedMetricSpecification" : { "PredefinedMetricType" : "RDSReaderAverageCPUUtilization" }, "ScaleInCooldown" : 600, "ScaleOutCooldown" : 300 } } } } }

YAML

--- Resources: ScalableTarget: Type: AWS::ApplicationAutoScaling::ScalableTarget Properties: MaxCapacity: 8 MinCapacity: 1 RoleARN: Fn::Sub: 'arn:aws:iam::${AWS::AccountId}:role/aws-service-role/rds.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_RDSCluster' ServiceNamespace: rds ScalableDimension: rds:cluster:ReadReplicaCount ResourceId: !Sub cluster:${logicalName} ScalingPolicyDBCluster: Type: AWS::ApplicationAutoScaling::ScalingPolicy Properties: PolicyName: !Sub ${AWS::StackName}-target-tracking-cpu40 PolicyType: TargetTrackingScaling ServiceNamespace: rds ScalableDimension: rds:cluster:ReadReplicaCount ResourceId: !Sub cluster:${logicalName} TargetTrackingScalingPolicyConfiguration: TargetValue: 40 PredefinedMetricSpecification: PredefinedMetricType: RDSReaderAverageCPUUtilization ScaleInCooldown: 600 ScaleOutCooldown: 300

建立 DynamoDB 資料表的擴展政策

此程式碼片段說明如何使用政策類型建立TargetTrackingScaling政策,並使用 AWS::DynamoDB::Table 資源將其套用至AWS::ApplicationAutoScaling::ScalingPolicy資源。AWS::ApplicationAutoScaling::ScalableTarget 資源宣告套用此政策的可擴展目標,其中寫入容量單位最少為五個,最多為 15 個。此擴展政策會根據 DynamoDBWriteCapacityUtilization 預先定義指標擴展資料表的寫入容量輸送量,以將目標使用率維持在 50%。

它使用 Ref Fn::Join和內部 函數,以相同範本中指定的AWS::DynamoDB::Table資源邏輯名稱來建構 ResourceId 屬性。

注意

如需如何建立 DynamoDB 資源 AWS CloudFormation 範本的詳細資訊,請參閱部落格文章如何使用 AWS CloudFormation 設定資料庫部落格上 Amazon DynamoDB 資料表和索引的自動擴展。 AWS

JSON

{ "Resources" : { "WriteCapacityScalableTarget" : { "Type" : "AWS::ApplicationAutoScaling::ScalableTarget", "Properties" : { "MaxCapacity" : 15, "MinCapacity" : 5, "RoleARN" : { "Fn::Sub" : "arn:aws:iam::${AWS::AccountId}:role/aws-service-role/dynamodb.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_DynamoDBTable" }, "ServiceNamespace" : "dynamodb", "ScalableDimension" : "dynamodb:table:WriteCapacityUnits", "ResourceId" : { "Fn::Join" : [ "/", [ "table", { "Ref" : "logicalName" } ] ] } } }, "WriteScalingPolicy" : { "Type" : "AWS::ApplicationAutoScaling::ScalingPolicy", "Properties" : { "PolicyName" : "WriteScalingPolicy", "PolicyType" : "TargetTrackingScaling", "ScalingTargetId" : { "Ref" : "WriteCapacityScalableTarget" }, "TargetTrackingScalingPolicyConfiguration" : { "TargetValue" : 50.0, "ScaleInCooldown" : 60, "ScaleOutCooldown" : 60, "PredefinedMetricSpecification" : { "PredefinedMetricType" : "DynamoDBWriteCapacityUtilization" } } } } } }

YAML

--- Resources: WriteCapacityScalableTarget: Type: AWS::ApplicationAutoScaling::ScalableTarget Properties: MaxCapacity: 15 MinCapacity: 5 RoleARN: Fn::Sub: 'arn:aws:iam::${AWS::AccountId}:role/aws-service-role/dynamodb.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_DynamoDBTable' ServiceNamespace: dynamodb ScalableDimension: dynamodb:table:WriteCapacityUnits ResourceId: !Join - / - - table - !Ref logicalName WriteScalingPolicy: Type: AWS::ApplicationAutoScaling::ScalingPolicy Properties: PolicyName: WriteScalingPolicy PolicyType: TargetTrackingScaling ScalingTargetId: !Ref WriteCapacityScalableTarget TargetTrackingScalingPolicyConfiguration: TargetValue: 50.0 ScaleInCooldown: 60 ScaleOutCooldown: 60 PredefinedMetricSpecification: PredefinedMetricType: DynamoDBWriteCapacityUtilization

建立 Amazon ECS服務的擴展政策 (指標:平均值CPU和記憶體)

此程式碼片段說明如何建立政策,並使用 AWS::ECS::Service 資源將其套用至AWS::ApplicationAutoScaling::ScalingPolicy資源。AWS::ApplicationAutoScaling::ScalableTarget 資源宣告套用此政策的可擴展目標。Application Auto Scaling 可擴展的任務數量下限為 1 個任務、上限為 6 個任務。

這會建立兩個具有 TargetTrackingScaling 政策類型的擴展政策。這些政策用於根據ECS服務的平均CPU和記憶體用量來擴展服務。它使用 Ref Fn::Join和內部 函數,以相同範本中指定的 AWS::ECS::ClustermyContainerCluster) 和 AWS::ECS::ServicemyService) 資源的邏輯名稱來建構 ResourceId 屬性。

JSON

{ "Resources" : { "ECSScalableTarget" : { "Type" : "AWS::ApplicationAutoScaling::ScalableTarget", "Properties" : { "MaxCapacity" : "6", "MinCapacity" : "1", "RoleARN" : { "Fn::Sub" : "arn:aws:iam::${AWS::AccountId}:role/aws-service-role/ecs.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_ECSService" }, "ServiceNamespace" : "ecs", "ScalableDimension" : "ecs:service:DesiredCount", "ResourceId" : { "Fn::Join" : [ "/", [ "service", { "Ref" : "myContainerCluster" }, { "Fn::GetAtt" : [ "myService", "Name" ] } ] ] } } }, "ServiceScalingPolicyCPU" : { "Type" : "AWS::ApplicationAutoScaling::ScalingPolicy", "Properties" : { "PolicyName" : { "Fn::Sub" : "${AWS::StackName}-target-tracking-cpu70" }, "PolicyType" : "TargetTrackingScaling", "ScalingTargetId" : { "Ref" : "ECSScalableTarget" }, "TargetTrackingScalingPolicyConfiguration" : { "TargetValue" : 70.0, "ScaleInCooldown" : 180, "ScaleOutCooldown" : 60, "PredefinedMetricSpecification" : { "PredefinedMetricType" : "ECSServiceAverageCPUUtilization" } } } }, "ServiceScalingPolicyMem" : { "Type" : "AWS::ApplicationAutoScaling::ScalingPolicy", "Properties" : { "PolicyName" : { "Fn::Sub" : "${AWS::StackName}-target-tracking-mem90" }, "PolicyType" : "TargetTrackingScaling", "ScalingTargetId" : { "Ref" : "ECSScalableTarget" }, "TargetTrackingScalingPolicyConfiguration" : { "TargetValue" : 90.0, "ScaleInCooldown" : 180, "ScaleOutCooldown" : 60, "PredefinedMetricSpecification" : { "PredefinedMetricType" : "ECSServiceAverageMemoryUtilization" } } } } } }

YAML

--- Resources: ECSScalableTarget: Type: AWS::ApplicationAutoScaling::ScalableTarget Properties: MaxCapacity: 6 MinCapacity: 1 RoleARN: Fn::Sub: 'arn:aws:iam::${AWS::AccountId}:role/aws-service-role/ecs.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_ECSService' ServiceNamespace: ecs ScalableDimension: 'ecs:service:DesiredCount' ResourceId: !Join - / - - service - !Ref myContainerCluster - !GetAtt myService.Name ServiceScalingPolicyCPU: Type: AWS::ApplicationAutoScaling::ScalingPolicy Properties: PolicyName: !Sub ${AWS::StackName}-target-tracking-cpu70 PolicyType: TargetTrackingScaling ScalingTargetId: !Ref ECSScalableTarget TargetTrackingScalingPolicyConfiguration: TargetValue: 70.0 ScaleInCooldown: 180 ScaleOutCooldown: 60 PredefinedMetricSpecification: PredefinedMetricType: ECSServiceAverageCPUUtilization ServiceScalingPolicyMem: Type: AWS::ApplicationAutoScaling::ScalingPolicy Properties: PolicyName: !Sub ${AWS::StackName}-target-tracking-mem90 PolicyType: TargetTrackingScaling ScalingTargetId: !Ref ECSScalableTarget TargetTrackingScalingPolicyConfiguration: TargetValue: 90.0 ScaleInCooldown: 180 ScaleOutCooldown: 60 PredefinedMetricSpecification: PredefinedMetricType: ECSServiceAverageMemoryUtilization

建立 Amazon ECS服務的擴展政策 (指標:每個目標的平均請求計數)

下列範例會將具有ALBRequestCountPerTarget預先定義指標的目標追蹤擴展政策套用至 ECS服務。當每個目標的請求計數 (每分鐘) 超過目標值時,此政策用於將容量新增至ECS服務。因為 DisableScaleIn 的值設為 true,所以目標追蹤政策不會從可擴展的目標移除容量。

它使用 Fn::GetAtt Fn::Join和內部 函數,以相同範本中指定的 AWS::ElasticLoadBalancingV2::LoadBalancermyLoadBalancer) 和 AWS::ElasticLoadBalancingV2::TargetGroupmyTargetGroup) 資源的邏輯名稱來建構 ResourceLabel 屬性。

可擴展目標的 MaxCapacityMinCapacity 屬性和擴展政策的 TargetValue 屬性會參考建立或更新堆疊時傳遞至範本的參數值。

JSON

{ "Resources" : { "ECSScalableTarget" : { "Type" : "AWS::ApplicationAutoScaling::ScalableTarget", "Properties" : { "MaxCapacity" : { "Ref" : "MaxCount" }, "MinCapacity" : { "Ref" : "MinCount" }, "RoleARN" : { "Fn::Sub" : "arn:aws:iam::${AWS::AccountId}:role/aws-service-role/ecs.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_ECSService" }, "ServiceNamespace" : "ecs", "ScalableDimension" : "ecs:service:DesiredCount", "ResourceId" : { "Fn::Join" : [ "/", [ "service", { "Ref" : "myContainerCluster" }, { "Fn::GetAtt" : [ "myService", "Name" ] } ] ] } } }, "ServiceScalingPolicyALB" : { "Type" : "AWS::ApplicationAutoScaling::ScalingPolicy", "Properties" : { "PolicyName" : "alb-requests-per-target-per-minute", "PolicyType" : "TargetTrackingScaling", "ScalingTargetId" : { "Ref" : "ECSScalableTarget" }, "TargetTrackingScalingPolicyConfiguration" : { "TargetValue" : { "Ref" : "ALBPolicyTargetValue" }, "ScaleInCooldown" : 180, "ScaleOutCooldown" : 30, "DisableScaleIn" : true, "PredefinedMetricSpecification" : { "PredefinedMetricType" : "ALBRequestCountPerTarget", "ResourceLabel" : { "Fn::Join" : [ "/", [ { "Fn::GetAtt" : [ "myLoadBalancer", "LoadBalancerFullName" ] }, { "Fn::GetAtt" : [ "myTargetGroup", "TargetGroupFullName" ] } ] ] } } } } } } }

YAML

--- Resources: ECSScalableTarget: Type: AWS::ApplicationAutoScaling::ScalableTarget Properties: MaxCapacity: !Ref MaxCount MinCapacity: !Ref MinCount RoleARN: Fn::Sub: 'arn:aws:iam::${AWS::AccountId}:role/aws-service-role/ecs.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_ECSService' ServiceNamespace: ecs ScalableDimension: 'ecs:service:DesiredCount' ResourceId: !Join - / - - service - !Ref myContainerCluster - !GetAtt myService.Name ServiceScalingPolicyALB: Type: AWS::ApplicationAutoScaling::ScalingPolicy Properties: PolicyName: alb-requests-per-target-per-minute PolicyType: TargetTrackingScaling ScalingTargetId: !Ref ECSScalableTarget TargetTrackingScalingPolicyConfiguration: TargetValue: !Ref ALBPolicyTargetValue ScaleInCooldown: 180 ScaleOutCooldown: 30 DisableScaleIn: true PredefinedMetricSpecification: PredefinedMetricType: ALBRequestCountPerTarget ResourceLabel: !Join - '/' - - !GetAtt myLoadBalancer.LoadBalancerFullName - !GetAtt myTargetGroup.TargetGroupFullName

使用 Lambda 函數的 Cron 表達式建立排程動作

此程式碼片段會使用 AWS::ApplicationAutoScaling::ScalableTarget 資源為名為 BLUE的函數別名 (AWS::Lambda::Alias) 註冊佈建並行。還建立排程動作,並使用 Cron 運算式設定重複排程。週期性排程的時區為 UTC。

它使用 RoleARN 屬性中的 Ref Fn::Join和內部函數來指定服務連結角色ARN的 。它使用Fn::Sub內部 函數,以相同範本中指定的 AWS::Lambda::FunctionAWS::Serverless::Function 資源的邏輯名稱來建構 ResourceId 屬性。

注意

您無法在指向未發佈版本的別名上配置佈建並行 ($LATEST)。

如需有關如何建立 Lambda 資源 AWS CloudFormation 範本的詳細資訊,請參閱 AWS 運算部落格上的部落格文章排程 AWS Lambda 佈建並行,以取得週期性尖峰用量

JSON

{ "ScalableTarget" : { "Type" : "AWS::ApplicationAutoScaling::ScalableTarget", "Properties" : { "MaxCapacity" : 250, "MinCapacity" : 0, "RoleARN" : { "Fn::Join" : [ ":", [ "arn:aws:iam:", { "Ref" : "AWS::AccountId" }, "role/aws-service-role/lambda.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_LambdaConcurrency" ] ] }, "ServiceNamespace" : "lambda", "ScalableDimension" : "lambda:function:ProvisionedConcurrency", "ResourceId" : { "Fn::Sub" : "function:${logicalName}:BLUE" }, "ScheduledActions" : [ { "ScalableTargetAction" : { "MinCapacity" : "250" }, "ScheduledActionName" : "my-scale-out-scheduled-action", "Schedule" : "cron(0 18 * * ? *)", "EndTime" : "2022-12-31T12:00:00.000Z" } ] } } }

YAML

ScalableTarget: Type: AWS::ApplicationAutoScaling::ScalableTarget Properties: MaxCapacity: 250 MinCapacity: 0 RoleARN: !Join - ':' - - 'arn:aws:iam:' - !Ref 'AWS::AccountId' - role/aws-service-role/lambda.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_LambdaConcurrency ServiceNamespace: lambda ScalableDimension: lambda:function:ProvisionedConcurrency ResourceId: !Sub function:${logicalName}:BLUE ScheduledActions: - ScalableTargetAction: MinCapacity: 250 ScheduledActionName: my-scale-out-scheduled-action Schedule: 'cron(0 18 * * ? *)' EndTime: '2022-12-31T12:00:00.000Z'

使用 Spot 機群的at表達式建立排程動作

此程式碼片段示範如何使用 AWS::EC2::SpotFleet 資源為AWS::ApplicationAutoScaling::ScalableTarget資源建立僅發生一次的兩個排程動作。每個一次性排程動作的時區為 UTC。

它使用 Ref Fn::Join和內部 函數,以相同範本中指定的AWS::EC2::SpotFleet資源邏輯名稱來建構 ResourceId 屬性。

注意

Spot 機群請求必須具有 maintain 的請求類型。一次性請求或 Spot 區塊不支援自動擴展功能。

JSON

{ "Resources" : { "SpotFleetScalableTarget" : { "Type" : "AWS::ApplicationAutoScaling::ScalableTarget", "Properties" : { "MaxCapacity" : 0, "MinCapacity" : 0, "RoleARN" : { "Fn::Sub" : "arn:aws:iam::${AWS::AccountId}:role/aws-service-role/ec2.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_EC2SpotFleetRequest" }, "ServiceNamespace" : "ec2", "ScalableDimension" : "ec2:spot-fleet-request:TargetCapacity", "ResourceId" : { "Fn::Join" : [ "/", [ "spot-fleet-request", { "Ref" : "logicalName" } ] ] }, "ScheduledActions" : [ { "ScalableTargetAction" : { "MaxCapacity" : "10", "MinCapacity" : "10" }, "ScheduledActionName" : "my-scale-out-scheduled-action", "Schedule" : "at(2022-05-20T13:00:00)" }, { "ScalableTargetAction" : { "MaxCapacity" : "0", "MinCapacity" : "0" }, "ScheduledActionName" : "my-scale-in-scheduled-action", "Schedule" : "at(2022-05-20T21:00:00)" } ] } } } }

YAML

--- Resources: SpotFleetScalableTarget: Type: AWS::ApplicationAutoScaling::ScalableTarget Properties: MaxCapacity: 0 MinCapacity: 0 RoleARN: Fn::Sub: 'arn:aws:iam::${AWS::AccountId}:role/aws-service-role/ec2.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_EC2SpotFleetRequest' ServiceNamespace: ec2 ScalableDimension: 'ec2:spot-fleet-request:TargetCapacity' ResourceId: !Join - / - - spot-fleet-request - !Ref logicalName ScheduledActions: - ScalableTargetAction: MaxCapacity: 10 MinCapacity: 10 ScheduledActionName: my-scale-out-scheduled-action Schedule: 'at(2022-05-20T13:00:00)' - ScalableTargetAction: MaxCapacity: 0 MinCapacity: 0 ScheduledActionName: my-scale-in-scheduled-action Schedule: 'at(2022-05-20T21:00:00)'