Skip to content

Commit 2f67543

Browse files
author
awstools
committed
feat(client-compute-optimizer): This release enables AWS Compute Optimizer to analyze and generate recommendations with a new customization preference, Memory Utilization.
1 parent 539621d commit 2f67543

File tree

7 files changed

+68
-28
lines changed

7 files changed

+68
-28
lines changed

clients/client-compute-optimizer/src/commands/GetAutoScalingGroupRecommendationsCommand.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,10 +149,10 @@ export interface GetAutoScalingGroupRecommendationsCommandOutput
149149
* // lookBackPeriod: "DAYS_14" || "DAYS_32" || "DAYS_93",
150150
* // utilizationPreferences: [ // UtilizationPreferences
151151
* // { // UtilizationPreference
152-
* // metricName: "CpuUtilization",
152+
* // metricName: "CpuUtilization" || "MemoryUtilization",
153153
* // metricParameters: { // CustomizableMetricParameters
154154
* // threshold: "P90" || "P95" || "P99_5",
155-
* // headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_0",
155+
* // headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_10" || "PERCENT_0",
156156
* // },
157157
* // },
158158
* // ],

clients/client-compute-optimizer/src/commands/GetEC2InstanceRecommendationsCommand.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,10 +148,10 @@ export interface GetEC2InstanceRecommendationsCommandOutput
148148
* // lookBackPeriod: "DAYS_14" || "DAYS_32" || "DAYS_93",
149149
* // utilizationPreferences: [ // UtilizationPreferences
150150
* // { // UtilizationPreference
151-
* // metricName: "CpuUtilization",
151+
* // metricName: "CpuUtilization" || "MemoryUtilization",
152152
* // metricParameters: { // CustomizableMetricParameters
153153
* // threshold: "P90" || "P95" || "P99_5",
154-
* // headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_0",
154+
* // headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_10" || "PERCENT_0",
155155
* // },
156156
* // },
157157
* // ],

clients/client-compute-optimizer/src/commands/GetEffectiveRecommendationPreferencesCommand.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,10 @@ export interface GetEffectiveRecommendationPreferencesCommandOutput
6161
* // lookBackPeriod: "DAYS_14" || "DAYS_32" || "DAYS_93",
6262
* // utilizationPreferences: [ // UtilizationPreferences
6363
* // { // UtilizationPreference
64-
* // metricName: "CpuUtilization",
64+
* // metricName: "CpuUtilization" || "MemoryUtilization",
6565
* // metricParameters: { // CustomizableMetricParameters
6666
* // threshold: "P90" || "P95" || "P99_5",
67-
* // headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_0",
67+
* // headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_10" || "PERCENT_0",
6868
* // },
6969
* // },
7070
* // ],

clients/client-compute-optimizer/src/commands/GetRecommendationPreferencesCommand.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,10 @@ export interface GetRecommendationPreferencesCommandOutput
7474
* // lookBackPeriod: "DAYS_14" || "DAYS_32" || "DAYS_93",
7575
* // utilizationPreferences: [ // UtilizationPreferences
7676
* // { // UtilizationPreference
77-
* // metricName: "CpuUtilization",
77+
* // metricName: "CpuUtilization" || "MemoryUtilization",
7878
* // metricParameters: { // CustomizableMetricParameters
7979
* // threshold: "P90" || "P95" || "P99_5",
80-
* // headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_0",
80+
* // headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_10" || "PERCENT_0",
8181
* // },
8282
* // },
8383
* // ],

clients/client-compute-optimizer/src/commands/PutRecommendationPreferencesCommand.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,10 @@ export interface PutRecommendationPreferencesCommandOutput
5757
* lookBackPeriod: "DAYS_14" || "DAYS_32" || "DAYS_93",
5858
* utilizationPreferences: [ // UtilizationPreferences
5959
* { // UtilizationPreference
60-
* metricName: "CpuUtilization",
60+
* metricName: "CpuUtilization" || "MemoryUtilization",
6161
* metricParameters: { // CustomizableMetricParameters
6262
* threshold: "P90" || "P95" || "P99_5",
63-
* headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_0",
63+
* headroom: "PERCENT_30" || "PERCENT_20" || "PERCENT_10" || "PERCENT_0",
6464
* },
6565
* },
6666
* ],

