Skip to content

Commit d8a4d0b

Browse files
author
awstools
committed
feat(client-application-auto-scaling): Application Auto Scaling now supports Predictive Scaling to proactively increase the desired capacity ahead of predicted demand, ensuring improved availability and responsiveness for customers' applications. This feature is currently only made available for Amazon ECS Service scalable targets.
1 parent 1a8d64c commit d8a4d0b

File tree

11 files changed

+1930
-4
lines changed

11 files changed

+1930
-4
lines changed

clients/client-application-auto-scaling/README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -340,6 +340,14 @@ DescribeScheduledActions
340340

341341
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/application-auto-scaling/command/DescribeScheduledActionsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-application-auto-scaling/Interface/DescribeScheduledActionsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-application-auto-scaling/Interface/DescribeScheduledActionsCommandOutput/)
342342

343+
</details>
344+
<details>
345+
<summary>
346+
GetPredictiveScalingForecast
347+
</summary>
348+
349+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/application-auto-scaling/command/GetPredictiveScalingForecastCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-application-auto-scaling/Interface/GetPredictiveScalingForecastCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-application-auto-scaling/Interface/GetPredictiveScalingForecastCommandOutput/)
350+
343351
</details>
344352
<details>
345353
<summary>

clients/client-application-auto-scaling/src/ApplicationAutoScaling.ts

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,11 @@ import {
3838
DescribeScheduledActionsCommandInput,
3939
DescribeScheduledActionsCommandOutput,
4040
} from "./commands/DescribeScheduledActionsCommand";
41+
import {
42+
GetPredictiveScalingForecastCommand,
43+
GetPredictiveScalingForecastCommandInput,
44+
GetPredictiveScalingForecastCommandOutput,
45+
} from "./commands/GetPredictiveScalingForecastCommand";
4146
import {
4247
ListTagsForResourceCommand,
4348
ListTagsForResourceCommandInput,
@@ -73,6 +78,7 @@ const commands = {
7378
DescribeScalingActivitiesCommand,
7479
DescribeScalingPoliciesCommand,
7580
DescribeScheduledActionsCommand,
81+
GetPredictiveScalingForecastCommand,
7682
ListTagsForResourceCommand,
7783
PutScalingPolicyCommand,
7884
PutScheduledActionCommand,
@@ -201,6 +207,23 @@ export interface ApplicationAutoScaling {
201207
cb: (err: any, data?: DescribeScheduledActionsCommandOutput) => void
202208
): void;
203209

210+
/**
211+
* @see {@link GetPredictiveScalingForecastCommand}
212+
*/
213+
getPredictiveScalingForecast(
214+
args: GetPredictiveScalingForecastCommandInput,
215+
options?: __HttpHandlerOptions
216+
): Promise<GetPredictiveScalingForecastCommandOutput>;
217+
getPredictiveScalingForecast(
218+
args: GetPredictiveScalingForecastCommandInput,
219+
cb: (err: any, data?: GetPredictiveScalingForecastCommandOutput) => void
220+
): void;
221+
getPredictiveScalingForecast(
222+
args: GetPredictiveScalingForecastCommandInput,
223+
options: __HttpHandlerOptions,
224+
cb: (err: any, data?: GetPredictiveScalingForecastCommandOutput) => void
225+
): void;
226+
204227
/**
205228
* @see {@link ListTagsForResourceCommand}
206229
*/

clients/client-application-auto-scaling/src/ApplicationAutoScalingClient.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,10 @@ import {
8181
DescribeScheduledActionsCommandInput,
8282
DescribeScheduledActionsCommandOutput,
8383
} from "./commands/DescribeScheduledActionsCommand";
84+
import {
85+
GetPredictiveScalingForecastCommandInput,
86+
GetPredictiveScalingForecastCommandOutput,
87+
} from "./commands/GetPredictiveScalingForecastCommand";
8488
import {
8589
ListTagsForResourceCommandInput,
8690
ListTagsForResourceCommandOutput,
@@ -115,6 +119,7 @@ export type ServiceInputTypes =
115119
| DescribeScalingActivitiesCommandInput
116120
| DescribeScalingPoliciesCommandInput
117121
| DescribeScheduledActionsCommandInput
122+
| GetPredictiveScalingForecastCommandInput
118123
| ListTagsForResourceCommandInput
119124
| PutScalingPolicyCommandInput
120125
| PutScheduledActionCommandInput
@@ -133,6 +138,7 @@ export type ServiceOutputTypes =
133138
| DescribeScalingActivitiesCommandOutput
134139
| DescribeScalingPoliciesCommandOutput
135140
| DescribeScheduledActionsCommandOutput
141+
| GetPredictiveScalingForecastCommandOutput
136142
| ListTagsForResourceCommandOutput
137143
| PutScalingPolicyCommandOutput
138144
| PutScheduledActionCommandOutput

clients/client-application-auto-scaling/src/commands/DescribeScalableTargetsCommand.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ export interface DescribeScalableTargetsCommandOutput extends DescribeScalableTa
6060
* // ScalableDimension: "ecs:service:DesiredCount" || "ec2:spot-fleet-request:TargetCapacity" || "elasticmapreduce:instancegroup:InstanceCount" || "appstream:fleet:DesiredCapacity" || "dynamodb:table:ReadCapacityUnits" || "dynamodb:table:WriteCapacityUnits" || "dynamodb:index:ReadCapacityUnits" || "dynamodb:index:WriteCapacityUnits" || "rds:cluster:ReadReplicaCount" || "sagemaker:variant:DesiredInstanceCount" || "custom-resource:ResourceType:Property" || "comprehend:document-classifier-endpoint:DesiredInferenceUnits" || "comprehend:entity-recognizer-endpoint:DesiredInferenceUnits" || "lambda:function:ProvisionedConcurrency" || "cassandra:table:ReadCapacityUnits" || "cassandra:table:WriteCapacityUnits" || "kafka:broker-storage:VolumeSize" || "elasticache:replication-group:NodeGroups" || "elasticache:replication-group:Replicas" || "neptune:cluster:ReadReplicaCount" || "sagemaker:variant:DesiredProvisionedConcurrency" || "sagemaker:inference-component:DesiredCopyCount" || "workspaces:workspacespool:DesiredUserSessions", // required
6161
* // MinCapacity: Number("int"), // required
6262
* // MaxCapacity: Number("int"), // required
63+
* // PredictedCapacity: Number("int"),
6364
* // RoleARN: "STRING_VALUE", // required
6465
* // CreationTime: new Date("TIMESTAMP"), // required
6566
* // SuspendedState: { // SuspendedState

clients/client-application-auto-scaling/src/commands/DescribeScalingPoliciesCommand.ts

Lines changed: 96 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ export interface DescribeScalingPoliciesCommandOutput extends DescribeScalingPol
6262
* // ServiceNamespace: "ecs" || "elasticmapreduce" || "ec2" || "appstream" || "dynamodb" || "rds" || "sagemaker" || "custom-resource" || "comprehend" || "lambda" || "cassandra" || "kafka" || "elasticache" || "neptune" || "workspaces", // required
6363
* // ResourceId: "STRING_VALUE", // required
6464
* // ScalableDimension: "ecs:service:DesiredCount" || "ec2:spot-fleet-request:TargetCapacity" || "elasticmapreduce:instancegroup:InstanceCount" || "appstream:fleet:DesiredCapacity" || "dynamodb:table:ReadCapacityUnits" || "dynamodb:table:WriteCapacityUnits" || "dynamodb:index:ReadCapacityUnits" || "dynamodb:index:WriteCapacityUnits" || "rds:cluster:ReadReplicaCount" || "sagemaker:variant:DesiredInstanceCount" || "custom-resource:ResourceType:Property" || "comprehend:document-classifier-endpoint:DesiredInferenceUnits" || "comprehend:entity-recognizer-endpoint:DesiredInferenceUnits" || "lambda:function:ProvisionedConcurrency" || "cassandra:table:ReadCapacityUnits" || "cassandra:table:WriteCapacityUnits" || "kafka:broker-storage:VolumeSize" || "elasticache:replication-group:NodeGroups" || "elasticache:replication-group:Replicas" || "neptune:cluster:ReadReplicaCount" || "sagemaker:variant:DesiredProvisionedConcurrency" || "sagemaker:inference-component:DesiredCopyCount" || "workspaces:workspacespool:DesiredUserSessions", // required
65-
* // PolicyType: "StepScaling" || "TargetTrackingScaling", // required
65+
* // PolicyType: "StepScaling" || "TargetTrackingScaling" || "PredictiveScaling", // required
6666
* // StepScalingPolicyConfiguration: { // StepScalingPolicyConfiguration
6767
* // AdjustmentType: "ChangeInCapacity" || "PercentChangeInCapacity" || "ExactCapacity",
6868
* // StepAdjustments: [ // StepAdjustments
@@ -120,6 +120,101 @@ export interface DescribeScalingPoliciesCommandOutput extends DescribeScalingPol
120120
* // ScaleInCooldown: Number("int"),
121121
* // DisableScaleIn: true || false,
122122
* // },
123+
* // PredictiveScalingPolicyConfiguration: { // PredictiveScalingPolicyConfiguration
124+
* // MetricSpecifications: [ // PredictiveScalingMetricSpecifications // required
125+
* // { // PredictiveScalingMetricSpecification
126+
* // TargetValue: Number("double"), // required
127+
* // PredefinedMetricPairSpecification: { // PredictiveScalingPredefinedMetricPairSpecification
128+
* // PredefinedMetricType: "STRING_VALUE", // required
129+
* // ResourceLabel: "STRING_VALUE",
130+
* // },
131+
* // PredefinedScalingMetricSpecification: { // PredictiveScalingPredefinedScalingMetricSpecification
132+
* // PredefinedMetricType: "STRING_VALUE", // required
133+
* // ResourceLabel: "STRING_VALUE",
134+
* // },
135+
* // PredefinedLoadMetricSpecification: { // PredictiveScalingPredefinedLoadMetricSpecification
136+
* // PredefinedMetricType: "STRING_VALUE", // required
137+
* // ResourceLabel: "STRING_VALUE",
138+
* // },
139+
* // CustomizedScalingMetricSpecification: { // PredictiveScalingCustomizedMetricSpecification
140+
* // MetricDataQueries: [ // PredictiveScalingMetricDataQueries // required
141+
* // { // PredictiveScalingMetricDataQuery
142+
* // Id: "STRING_VALUE", // required
143+
* // Expression: "STRING_VALUE",
144+
* // MetricStat: { // PredictiveScalingMetricStat
145+
* // Metric: { // PredictiveScalingMetric
146+
* // Dimensions: [ // PredictiveScalingMetricDimensions
147+
* // { // PredictiveScalingMetricDimension
148+
* // Name: "STRING_VALUE", // required
149+
* // Value: "STRING_VALUE", // required
150+
* // },
151+
* // ],
152+
* // MetricName: "STRING_VALUE",
153+
* // Namespace: "STRING_VALUE",
154+
* // },
155+
* // Stat: "STRING_VALUE", // required
156+
* // Unit: "STRING_VALUE",
157+
* // },
158+
* // Label: "STRING_VALUE",
159+
* // ReturnData: true || false,
160+
* // },
161+
* // ],
162+
* // },
163+
* // CustomizedLoadMetricSpecification: {
164+
* // MetricDataQueries: [ // required
165+
* // {
166+
* // Id: "STRING_VALUE", // required
167+
* // Expression: "STRING_VALUE",
168+
* // MetricStat: {
169+
* // Metric: {
170+
* // Dimensions: [
171+
* // {
172+
* // Name: "STRING_VALUE", // required
173+
* // Value: "STRING_VALUE", // required
174+
* // },
175+
* // ],
176+
* // MetricName: "STRING_VALUE",
177+
* // Namespace: "STRING_VALUE",
178+
* // },
179+
* // Stat: "STRING_VALUE", // required
180+
* // Unit: "STRING_VALUE",
181+
* // },
182+
* // Label: "STRING_VALUE",
183+
* // ReturnData: true || false,
184+
* // },
185+
* // ],
186+
* // },
187+
* // CustomizedCapacityMetricSpecification: {
188+
* // MetricDataQueries: [ // required
189+
* // {
190+
* // Id: "STRING_VALUE", // required
191+
* // Expression: "STRING_VALUE",
192+
* // MetricStat: {
193+
* // Metric: {
194+
* // Dimensions: [
195+
* // {
196+
* // Name: "STRING_VALUE", // required
197+
* // Value: "STRING_VALUE", // required
198+
* // },
199+
* // ],
200+
* // MetricName: "STRING_VALUE",
201+
* // Namespace: "STRING_VALUE",
202+
* // },
203+
* // Stat: "STRING_VALUE", // required
204+
* // Unit: "STRING_VALUE",
205+
* // },
206+
* // Label: "STRING_VALUE",
207+
* // ReturnData: true || false,
208+
* // },
209+
* // ],
210+
* // },
211+
* // },
212+
* // ],
213+
* // Mode: "ForecastOnly" || "ForecastAndScale",
214+
* // SchedulingBufferTime: Number("int"),
215+
* // MaxCapacityBreachBehavior: "HonorMaxCapacity" || "IncreaseMaxCapacity",
216+
* // MaxCapacityBuffer: Number("int"),
217+
* // },
123218
* // Alarms: [ // Alarms
124219
* // { // Alarm
125220
* // AlarmName: "STRING_VALUE", // required

0 commit comments

Comments
 (0)