Skip to content

Commit 2392739

Browse files
author
awstools
committed
feat(client-auto-scaling): Adds bake time for Auto Scaling group Instance Refresh
1 parent 2f50238 commit 2392739

File tree

6 files changed

+50
-4
lines changed

6 files changed

+50
-4
lines changed

clients/client-auto-scaling/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ based on user-defined scaling policies, scheduled actions, and health checks.</p
1414

1515
## Installing
1616

17-
To install the this package, simply type add or install @aws-sdk/client-auto-scaling
17+
To install this package, simply type add or install @aws-sdk/client-auto-scaling
1818
using your favorite package manager:
1919

2020
- `npm install @aws-sdk/client-auto-scaling`

clients/client-auto-scaling/src/commands/DescribeInstanceRefreshesCommand.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ export interface DescribeInstanceRefreshesCommandOutput extends DescribeInstance
6060
* // { // InstanceRefresh
6161
* // InstanceRefreshId: "STRING_VALUE",
6262
* // AutoScalingGroupName: "STRING_VALUE",
63-
* // Status: "Pending" || "InProgress" || "Successful" || "Failed" || "Cancelling" || "Cancelled" || "RollbackInProgress" || "RollbackFailed" || "RollbackSuccessful",
63+
* // Status: "Pending" || "InProgress" || "Successful" || "Failed" || "Cancelling" || "Cancelled" || "RollbackInProgress" || "RollbackFailed" || "RollbackSuccessful" || "Baking",
6464
* // StatusReason: "STRING_VALUE",
6565
* // StartTime: new Date("TIMESTAMP"),
6666
* // EndTime: new Date("TIMESTAMP"),
@@ -93,6 +93,7 @@ export interface DescribeInstanceRefreshesCommandOutput extends DescribeInstance
9393
* // ],
9494
* // },
9595
* // MaxHealthyPercentage: Number("int"),
96+
* // BakeTime: Number("int"),
9697
* // },
9798
* // DesiredConfiguration: { // DesiredConfiguration
9899
* // LaunchTemplate: { // LaunchTemplateSpecification

clients/client-auto-scaling/src/commands/StartInstanceRefreshCommand.ts

+1
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,7 @@ export interface StartInstanceRefreshCommandOutput extends StartInstanceRefreshA
177177
* ],
178178
* },
179179
* MaxHealthyPercentage: Number("int"),
180+
* BakeTime: Number("int"),
180181
* },
181182
* };
182183
* const command = new StartInstanceRefreshCommand(input);

clients/client-auto-scaling/src/models/models_0.ts

+16
Original file line numberDiff line numberDiff line change
@@ -3880,6 +3880,14 @@ export interface RefreshPreferences {
38803880
* @public
38813881
*/
38823882
MaxHealthyPercentage?: number;
3883+
3884+
/**
3885+
* <p>
3886+
* The amount of time, in seconds, to wait at the end of an instance refresh before the instance refresh is considered complete.
3887+
* </p>
3888+
* @public
3889+
*/
3890+
BakeTime?: number;
38833891
}
38843892