clients/client-compute-optimizer/src/models/models_0.ts

Lines changed: 39 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -395,6 +395,7 @@ export interface InstanceSavingsEstimationMode {
395395
*/
396396
export const CustomizableMetricName = {
397397
CPU_UTILIZATION: "CpuUtilization",
398+
MEMORY_UTILIZATION: "MemoryUtilization",
398399
} as const;
399400

400401
/**
@@ -408,6 +409,7 @@ export type CustomizableMetricName = (typeof CustomizableMetricName)[keyof typeo
408409
*/
409410
export const CustomizableMetricHeadroom = {
410411
PERCENT_0: "PERCENT_0",
412+
PERCENT_10: "PERCENT_10",
411413
PERCENT_20: "PERCENT_20",
412414
PERCENT_30: "PERCENT_30",
413415
} as const;
@@ -444,14 +446,28 @@ export interface CustomizableMetricParameters {
444446
* <p>
445447
* The threshold value used for the specified metric parameter.
446448
* </p>
449+
* <note>
450+
* <p>You can only specify the threshold value for CPU utilization.</p>
451+
* </note>
447452
* @public
448453
*/
449454
threshold?: CustomizableMetricThreshold;
450455

451456
/**
452457
* <p>
453-
* The headroom threshold value in percentage used for the specified metric parameter.
458+
* The headroom value in percentage used for the specified metric parameter.
454459
* </p>
460+
* <p>The following lists the valid values for CPU and memory utilization.</p>
461+
* <ul>
462+
* <li>
463+
* <p>CPU utilization: <code>PERCENT_30 | PERCENT_20 | PERCENT_0</code>
464+
* </p>
465+
* </li>
466+
* <li>
467+
* <p>Memory utilization: <code>PERCENT_30 | PERCENT_20 | PERCENT_10</code>
468+
* </p>
469+
* </li>
470+
* </ul>
455471
* @public
456472
*/
457473
headroom?: CustomizableMetricHeadroom;
@@ -471,9 +487,6 @@ export interface UtilizationPreference {
471487
* <p>
472488
* The name of the resource utilization metric name to customize.
473489
* </p>
474-
* <note>
475-
* <p>Compute Optimizer only supports <code>CpuUtilization</code>.</p>
476-
* </note>
477490
* @public
478491
*/
479492
metricName?: CustomizableMetricName;
@@ -555,7 +568,7 @@ export interface EffectiveRecommendationPreferences {
555568

556569
/**
557570
* <p>
558-
* The resource’s CPU utilization threshold preferences, such as threshold and headroom, that
571+
* The resource’s CPU and memory utilization preferences, such as threshold and headroom, that
559572
* are used to generate rightsizing recommendations.
560573
* </p>
561574
* <note>
@@ -5893,7 +5906,7 @@ export interface GetEffectiveRecommendationPreferencesResponse {
58935906

58945907
/**
58955908
* <p>
5896-
* The resource’s CPU utilization threshold preferences, such as threshold and headroom,
5909+
* The resource’s CPU and memory utilization preferences, such as threshold and headroom,
58975910
* that were used to generate rightsizing recommendations. It considers all applicable preferences
58985911
* that you set at the resource, account, and organization level.
58995912
* </p>
@@ -7194,7 +7207,7 @@ export interface RecommendationPreferencesDetail {
71947207

71957208
/**
71967209
* <p>
7197-
* The preference to control the resource’s CPU utilization thresholds - threshold and headroom.
7210+
* The preference to control the resource’s CPU utilization threshold, CPU utilization headroom, and memory utilization headroom.
71987211
* If the preference isn’t set, this object is null.
71997212
* </p>
72007213
* <note>
@@ -7648,21 +7661,36 @@ export interface PutRecommendationPreferencesRequest {
76487661

76497662
/**
76507663
* <p>
7651-
* The preference to control the resource’s CPU utilization thresholds - threshold and headroom. When this
7652-
* preference isn't specified, we use the following default values:
7664+
* The preference to control the resource’s CPU utilization threshold, CPU utilization headroom, and memory utilization headroom. When this
7665+
* preference isn't specified, we use the following default values.
76537666
* </p>
7667+
* <p>CPU utilization:</p>
76547668
* <ul>
76557669
* <li>
76567670
* <p>
76577671
* <code>P99_5</code> for threshold</p>
76587672
* </li>
76597673
* <li>
76607674
* <p>
7661-
* <code>PERCENT_17</code> for headroom</p>
7675+
* <code>PERCENT_20</code> for headroom</p>
7676+
* </li>
7677+
* </ul>
7678+
* <p>Memory utilization:</p>
7679+
* <ul>
7680+
* <li>
7681+
* <p>
7682+
* <code>PERCENT_20</code> for headroom</p>
76627683
* </li>
76637684
* </ul>
76647685
* <note>
7665-
* <p>You can only set this preference for the Amazon EC2 instance resource type.</p>
7686+
* <ul>
7687+
* <li>
7688+
* <p>You can only set CPU and memory utilization preferences for the Amazon EC2 instance resource type.</p>
7689+
* </li>
7690+
* <li>
7691+
* <p>The threshold setting isn’t available for memory utilization.</p>
7692+
* </li>
7693+
* </ul>
76667694
* </note>
76677695
* @public
76687696
*/

codegen/sdk-codegen/aws-models/compute-optimizer.json

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1480,6 +1480,12 @@
14801480
"smithy.api#enumValue": "PERCENT_20"
14811481
}
14821482
},
1483+
"PERCENT_10": {
1484+
"target": "smithy.api#Unit",
1485+
"traits": {
1486+
"smithy.api#enumValue": "PERCENT_10"
1487+
}
1488+
},
14831489
"PERCENT_0": {
14841490
"target": "smithy.api#Unit",
14851491
"traits": {
@@ -1496,6 +1502,12 @@
14961502
"traits": {
14971503
"smithy.api#enumValue": "CpuUtilization"
14981504
}
1505+
},
1506+
"MEMORY_UTILIZATION": {
1507+
"target": "smithy.api#Unit",
1508+
"traits": {
1509+
"smithy.api#enumValue": "MemoryUtilization"
1510+
}
14991511
}
15001512
}
15011513
},
@@ -1505,13 +1517,13 @@
15051517
"threshold": {
15061518
"target": "com.amazonaws.computeoptimizer#CustomizableMetricThreshold",
15071519
"traits": {
1508-
"smithy.api#documentation": "<p>\n The threshold value used for the specified metric parameter.\n </p>"
1520+
"smithy.api#documentation": "<p>\n The threshold value used for the specified metric parameter.\n </p>\n <note>\n <p>You can only specify the threshold value for CPU utilization.</p>\n </note>"
15091521
}
15101522
},
15111523
"headroom": {
15121524
"target": "com.amazonaws.computeoptimizer#CustomizableMetricHeadroom",
15131525
"traits": {
1514-
"smithy.api#documentation": "<p>\n The headroom threshold value in percentage used for the specified metric parameter.\n </p>"
1526+
"smithy.api#documentation": "<p>\n The headroom value in percentage used for the specified metric parameter.\n </p>\n <p>The following lists the valid values for CPU and memory utilization.</p>\n <ul>\n <li>\n <p>CPU utilization: <code>PERCENT_30 | PERCENT_20 | PERCENT_0</code>\n </p>\n </li>\n <li>\n <p>Memory utilization: <code>PERCENT_30 | PERCENT_20 | PERCENT_10</code>\n </p>\n </li>\n </ul>"
15151527
}
15161528
}
15171529
},
@@ -2539,7 +2551,7 @@
25392551
"utilizationPreferences": {
25402552
"target": "com.amazonaws.computeoptimizer#UtilizationPreferences",
25412553
"traits": {
2542-
"smithy.api#documentation": "<p>\n The resource’s CPU utilization threshold preferences, such as threshold and headroom, that \n are used to generate rightsizing recommendations. \n </p>\n <note>\n <p>This preference is only available for the Amazon EC2 instance resource type.</p>\n </note>"
2554+
"smithy.api#documentation": "<p>\n The resource’s CPU and memory utilization preferences, such as threshold and headroom, that \n are used to generate rightsizing recommendations. \n </p>\n <note>\n <p>This preference is only available for the Amazon EC2 instance resource type.</p>\n </note>"
25432555
}
25442556
},
25452557
"preferredResources": {
@@ -5811,7 +5823,7 @@
58115823
"utilizationPreferences": {
58125824
"target": "com.amazonaws.computeoptimizer#UtilizationPreferences",
58135825
"traits": {
5814-
"smithy.api#documentation": "<p>\n The resource’s CPU utilization threshold preferences, such as threshold and headroom, \n that were used to generate rightsizing recommendations. It considers all applicable preferences \n that you set at the resource, account, and organization level.\n </p>\n <p>To validate that the preference is applied to your last generated set of recommendations, review the \n <code>effectiveRecommendationPreferences</code> value in the response of the \n GetAutoScalingGroupRecommendations or GetEC2InstanceRecommendations actions.</p>"
5826+
"smithy.api#documentation": "<p>\n The resource’s CPU and memory utilization preferences, such as threshold and headroom, \n that were used to generate rightsizing recommendations. It considers all applicable preferences \n that you set at the resource, account, and organization level.\n </p>\n <p>To validate that the preference is applied to your last generated set of recommendations, review the \n <code>effectiveRecommendationPreferences</code> value in the response of the \n GetAutoScalingGroupRecommendations or GetEC2InstanceRecommendations actions.</p>"
58155827
}
58165828
},
58175829
"preferredResources": {
@@ -8591,7 +8603,7 @@
85918603
"utilizationPreferences": {
85928604
"target": "com.amazonaws.computeoptimizer#UtilizationPreferences",
85938605
"traits": {
8594-
"smithy.api#documentation": "<p>\n The preference to control the resource’s CPU utilization thresholds - threshold and headroom. When this \n preference isn't specified, we use the following default values:\n </p>\n <ul>\n <li>\n <p>\n <code>P99_5</code> for threshold</p>\n </li>\n <li>\n <p>\n <code>PERCENT_17</code> for headroom</p>\n </li>\n </ul>\n <note>\n <p>You can only set this preference for the Amazon EC2 instance resource type.</p>\n </note>"
8606+
"smithy.api#documentation": "<p>\n The preference to control the resource’s CPU utilization threshold, CPU utilization headroom, and memory utilization headroom. When this \n preference isn't specified, we use the following default values.\n </p>\n <p>CPU utilization:</p>\n <ul>\n <li>\n <p>\n <code>P99_5</code> for threshold</p>\n </li>\n <li>\n <p>\n <code>PERCENT_20</code> for headroom</p>\n </li>\n </ul>\n <p>Memory utilization:</p>\n <ul>\n <li>\n <p>\n <code>PERCENT_20</code> for headroom</p>\n </li>\n </ul>\n <note>\n <ul>\n <li>\n <p>You can only set CPU and memory utilization preferences for the Amazon EC2 instance resource type.</p>\n </li>\n <li>\n <p>The threshold setting isn’t available for memory utilization.</p>\n </li>\n </ul>\n </note>"
85958607
}
85968608
},
85978609
"preferredResources": {
@@ -8816,7 +8828,7 @@
88168828
"utilizationPreferences": {
88178829
"target": "com.amazonaws.computeoptimizer#UtilizationPreferences",
88188830
"traits": {
8819-
"smithy.api#documentation": "<p>\n The preference to control the resource’s CPU utilization thresholds - threshold and headroom. \n If the preference isn’t set, this object is null. \n </p>\n <note>\n <p>This preference is only available for the Amazon EC2 instance resource type.</p>\n </note>"
8831+
"smithy.api#documentation": "<p>\n The preference to control the resource’s CPU utilization threshold, CPU utilization headroom, and memory utilization headroom. \n If the preference isn’t set, this object is null. \n </p>\n <note>\n <p>This preference is only available for the Amazon EC2 instance resource type.</p>\n </note>"
88208832
}
88218833
},
88228834
"preferredResources": {
@@ -9516,7 +9528,7 @@
95169528
"metricName": {
95179529
"target": "com.amazonaws.computeoptimizer#CustomizableMetricName",
95189530
"traits": {
9519-
"smithy.api#documentation": "<p>\n The name of the resource utilization metric name to customize. \n </p>\n <note>\n <p>Compute Optimizer only supports <code>CpuUtilization</code>.</p>\n </note>"
9531+
"smithy.api#documentation": "<p>\n The name of the resource utilization metric name to customize. \n </p>"
95209532
}
95219533
},
95229534
"metricParameters": {

0 commit comments

Comments
 (0)