38853893
/**
@@ -3992,6 +4000,7 @@ export interface RollbackDetails {
39924000
* @enum
39934001
*/
39944002
export const InstanceRefreshStatus = {
4003+
Baking: "Baking",
39954004
Cancelled: "Cancelled",
39964005
Cancelling: "Cancelling",
39974006
Failed: "Failed",
@@ -4069,6 +4078,10 @@ export interface InstanceRefresh {
40694078
* <p>
40704079
* <code>RollbackSuccessful</code> - The rollback completed successfully.</p>
40714080
* </li>
4081+
* <li>
4082+
* <p>
4083+
* <code>Baking</code> - Waiting the specified bake time after an instance refresh has finished updating instances.</p>
4084+
* </li>
40724085
* </ul>
40734086
* @public
40744087
*/
@@ -7977,6 +7990,9 @@ export interface StartInstanceRefreshType {
79777990
* <li>
79787991
* <p>Skip matching</p>
79797992
* </li>
7993+
* <li>
7994+
* <p>Bake time</p>
7995+
* </li>
79807996
* </ul>
79817997
* @public
79827998
*/

clients/client-auto-scaling/src/protocols/Aws_query.ts

+7
Original file line numberDiff line numberDiff line change
@@ -5780,6 +5780,9 @@ const se_RefreshPreferences = (input: RefreshPreferences, context: __SerdeContex
57805780
if (input[_MHPa] != null) {
57815781
entries[_MHPa] = input[_MHPa];
57825782
}
5783+
if (input[_BTa] != null) {
5784+
entries[_BTa] = input[_BTa];
5785+
}
57835786
return entries;
57845787
};
57855788

@@ -8796,6 +8799,9 @@ const de_RefreshPreferences = (output: any, context: __SerdeContext): RefreshPre
87968799
if (output[_MHPa] != null) {
87978800
contents[_MHPa] = __strictParseInt32(output[_MHPa]) as number;
87988801
}
8802+
if (output[_BTa] != null) {
8803+
contents[_BTa] = __strictParseInt32(output[_BTa]) as number;
8804+
}
87998805
return contents;
88008806
};
88018807

@@ -9430,6 +9436,7 @@ const _BM = "BareMetal";
94309436
const _BP = "BurstablePerformance";
94319437
const _BPSUGA = "BatchPutScheduledUpdateGroupAction";
94329438
const _BT = "BreachThreshold";
9439+
const _BTa = "BakeTime";
94339440
const _C = "Context";
94349441
const _CASG = "CreateAutoScalingGroup";
94359442
const _CCMS = "CustomizedCapacityMetricSpecification";

codegen/sdk-codegen/aws-models/auto-scaling.json

+23-2
Original file line numberDiff line numberDiff line change
@@ -2305,6 +2305,15 @@
23052305
"target": "com.amazonaws.autoscaling#XmlStringMaxLen255"
23062306
}
23072307
},
2308+
"com.amazonaws.autoscaling#BakeTime": {
2309+
"type": "integer",
2310+
"traits": {
2311+
"smithy.api#range": {
2312+
"min": 0,
2313+
"max": 172800
2314+
}
2315+
}
2316+
},
23082317
"com.amazonaws.autoscaling#BareMetal": {
23092318
"type": "enum",
23102319
"members": {
@@ -6409,7 +6418,7 @@
64096418
"Status": {
64106419
"target": "com.amazonaws.autoscaling#InstanceRefreshStatus",
64116420
"traits": {
6412-
"smithy.api#documentation": "<p>The current status for the instance refresh operation:</p>\n <ul>\n <li>\n <p>\n <code>Pending</code> - The request was created, but the instance refresh has\n not started.</p>\n </li>\n <li>\n <p>\n <code>InProgress</code> - An instance refresh is in progress.</p>\n </li>\n <li>\n <p>\n <code>Successful</code> - An instance refresh completed successfully.</p>\n </li>\n <li>\n <p>\n <code>Failed</code> - An instance refresh failed to complete. You can\n troubleshoot using the status reason and the scaling activities. </p>\n </li>\n <li>\n <p>\n <code>Cancelling</code> - An ongoing instance refresh is being\n cancelled.</p>\n </li>\n <li>\n <p>\n <code>Cancelled</code> - The instance refresh is cancelled. </p>\n </li>\n <li>\n <p>\n <code>RollbackInProgress</code> - An instance refresh is being rolled\n back.</p>\n </li>\n <li>\n <p>\n <code>RollbackFailed</code> - The rollback failed to complete. You can\n troubleshoot using the status reason and the scaling activities.</p>\n </li>\n <li>\n <p>\n <code>RollbackSuccessful</code> - The rollback completed successfully.</p>\n </li>\n </ul>"
6421+
"smithy.api#documentation": "<p>The current status for the instance refresh operation:</p>\n <ul>\n <li>\n <p>\n <code>Pending</code> - The request was created, but the instance refresh has\n not started.</p>\n </li>\n <li>\n <p>\n <code>InProgress</code> - An instance refresh is in progress.</p>\n </li>\n <li>\n <p>\n <code>Successful</code> - An instance refresh completed successfully.</p>\n </li>\n <li>\n <p>\n <code>Failed</code> - An instance refresh failed to complete. You can\n troubleshoot using the status reason and the scaling activities. </p>\n </li>\n <li>\n <p>\n <code>Cancelling</code> - An ongoing instance refresh is being\n cancelled.</p>\n </li>\n <li>\n <p>\n <code>Cancelled</code> - The instance refresh is cancelled. </p>\n </li>\n <li>\n <p>\n <code>RollbackInProgress</code> - An instance refresh is being rolled\n back.</p>\n </li>\n <li>\n <p>\n <code>RollbackFailed</code> - The rollback failed to complete. You can\n troubleshoot using the status reason and the scaling activities.</p>\n </li>\n <li>\n <p>\n <code>RollbackSuccessful</code> - The rollback completed successfully.</p>\n </li>\n <li>\n <p>\n <code>Baking</code> - Waiting the specified bake time after an instance refresh has finished updating instances.</p>\n </li>\n </ul>"
64136422
}
64146423
},
64156424
"StatusReason": {
@@ -6590,6 +6599,12 @@
65906599
"traits": {
65916600
"smithy.api#enumValue": "RollbackSuccessful"
65926601
}
6602+
},
6603+
"Baking": {
6604+
"target": "smithy.api#Unit",
6605+
"traits": {
6606+
"smithy.api#enumValue": "Baking"
6607+
}
65936608
}
65946609
}
65956610
},
@@ -9274,6 +9289,12 @@
92749289
"traits": {
92759290
"smithy.api#documentation": "<p>Specifies the maximum percentage of the group that can be in service and healthy, or\n pending, to support your workload when replacing instances. The value is expressed as a\n percentage of the desired capacity of the Auto Scaling group. Value range is 100 to 200.</p>\n <p>If you specify <code>MaxHealthyPercentage</code>, you must also specify\n <code>MinHealthyPercentage</code>, and the difference between them cannot be greater\n than 100. A larger range increases the number of instances that can be replaced at the\n same time.</p>\n <p>If you do not specify this property, the default is 100 percent, or the percentage set\n in the instance maintenance policy for the Auto Scaling group, if defined.</p>"
92769291
}
9292+
},
9293+
"BakeTime": {
9294+
"target": "com.amazonaws.autoscaling#BakeTime",
9295+
"traits": {
9296+
"smithy.api#documentation": "<p>\n The amount of time, in seconds, to wait at the end of an instance refresh before the instance refresh is considered complete.\n </p>"
9297+
}
92779298
}
92789299
},
92799300
"traits": {
@@ -10229,7 +10250,7 @@
1022910250
"Preferences": {
1023010251
"target": "com.amazonaws.autoscaling#RefreshPreferences",
1023110252
"traits": {
10232-
"smithy.api#documentation": "<p>Sets your preferences for the instance refresh so that it performs as expected when\n you start it. Includes the instance warmup time, the minimum and maximum healthy\n percentages, and the behaviors that you want Amazon EC2 Auto Scaling to use if instances that are in\n <code>Standby</code> state or protected from scale in are found. You can also choose\n to enable additional features, such as the following:</p>\n <ul>\n <li>\n <p>Auto rollback</p>\n </li>\n <li>\n <p>Checkpoints</p>\n </li>\n <li>\n <p>CloudWatch alarms</p>\n </li>\n <li>\n <p>Skip matching</p>\n </li>\n </ul>"
10253+
"smithy.api#documentation": "<p>Sets your preferences for the instance refresh so that it performs as expected when\n you start it. Includes the instance warmup time, the minimum and maximum healthy\n percentages, and the behaviors that you want Amazon EC2 Auto Scaling to use if instances that are in\n <code>Standby</code> state or protected from scale in are found. You can also choose\n to enable additional features, such as the following:</p>\n <ul>\n <li>\n <p>Auto rollback</p>\n </li>\n <li>\n <p>Checkpoints</p>\n </li>\n <li>\n <p>CloudWatch alarms</p>\n </li>\n <li>\n <p>Skip matching</p>\n </li>\n <li>\n <p>Bake time</p>\n </li>\n </ul>"
1023310254
}
1023410255
}
1023510256
}

0 commit comments

Comments
 (0)