aws-sdk-computeoptimizer 1.10.0 → 1.11.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 498e8b38dc082c018f02d93d8d850aea61628741f4a8761e9a7e09a971e7b348
4
- data.tar.gz: 8f94fcd7017e18944848f5690f9e124c9224b127dfc20680c6586575dadd91e2
3
+ metadata.gz: ce32447ca02d8fc55afbba45f86ffdb02f1e18774b2b3ca1e886f3fc3c58a0ba
4
+ data.tar.gz: cfc68d88d95fc97114972736c8c10129cfbba90dceef2196a076905c83c536b6
5
5
  SHA512:
6
- metadata.gz: be632931c4103d2323a6914c0bbfd7d03c6faeda70861ed11036f472aaf6456463ba8b9605435e769798dea7613562b7c8cd53e5154377c085ba1a6f96326cbf
7
- data.tar.gz: ed6bffbc0d018c6b78281bc3505d47741623189b1c8c76e81c180f27bede1c0065747825b423897b617f9d8a1f5b7d29dddb6148bd08787816e0ccf1e4269be3
6
+ metadata.gz: 627c0334f8b33ff1a20d27945fdee665f41939c90e878c422d58af268a684f16a5e2cb8f81b541857c483dda6f0c48f1d68d1fdbe0b31c9db8562668a9114c87
7
+ data.tar.gz: 121ada2a5c8fef83a676bb80763d691054512a6fdbde093a92076d0c7e35cc860f2a0e79ed8c0140422b6cde854f7dad5aa32ef9ac3635d33a0e89578132b5c7
@@ -48,6 +48,6 @@ require_relative 'aws-sdk-computeoptimizer/customizations'
48
48
  # @!group service
49
49
  module Aws::ComputeOptimizer
50
50
 
51
- GEM_VERSION = '1.10.0'
51
+ GEM_VERSION = '1.11.0'
52
52
 
53
53
  end
@@ -943,7 +943,7 @@ module Aws::ComputeOptimizer
943
943
  # resp.instance_recommendations[0].recommendation_options[0].rank #=> Integer
944
944
  # resp.instance_recommendations[0].recommendation_sources #=> Array
945
945
  # resp.instance_recommendations[0].recommendation_sources[0].recommendation_source_arn #=> String
946
- # resp.instance_recommendations[0].recommendation_sources[0].recommendation_source_type #=> String, one of "Ec2Instance", "AutoScalingGroup", "EbsVolume"
946
+ # resp.instance_recommendations[0].recommendation_sources[0].recommendation_source_type #=> String, one of "Ec2Instance", "AutoScalingGroup", "EbsVolume", "LambdaFunction"
947
947
  # resp.instance_recommendations[0].last_refresh_timestamp #=> Time
948
948
  # resp.errors #=> Array
949
949
  # resp.errors[0].identifier #=> String
@@ -1053,6 +1053,112 @@ module Aws::ComputeOptimizer
1053
1053
  req.send_request(options)
1054
1054
  end
1055
1055
 
1056
+ # Returns AWS Lambda function recommendations.
1057
+ #
1058
+ # AWS Compute Optimizer generates recommendations for functions that
1059
+ # meet a specific set of requirements. For more information, see the
1060
+ # [Supported resources and requirements][1] in the *AWS Compute
1061
+ # Optimizer User Guide*.
1062
+ #
1063
+ #
1064
+ #
1065
+ # [1]: https://docs.aws.amazon.com/compute-optimizer/latest/ug/requirements.html
1066
+ #
1067
+ # @option params [Array<String>] :function_arns
1068
+ # The Amazon Resource Name (ARN) of the functions for which to return
1069
+ # recommendations.
1070
+ #
1071
+ # You can specify a qualified or unqualified ARN. If you specify an
1072
+ # unqualified ARN without a function version suffix, Compute Optimizer
1073
+ # will return recommendations for the latest (`$LATEST`) version of the
1074
+ # function. If you specify a qualified ARN with a version suffix,
1075
+ # Compute Optimizer will return recommendations for the specified
1076
+ # function version. For more information about using function versions,
1077
+ # see [Using versions][1] in the *AWS Lambda Developer Guide*.
1078
+ #
1079
+ #
1080
+ #
1081
+ # [1]: https://docs.aws.amazon.com/lambda/latest/dg/configuration-versions.html#versioning-versions-using
1082
+ #
1083
+ # @option params [Array<String>] :account_ids
1084
+ # The IDs of the AWS accounts for which to return function
1085
+ # recommendations.
1086
+ #
1087
+ # If your account is the management account of an organization, use this
1088
+ # parameter to specify the member accounts for which you want to return
1089
+ # function recommendations.
1090
+ #
1091
+ # Only one account ID can be specified per request.
1092
+ #
1093
+ # @option params [Array<Types::LambdaFunctionRecommendationFilter>] :filters
1094
+ # An array of objects that describe a filter that returns a more
1095
+ # specific list of function recommendations.
1096
+ #
1097
+ # @option params [String] :next_token
1098
+ # The token to advance to the next page of function recommendations.
1099
+ #
1100
+ # @option params [Integer] :max_results
1101
+ # The maximum number of function recommendations to return with a single
1102
+ # request.
1103
+ #
1104
+ # To retrieve the remaining results, make another request with the
1105
+ # returned `NextToken` value.
1106
+ #
1107
+ # @return [Types::GetLambdaFunctionRecommendationsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
1108
+ #
1109
+ # * {Types::GetLambdaFunctionRecommendationsResponse#next_token #next_token} => String
1110
+ # * {Types::GetLambdaFunctionRecommendationsResponse#lambda_function_recommendations #lambda_function_recommendations} => Array&lt;Types::LambdaFunctionRecommendation&gt;
1111
+ #
1112
+ # @example Request syntax with placeholder values
1113
+ #
1114
+ # resp = client.get_lambda_function_recommendations({
1115
+ # function_arns: ["FunctionArn"],
1116
+ # account_ids: ["AccountId"],
1117
+ # filters: [
1118
+ # {
1119
+ # name: "Finding", # accepts Finding, FindingReasonCode
1120
+ # values: ["FilterValue"],
1121
+ # },
1122
+ # ],
1123
+ # next_token: "NextToken",
1124
+ # max_results: 1,
1125
+ # })
1126
+ #
1127
+ # @example Response structure
1128
+ #
1129
+ # resp.next_token #=> String
1130
+ # resp.lambda_function_recommendations #=> Array
1131
+ # resp.lambda_function_recommendations[0].function_arn #=> String
1132
+ # resp.lambda_function_recommendations[0].function_version #=> String
1133
+ # resp.lambda_function_recommendations[0].account_id #=> String
1134
+ # resp.lambda_function_recommendations[0].current_memory_size #=> Integer
1135
+ # resp.lambda_function_recommendations[0].number_of_invocations #=> Integer
1136
+ # resp.lambda_function_recommendations[0].utilization_metrics #=> Array
1137
+ # resp.lambda_function_recommendations[0].utilization_metrics[0].name #=> String, one of "Duration", "Memory"
1138
+ # resp.lambda_function_recommendations[0].utilization_metrics[0].statistic #=> String, one of "Maximum", "Average"
1139
+ # resp.lambda_function_recommendations[0].utilization_metrics[0].value #=> Float
1140
+ # resp.lambda_function_recommendations[0].lookback_period_in_days #=> Float
1141
+ # resp.lambda_function_recommendations[0].last_refresh_timestamp #=> Time
1142
+ # resp.lambda_function_recommendations[0].finding #=> String, one of "Optimized", "NotOptimized", "Unavailable"
1143
+ # resp.lambda_function_recommendations[0].finding_reason_codes #=> Array
1144
+ # resp.lambda_function_recommendations[0].finding_reason_codes[0] #=> String, one of "MemoryOverprovisioned", "MemoryUnderprovisioned", "InsufficientData", "Inconclusive"
1145
+ # resp.lambda_function_recommendations[0].memory_size_recommendation_options #=> Array
1146
+ # resp.lambda_function_recommendations[0].memory_size_recommendation_options[0].rank #=> Integer
1147
+ # resp.lambda_function_recommendations[0].memory_size_recommendation_options[0].memory_size #=> Integer
1148
+ # resp.lambda_function_recommendations[0].memory_size_recommendation_options[0].projected_utilization_metrics #=> Array
1149
+ # resp.lambda_function_recommendations[0].memory_size_recommendation_options[0].projected_utilization_metrics[0].name #=> String, one of "Duration"
1150
+ # resp.lambda_function_recommendations[0].memory_size_recommendation_options[0].projected_utilization_metrics[0].statistic #=> String, one of "LowerBound", "UpperBound", "Expected"
1151
+ # resp.lambda_function_recommendations[0].memory_size_recommendation_options[0].projected_utilization_metrics[0].value #=> Float
1152
+ #
1153
+ # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/GetLambdaFunctionRecommendations AWS API Documentation
1154
+ #
1155
+ # @overload get_lambda_function_recommendations(params = {})
1156
+ # @param [Hash] params ({})
1157
+ def get_lambda_function_recommendations(params = {}, options = {})
1158
+ req = build_request(:get_lambda_function_recommendations, params)
1159
+ req.send_request(options)
1160
+ end
1161
+
1056
1162
  # Returns the optimization findings for an account.
1057
1163
  #
1058
1164
  # For example, it returns the number of Amazon EC2 instances in an
@@ -1100,7 +1206,10 @@ module Aws::ComputeOptimizer
1100
1206
  # resp.recommendation_summaries[0].summaries #=> Array
1101
1207
  # resp.recommendation_summaries[0].summaries[0].name #=> String, one of "Underprovisioned", "Overprovisioned", "Optimized", "NotOptimized"
1102
1208
  # resp.recommendation_summaries[0].summaries[0].value #=> Float
1103
- # resp.recommendation_summaries[0].recommendation_resource_type #=> String, one of "Ec2Instance", "AutoScalingGroup", "EbsVolume"
1209
+ # resp.recommendation_summaries[0].summaries[0].reason_code_summaries #=> Array
1210
+ # resp.recommendation_summaries[0].summaries[0].reason_code_summaries[0].name #=> String, one of "MemoryOverprovisioned", "MemoryUnderprovisioned"
1211
+ # resp.recommendation_summaries[0].summaries[0].reason_code_summaries[0].value #=> Float
1212
+ # resp.recommendation_summaries[0].recommendation_resource_type #=> String, one of "Ec2Instance", "AutoScalingGroup", "EbsVolume", "LambdaFunction"
1104
1213
  # resp.recommendation_summaries[0].account_id #=> String
1105
1214
  #
1106
1215
  # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/GetRecommendationSummaries AWS API Documentation
@@ -1167,7 +1276,7 @@ module Aws::ComputeOptimizer
1167
1276
  params: params,
1168
1277
  config: config)
1169
1278
  context[:gem_name] = 'aws-sdk-computeoptimizer'
1170
- context[:gem_version] = '1.10.0'
1279
+ context[:gem_version] = '1.11.0'
1171
1280
  Seahorse::Client::Request.new(handlers, context)
1172
1281
  end
1173
1282
 
@@ -58,6 +58,10 @@ module Aws::ComputeOptimizer
58
58
  FilterValues = Shapes::ListShape.new(name: 'FilterValues')
59
59
  Filters = Shapes::ListShape.new(name: 'Filters')
60
60
  Finding = Shapes::StringShape.new(name: 'Finding')
61
+ FindingReasonCode = Shapes::StringShape.new(name: 'FindingReasonCode')
62
+ FunctionArn = Shapes::StringShape.new(name: 'FunctionArn')
63
+ FunctionArns = Shapes::ListShape.new(name: 'FunctionArns')
64
+ FunctionVersion = Shapes::StringShape.new(name: 'FunctionVersion')
61
65
  GetAutoScalingGroupRecommendationsRequest = Shapes::StructureShape.new(name: 'GetAutoScalingGroupRecommendationsRequest')
62
66
  GetAutoScalingGroupRecommendationsResponse = Shapes::StructureShape.new(name: 'GetAutoScalingGroupRecommendationsResponse')
63
67
  GetEBSVolumeRecommendationsRequest = Shapes::StructureShape.new(name: 'GetEBSVolumeRecommendationsRequest')
@@ -68,6 +72,8 @@ module Aws::ComputeOptimizer
68
72
  GetEC2RecommendationProjectedMetricsResponse = Shapes::StructureShape.new(name: 'GetEC2RecommendationProjectedMetricsResponse')
69
73
  GetEnrollmentStatusRequest = Shapes::StructureShape.new(name: 'GetEnrollmentStatusRequest')
70
74
  GetEnrollmentStatusResponse = Shapes::StructureShape.new(name: 'GetEnrollmentStatusResponse')
75
+ GetLambdaFunctionRecommendationsRequest = Shapes::StructureShape.new(name: 'GetLambdaFunctionRecommendationsRequest')
76
+ GetLambdaFunctionRecommendationsResponse = Shapes::StructureShape.new(name: 'GetLambdaFunctionRecommendationsResponse')
71
77
  GetRecommendationError = Shapes::StructureShape.new(name: 'GetRecommendationError')
72
78
  GetRecommendationErrors = Shapes::ListShape.new(name: 'GetRecommendationErrors')
73
79
  GetRecommendationSummariesRequest = Shapes::StructureShape.new(name: 'GetRecommendationSummariesRequest')
@@ -89,6 +95,24 @@ module Aws::ComputeOptimizer
89
95
  JobId = Shapes::StringShape.new(name: 'JobId')
90
96
  JobIds = Shapes::ListShape.new(name: 'JobIds')
91
97
  JobStatus = Shapes::StringShape.new(name: 'JobStatus')
98
+ LambdaFunctionMemoryMetricName = Shapes::StringShape.new(name: 'LambdaFunctionMemoryMetricName')
99
+ LambdaFunctionMemoryMetricStatistic = Shapes::StringShape.new(name: 'LambdaFunctionMemoryMetricStatistic')
100
+ LambdaFunctionMemoryProjectedMetric = Shapes::StructureShape.new(name: 'LambdaFunctionMemoryProjectedMetric')
101
+ LambdaFunctionMemoryProjectedMetrics = Shapes::ListShape.new(name: 'LambdaFunctionMemoryProjectedMetrics')
102
+ LambdaFunctionMemoryRecommendationOption = Shapes::StructureShape.new(name: 'LambdaFunctionMemoryRecommendationOption')
103
+ LambdaFunctionMemoryRecommendationOptions = Shapes::ListShape.new(name: 'LambdaFunctionMemoryRecommendationOptions')
104
+ LambdaFunctionMetricName = Shapes::StringShape.new(name: 'LambdaFunctionMetricName')
105
+ LambdaFunctionMetricStatistic = Shapes::StringShape.new(name: 'LambdaFunctionMetricStatistic')
106
+ LambdaFunctionRecommendation = Shapes::StructureShape.new(name: 'LambdaFunctionRecommendation')
107
+ LambdaFunctionRecommendationFilter = Shapes::StructureShape.new(name: 'LambdaFunctionRecommendationFilter')
108
+ LambdaFunctionRecommendationFilterName = Shapes::StringShape.new(name: 'LambdaFunctionRecommendationFilterName')
109
+ LambdaFunctionRecommendationFilters = Shapes::ListShape.new(name: 'LambdaFunctionRecommendationFilters')
110
+ LambdaFunctionRecommendationFinding = Shapes::StringShape.new(name: 'LambdaFunctionRecommendationFinding')
111
+ LambdaFunctionRecommendationFindingReasonCode = Shapes::StringShape.new(name: 'LambdaFunctionRecommendationFindingReasonCode')
112
+ LambdaFunctionRecommendationFindingReasonCodes = Shapes::ListShape.new(name: 'LambdaFunctionRecommendationFindingReasonCodes')
113
+ LambdaFunctionRecommendations = Shapes::ListShape.new(name: 'LambdaFunctionRecommendations')
114
+ LambdaFunctionUtilizationMetric = Shapes::StructureShape.new(name: 'LambdaFunctionUtilizationMetric')
115
+ LambdaFunctionUtilizationMetrics = Shapes::ListShape.new(name: 'LambdaFunctionUtilizationMetrics')
92
116
  LastRefreshTimestamp = Shapes::TimestampShape.new(name: 'LastRefreshTimestamp')
93
117
  LastUpdatedTimestamp = Shapes::TimestampShape.new(name: 'LastUpdatedTimestamp')
94
118
  LimitExceededException = Shapes::StructureShape.new(name: 'LimitExceededException')
@@ -96,6 +120,7 @@ module Aws::ComputeOptimizer
96
120
  MaxResults = Shapes::IntegerShape.new(name: 'MaxResults')
97
121
  MaxSize = Shapes::IntegerShape.new(name: 'MaxSize')
98
122
  MemberAccountsEnrolled = Shapes::BooleanShape.new(name: 'MemberAccountsEnrolled')
123
+ MemorySize = Shapes::IntegerShape.new(name: 'MemorySize')
99
124
  Message = Shapes::StringShape.new(name: 'Message')
100
125
  MetadataKey = Shapes::StringShape.new(name: 'MetadataKey')
101
126
  MetricName = Shapes::StringShape.new(name: 'MetricName')
@@ -105,6 +130,7 @@ module Aws::ComputeOptimizer
105
130
  MinSize = Shapes::IntegerShape.new(name: 'MinSize')
106
131
  MissingAuthenticationToken = Shapes::StructureShape.new(name: 'MissingAuthenticationToken')
107
132
  NextToken = Shapes::StringShape.new(name: 'NextToken')
133
+ NumberOfInvocations = Shapes::IntegerShape.new(name: 'NumberOfInvocations')
108
134
  OptInRequiredException = Shapes::StructureShape.new(name: 'OptInRequiredException')
109
135
  PerformanceRisk = Shapes::FloatShape.new(name: 'PerformanceRisk')
110
136
  Period = Shapes::IntegerShape.new(name: 'Period')
@@ -112,6 +138,8 @@ module Aws::ComputeOptimizer
112
138
  ProjectedMetrics = Shapes::ListShape.new(name: 'ProjectedMetrics')
113
139
  ProjectedUtilizationMetrics = Shapes::ListShape.new(name: 'ProjectedUtilizationMetrics')
114
140
  Rank = Shapes::IntegerShape.new(name: 'Rank')
141
+ ReasonCodeSummaries = Shapes::ListShape.new(name: 'ReasonCodeSummaries')
142
+ ReasonCodeSummary = Shapes::StructureShape.new(name: 'ReasonCodeSummary')
115
143
  RecommendationExportJob = Shapes::StructureShape.new(name: 'RecommendationExportJob')
116
144
  RecommendationExportJobs = Shapes::ListShape.new(name: 'RecommendationExportJobs')
117
145
  RecommendationOptions = Shapes::ListShape.new(name: 'RecommendationOptions')
@@ -251,6 +279,8 @@ module Aws::ComputeOptimizer
251
279
 
252
280
  Filters.member = Shapes::ShapeRef.new(shape: Filter)
253
281
 
282
+ FunctionArns.member = Shapes::ShapeRef.new(shape: FunctionArn)
283
+
254
284
  GetAutoScalingGroupRecommendationsRequest.add_member(:account_ids, Shapes::ShapeRef.new(shape: AccountIds, location_name: "accountIds"))
255
285
  GetAutoScalingGroupRecommendationsRequest.add_member(:auto_scaling_group_arns, Shapes::ShapeRef.new(shape: AutoScalingGroupArns, location_name: "autoScalingGroupArns"))
256
286
  GetAutoScalingGroupRecommendationsRequest.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "nextToken"))
@@ -304,6 +334,17 @@ module Aws::ComputeOptimizer
304
334
  GetEnrollmentStatusResponse.add_member(:member_accounts_enrolled, Shapes::ShapeRef.new(shape: MemberAccountsEnrolled, location_name: "memberAccountsEnrolled"))
305
335
  GetEnrollmentStatusResponse.struct_class = Types::GetEnrollmentStatusResponse
306
336
 
337
+ GetLambdaFunctionRecommendationsRequest.add_member(:function_arns, Shapes::ShapeRef.new(shape: FunctionArns, location_name: "functionArns"))
338
+ GetLambdaFunctionRecommendationsRequest.add_member(:account_ids, Shapes::ShapeRef.new(shape: AccountIds, location_name: "accountIds"))
339
+ GetLambdaFunctionRecommendationsRequest.add_member(:filters, Shapes::ShapeRef.new(shape: LambdaFunctionRecommendationFilters, location_name: "filters"))
340
+ GetLambdaFunctionRecommendationsRequest.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "nextToken"))
341
+ GetLambdaFunctionRecommendationsRequest.add_member(:max_results, Shapes::ShapeRef.new(shape: MaxResults, location_name: "maxResults"))
342
+ GetLambdaFunctionRecommendationsRequest.struct_class = Types::GetLambdaFunctionRecommendationsRequest
343
+
344
+ GetLambdaFunctionRecommendationsResponse.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "nextToken"))
345
+ GetLambdaFunctionRecommendationsResponse.add_member(:lambda_function_recommendations, Shapes::ShapeRef.new(shape: LambdaFunctionRecommendations, location_name: "lambdaFunctionRecommendations"))
346
+ GetLambdaFunctionRecommendationsResponse.struct_class = Types::GetLambdaFunctionRecommendationsResponse
347
+
307
348
  GetRecommendationError.add_member(:identifier, Shapes::ShapeRef.new(shape: Identifier, location_name: "identifier"))
308
349
  GetRecommendationError.add_member(:code, Shapes::ShapeRef.new(shape: Code, location_name: "code"))
309
350
  GetRecommendationError.add_member(:message, Shapes::ShapeRef.new(shape: Message, location_name: "message"))
@@ -356,6 +397,50 @@ module Aws::ComputeOptimizer
356
397
 
357
398
  JobIds.member = Shapes::ShapeRef.new(shape: JobId)
358
399
 
400
+ LambdaFunctionMemoryProjectedMetric.add_member(:name, Shapes::ShapeRef.new(shape: LambdaFunctionMemoryMetricName, location_name: "name"))
401
+ LambdaFunctionMemoryProjectedMetric.add_member(:statistic, Shapes::ShapeRef.new(shape: LambdaFunctionMemoryMetricStatistic, location_name: "statistic"))
402
+ LambdaFunctionMemoryProjectedMetric.add_member(:value, Shapes::ShapeRef.new(shape: MetricValue, location_name: "value"))
403
+ LambdaFunctionMemoryProjectedMetric.struct_class = Types::LambdaFunctionMemoryProjectedMetric
404
+
405
+ LambdaFunctionMemoryProjectedMetrics.member = Shapes::ShapeRef.new(shape: LambdaFunctionMemoryProjectedMetric)
406
+
407
+ LambdaFunctionMemoryRecommendationOption.add_member(:rank, Shapes::ShapeRef.new(shape: Rank, location_name: "rank"))
408
+ LambdaFunctionMemoryRecommendationOption.add_member(:memory_size, Shapes::ShapeRef.new(shape: MemorySize, location_name: "memorySize"))
409
+ LambdaFunctionMemoryRecommendationOption.add_member(:projected_utilization_metrics, Shapes::ShapeRef.new(shape: LambdaFunctionMemoryProjectedMetrics, location_name: "projectedUtilizationMetrics"))
410
+ LambdaFunctionMemoryRecommendationOption.struct_class = Types::LambdaFunctionMemoryRecommendationOption
411
+
412
+ LambdaFunctionMemoryRecommendationOptions.member = Shapes::ShapeRef.new(shape: LambdaFunctionMemoryRecommendationOption)
413
+
414
+ LambdaFunctionRecommendation.add_member(:function_arn, Shapes::ShapeRef.new(shape: FunctionArn, location_name: "functionArn"))
415
+ LambdaFunctionRecommendation.add_member(:function_version, Shapes::ShapeRef.new(shape: FunctionVersion, location_name: "functionVersion"))
416
+ LambdaFunctionRecommendation.add_member(:account_id, Shapes::ShapeRef.new(shape: AccountId, location_name: "accountId"))
417
+ LambdaFunctionRecommendation.add_member(:current_memory_size, Shapes::ShapeRef.new(shape: MemorySize, location_name: "currentMemorySize"))
418
+ LambdaFunctionRecommendation.add_member(:number_of_invocations, Shapes::ShapeRef.new(shape: NumberOfInvocations, location_name: "numberOfInvocations"))
419
+ LambdaFunctionRecommendation.add_member(:utilization_metrics, Shapes::ShapeRef.new(shape: LambdaFunctionUtilizationMetrics, location_name: "utilizationMetrics"))
420
+ LambdaFunctionRecommendation.add_member(:lookback_period_in_days, Shapes::ShapeRef.new(shape: LookBackPeriodInDays, location_name: "lookbackPeriodInDays"))
421
+ LambdaFunctionRecommendation.add_member(:last_refresh_timestamp, Shapes::ShapeRef.new(shape: LastRefreshTimestamp, location_name: "lastRefreshTimestamp"))
422
+ LambdaFunctionRecommendation.add_member(:finding, Shapes::ShapeRef.new(shape: LambdaFunctionRecommendationFinding, location_name: "finding"))
423
+ LambdaFunctionRecommendation.add_member(:finding_reason_codes, Shapes::ShapeRef.new(shape: LambdaFunctionRecommendationFindingReasonCodes, location_name: "findingReasonCodes"))
424
+ LambdaFunctionRecommendation.add_member(:memory_size_recommendation_options, Shapes::ShapeRef.new(shape: LambdaFunctionMemoryRecommendationOptions, location_name: "memorySizeRecommendationOptions"))
425
+ LambdaFunctionRecommendation.struct_class = Types::LambdaFunctionRecommendation
426
+
427
+ LambdaFunctionRecommendationFilter.add_member(:name, Shapes::ShapeRef.new(shape: LambdaFunctionRecommendationFilterName, location_name: "name"))
428
+ LambdaFunctionRecommendationFilter.add_member(:values, Shapes::ShapeRef.new(shape: FilterValues, location_name: "values"))
429
+ LambdaFunctionRecommendationFilter.struct_class = Types::LambdaFunctionRecommendationFilter
430
+
431
+ LambdaFunctionRecommendationFilters.member = Shapes::ShapeRef.new(shape: LambdaFunctionRecommendationFilter)
432
+
433
+ LambdaFunctionRecommendationFindingReasonCodes.member = Shapes::ShapeRef.new(shape: LambdaFunctionRecommendationFindingReasonCode)
434
+
435
+ LambdaFunctionRecommendations.member = Shapes::ShapeRef.new(shape: LambdaFunctionRecommendation)
436
+
437
+ LambdaFunctionUtilizationMetric.add_member(:name, Shapes::ShapeRef.new(shape: LambdaFunctionMetricName, location_name: "name"))
438
+ LambdaFunctionUtilizationMetric.add_member(:statistic, Shapes::ShapeRef.new(shape: LambdaFunctionMetricStatistic, location_name: "statistic"))
439
+ LambdaFunctionUtilizationMetric.add_member(:value, Shapes::ShapeRef.new(shape: MetricValue, location_name: "value"))
440
+ LambdaFunctionUtilizationMetric.struct_class = Types::LambdaFunctionUtilizationMetric
441
+
442
+ LambdaFunctionUtilizationMetrics.member = Shapes::ShapeRef.new(shape: LambdaFunctionUtilizationMetric)
443
+
359
444
  LimitExceededException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessage, location_name: "message"))
360
445
  LimitExceededException.struct_class = Types::LimitExceededException
361
446
 
@@ -376,6 +461,12 @@ module Aws::ComputeOptimizer
376
461
 
377
462
  ProjectedUtilizationMetrics.member = Shapes::ShapeRef.new(shape: UtilizationMetric)
378
463
 
464
+ ReasonCodeSummaries.member = Shapes::ShapeRef.new(shape: ReasonCodeSummary)
465
+
466
+ ReasonCodeSummary.add_member(:name, Shapes::ShapeRef.new(shape: FindingReasonCode, location_name: "name"))
467
+ ReasonCodeSummary.add_member(:value, Shapes::ShapeRef.new(shape: SummaryValue, location_name: "value"))
468
+ ReasonCodeSummary.struct_class = Types::ReasonCodeSummary
469
+
379
470
  RecommendationExportJob.add_member(:job_id, Shapes::ShapeRef.new(shape: JobId, location_name: "jobId"))
380
471
  RecommendationExportJob.add_member(:destination, Shapes::ShapeRef.new(shape: ExportDestination, location_name: "destination"))
381
472
  RecommendationExportJob.add_member(:resource_type, Shapes::ShapeRef.new(shape: ResourceType, location_name: "resourceType"))
@@ -428,6 +519,7 @@ module Aws::ComputeOptimizer
428
519
 
429
520
  Summary.add_member(:name, Shapes::ShapeRef.new(shape: Finding, location_name: "name"))
430
521
  Summary.add_member(:value, Shapes::ShapeRef.new(shape: SummaryValue, location_name: "value"))
522
+ Summary.add_member(:reason_code_summaries, Shapes::ShapeRef.new(shape: ReasonCodeSummaries, location_name: "reasonCodeSummaries"))
431
523
  Summary.struct_class = Types::Summary
432
524
 
433
525
  ThrottlingException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessage, required: true, location_name: "message"))
@@ -624,6 +716,22 @@ module Aws::ComputeOptimizer
624
716
  o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
625
717
  end)
626
718
 
719
+ api.add_operation(:get_lambda_function_recommendations, Seahorse::Model::Operation.new.tap do |o|
720
+ o.name = "GetLambdaFunctionRecommendations"
721
+ o.http_method = "POST"
722
+ o.http_request_uri = "/"
723
+ o.input = Shapes::ShapeRef.new(shape: GetLambdaFunctionRecommendationsRequest)
724
+ o.output = Shapes::ShapeRef.new(shape: GetLambdaFunctionRecommendationsResponse)
725
+ o.errors << Shapes::ShapeRef.new(shape: OptInRequiredException)
726
+ o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
727
+ o.errors << Shapes::ShapeRef.new(shape: ServiceUnavailableException)
728
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
729
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterValueException)
730
+ o.errors << Shapes::ShapeRef.new(shape: MissingAuthenticationToken)
731
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
732
+ o.errors << Shapes::ShapeRef.new(shape: LimitExceededException)
733
+ end)
734
+
627
735
  api.add_operation(:get_recommendation_summaries, Seahorse::Model::Operation.new.tap do |o|
628
736
  o.name = "GetRecommendationSummaries"
629
737
  o.http_method = "POST"
@@ -1034,6 +1034,101 @@ module Aws::ComputeOptimizer
1034
1034
  include Aws::Structure
1035
1035
  end
1036
1036
 
1037
+ # @note When making an API call, you may pass GetLambdaFunctionRecommendationsRequest
1038
+ # data as a hash:
1039
+ #
1040
+ # {
1041
+ # function_arns: ["FunctionArn"],
1042
+ # account_ids: ["AccountId"],
1043
+ # filters: [
1044
+ # {
1045
+ # name: "Finding", # accepts Finding, FindingReasonCode
1046
+ # values: ["FilterValue"],
1047
+ # },
1048
+ # ],
1049
+ # next_token: "NextToken",
1050
+ # max_results: 1,
1051
+ # }
1052
+ #
1053
+ # @!attribute [rw] function_arns
1054
+ # The Amazon Resource Name (ARN) of the functions for which to return
1055
+ # recommendations.
1056
+ #
1057
+ # You can specify a qualified or unqualified ARN. If you specify an
1058
+ # unqualified ARN without a function version suffix, Compute Optimizer
1059
+ # will return recommendations for the latest (`$LATEST`) version of
1060
+ # the function. If you specify a qualified ARN with a version suffix,
1061
+ # Compute Optimizer will return recommendations for the specified
1062
+ # function version. For more information about using function
1063
+ # versions, see [Using versions][1] in the *AWS Lambda Developer
1064
+ # Guide*.
1065
+ #
1066
+ #
1067
+ #
1068
+ # [1]: https://docs.aws.amazon.com/lambda/latest/dg/configuration-versions.html#versioning-versions-using
1069
+ # @return [Array<String>]
1070
+ #
1071
+ # @!attribute [rw] account_ids
1072
+ # The IDs of the AWS accounts for which to return function
1073
+ # recommendations.
1074
+ #
1075
+ # If your account is the management account of an organization, use
1076
+ # this parameter to specify the member accounts for which you want to
1077
+ # return function recommendations.
1078
+ #
1079
+ # Only one account ID can be specified per request.
1080
+ # @return [Array<String>]
1081
+ #
1082
+ # @!attribute [rw] filters
1083
+ # An array of objects that describe a filter that returns a more
1084
+ # specific list of function recommendations.
1085
+ # @return [Array<Types::LambdaFunctionRecommendationFilter>]
1086
+ #
1087
+ # @!attribute [rw] next_token
1088
+ # The token to advance to the next page of function recommendations.
1089
+ # @return [String]
1090
+ #
1091
+ # @!attribute [rw] max_results
1092
+ # The maximum number of function recommendations to return with a
1093
+ # single request.
1094
+ #
1095
+ # To retrieve the remaining results, make another request with the
1096
+ # returned `NextToken` value.
1097
+ # @return [Integer]
1098
+ #
1099
+ # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/GetLambdaFunctionRecommendationsRequest AWS API Documentation
1100
+ #
1101
+ class GetLambdaFunctionRecommendationsRequest < Struct.new(
1102
+ :function_arns,
1103
+ :account_ids,
1104
+ :filters,
1105
+ :next_token,
1106
+ :max_results)
1107
+ SENSITIVE = []
1108
+ include Aws::Structure
1109
+ end
1110
+
1111
+ # @!attribute [rw] next_token
1112
+ # The token to use to advance to the next page of function
1113
+ # recommendations.
1114
+ #
1115
+ # This value is null when there are no more pages of function
1116
+ # recommendations to return.
1117
+ # @return [String]
1118
+ #
1119
+ # @!attribute [rw] lambda_function_recommendations
1120
+ # An array of objects that describe function recommendations.
1121
+ # @return [Array<Types::LambdaFunctionRecommendation>]
1122
+ #
1123
+ # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/GetLambdaFunctionRecommendationsResponse AWS API Documentation
1124
+ #
1125
+ class GetLambdaFunctionRecommendationsResponse < Struct.new(
1126
+ :next_token,
1127
+ :lambda_function_recommendations)
1128
+ SENSITIVE = []
1129
+ include Aws::Structure
1130
+ end
1131
+
1037
1132
  # Describes an error experienced when getting recommendations.
1038
1133
  #
1039
1134
  # For example, an error is returned if you request recommendations for
@@ -1336,6 +1431,261 @@ module Aws::ComputeOptimizer
1336
1431
  include Aws::Structure
1337
1432
  end
1338
1433
 
1434
+ # Describes a projected utilization metric of an AWS Lambda function
1435
+ # recommendation option.
1436
+ #
1437
+ # @!attribute [rw] name
1438
+ # The name of the projected utilization metric.
1439
+ # @return [String]
1440
+ #
1441
+ # @!attribute [rw] statistic
1442
+ # The statistic of the projected utilization metric.
1443
+ # @return [String]
1444
+ #
1445
+ # @!attribute [rw] value
1446
+ # The values of the projected utilization metrics.
1447
+ # @return [Float]
1448
+ #
1449
+ # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/LambdaFunctionMemoryProjectedMetric AWS API Documentation
1450
+ #
1451
+ class LambdaFunctionMemoryProjectedMetric < Struct.new(
1452
+ :name,
1453
+ :statistic,
1454
+ :value)
1455
+ SENSITIVE = []
1456
+ include Aws::Structure
1457
+ end
1458
+
1459
+ # Describes a recommendation option for an AWS Lambda function.
1460
+ #
1461
+ # @!attribute [rw] rank
1462
+ # The rank of the function recommendation option.
1463
+ #
1464
+ # The top recommendation option is ranked as `1`.
1465
+ # @return [Integer]
1466
+ #
1467
+ # @!attribute [rw] memory_size
1468
+ # The memory size, in MB, of the function recommendation option.
1469
+ # @return [Integer]
1470
+ #
1471
+ # @!attribute [rw] projected_utilization_metrics
1472
+ # An array of objects that describe the projected utilization metrics
1473
+ # of the function recommendation option.
1474
+ # @return [Array<Types::LambdaFunctionMemoryProjectedMetric>]
1475
+ #
1476
+ # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/LambdaFunctionMemoryRecommendationOption AWS API Documentation
1477
+ #
1478
+ class LambdaFunctionMemoryRecommendationOption < Struct.new(
1479
+ :rank,
1480
+ :memory_size,
1481
+ :projected_utilization_metrics)
1482
+ SENSITIVE = []
1483
+ include Aws::Structure
1484
+ end
1485
+
1486
+ # Describes an AWS Lambda function recommendation.
1487
+ #
1488
+ # @!attribute [rw] function_arn
1489
+ # The Amazon Resource Name (ARN) of the current function.
1490
+ # @return [String]
1491
+ #
1492
+ # @!attribute [rw] function_version
1493
+ # The version number of the current function.
1494
+ # @return [String]
1495
+ #
1496
+ # @!attribute [rw] account_id
1497
+ # The AWS account ID of the function.
1498
+ # @return [String]
1499
+ #
1500
+ # @!attribute [rw] current_memory_size
1501
+ # The amount of memory, in MB, that's allocated to the current
1502
+ # function.
1503
+ # @return [Integer]
1504
+ #
1505
+ # @!attribute [rw] number_of_invocations
1506
+ # The number of times your function code was executed during the
1507
+ # look-back period.
1508
+ # @return [Integer]
1509
+ #
1510
+ # @!attribute [rw] utilization_metrics
1511
+ # An array of objects that describe the utilization metrics of the
1512
+ # function.
1513
+ # @return [Array<Types::LambdaFunctionUtilizationMetric>]
1514
+ #
1515
+ # @!attribute [rw] lookback_period_in_days
1516
+ # The number of days for which utilization metrics were analyzed for
1517
+ # the function.
1518
+ # @return [Float]
1519
+ #
1520
+ # @!attribute [rw] last_refresh_timestamp
1521
+ # The time stamp of when the function recommendation was last
1522
+ # refreshed.
1523
+ # @return [Time]
1524
+ #
1525
+ # @!attribute [rw] finding
1526
+ # The finding classification for the function.
1527
+ #
1528
+ # Findings for functions include:
1529
+ #
1530
+ # * <b> <code>Optimized</code> </b> — The function is correctly
1531
+ # provisioned to run your workload based on its current
1532
+ # configuration and its utilization history. This finding
1533
+ # classification does not include finding reason codes.
1534
+ #
1535
+ # * <b> <code>NotOptimized</code> </b> — The function is performing at
1536
+ # a higher level (over-provisioned) or at a lower level
1537
+ # (under-provisioned) than required for your workload because its
1538
+ # current configuration is not optimal. Over-provisioned resources
1539
+ # might lead to unnecessary infrastructure cost, and
1540
+ # under-provisioned resources might lead to poor application
1541
+ # performance. This finding classification can include the
1542
+ # `MemoryUnderprovisioned` and `MemoryUnderprovisioned` finding
1543
+ # reason codes.
1544
+ #
1545
+ # * <b> <code>Unavailable</code> </b> — Compute Optimizer was unable
1546
+ # to generate a recommendation for the function. This could be
1547
+ # because the function has not accumulated sufficient metric data,
1548
+ # or the function does not qualify for a recommendation. This
1549
+ # finding classification can include the `InsufficientData` and
1550
+ # `Inconclusive` finding reason codes.
1551
+ #
1552
+ # <note markdown="1"> Functions with a finding of unavailable are not returned unless
1553
+ # you specify the `filter` parameter with a value of `Unavailable`
1554
+ # in your `GetLambdaFunctionRecommendations` request.
1555
+ #
1556
+ # </note>
1557
+ # @return [String]
1558
+ #
1559
+ # @!attribute [rw] finding_reason_codes
1560
+ # The reason for the finding classification of the function.
1561
+ #
1562
+ # <note markdown="1"> Functions that have a finding classification of `Optimized` don't
1563
+ # have a finding reason code.
1564
+ #
1565
+ # </note>
1566
+ #
1567
+ # Reason codes include:
1568
+ #
1569
+ # * <b> <code>MemoryOverprovisioned</code> </b> — The function is
1570
+ # over-provisioned when its memory configuration can be sized down
1571
+ # while still meeting the performance requirements of your workload.
1572
+ # An over-provisioned function might lead to unnecessary
1573
+ # infrastructure cost. This finding reason code is part of the
1574
+ # `NotOptimized` finding classification.
1575
+ #
1576
+ # * <b> <code>MemoryUnderprovisioned</code> </b> — The function is
1577
+ # under-provisioned when its memory configuration doesn't meet the
1578
+ # performance requirements of the workload. An under-provisioned
1579
+ # function might lead to poor application performance. This finding
1580
+ # reason code is part of the `NotOptimized` finding classification.
1581
+ #
1582
+ # * <b> <code>InsufficientData</code> </b> — The function does not
1583
+ # have sufficient metric data for Compute Optimizer to generate a
1584
+ # recommendation. For more information, see the [Supported resources
1585
+ # and requirements][1] in the *AWS Compute Optimizer User Guide*.
1586
+ # This finding reason code is part of the `Unavailable` finding
1587
+ # classification.
1588
+ #
1589
+ # * <b> <code>Inconclusive</code> </b> — The function does not qualify
1590
+ # for a recommendation, or there was an internal error. This finding
1591
+ # reason code is part of the `Unavailable` finding classification.
1592
+ #
1593
+ #
1594
+ #
1595
+ # [1]: https://docs.aws.amazon.com/compute-optimizer/latest/ug/requirements.html
1596
+ # @return [Array<String>]
1597
+ #
1598
+ # @!attribute [rw] memory_size_recommendation_options
1599
+ # An array of objects that describe the memory configuration
1600
+ # recommendation options for the function.
1601
+ # @return [Array<Types::LambdaFunctionMemoryRecommendationOption>]
1602
+ #
1603
+ # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/LambdaFunctionRecommendation AWS API Documentation
1604
+ #
1605
+ class LambdaFunctionRecommendation < Struct.new(
1606
+ :function_arn,
1607
+ :function_version,
1608
+ :account_id,
1609
+ :current_memory_size,
1610
+ :number_of_invocations,
1611
+ :utilization_metrics,
1612
+ :lookback_period_in_days,
1613
+ :last_refresh_timestamp,
1614
+ :finding,
1615
+ :finding_reason_codes,
1616
+ :memory_size_recommendation_options)
1617
+ SENSITIVE = []
1618
+ include Aws::Structure
1619
+ end
1620
+
1621
+ # Describes a filter that returns a more specific list of AWS Lambda
1622
+ # function recommendations.
1623
+ #
1624
+ # @note When making an API call, you may pass LambdaFunctionRecommendationFilter
1625
+ # data as a hash:
1626
+ #
1627
+ # {
1628
+ # name: "Finding", # accepts Finding, FindingReasonCode
1629
+ # values: ["FilterValue"],
1630
+ # }
1631
+ #
1632
+ # @!attribute [rw] name
1633
+ # The name of the filter.
1634
+ #
1635
+ # Specify `Finding` to return recommendations with a specific finding
1636
+ # classification (e.g., `NotOptimized`).
1637
+ #
1638
+ # Specify `FindingReasonCode` to return recommendations with a
1639
+ # specific finding reason code (e.g., `MemoryUnderprovisioned`).
1640
+ # @return [String]
1641
+ #
1642
+ # @!attribute [rw] values
1643
+ # The value of the filter.
1644
+ #
1645
+ # The valid values for this parameter are as follows, depending on
1646
+ # what you specify for the `name` parameter:
1647
+ #
1648
+ # * Specify `Optimized`, `NotOptimized`, or `Unavailable` if you
1649
+ # specified the `name` parameter as `Finding`.
1650
+ #
1651
+ # * Specify `MemoryOverprovisioned`, `MemoryUnderprovisioned`,
1652
+ # `InsufficientData`, or `Inconclusive` if you specified the `name`
1653
+ # parameter as `FindingReasonCode`.
1654
+ # @return [Array<String>]
1655
+ #
1656
+ # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/LambdaFunctionRecommendationFilter AWS API Documentation
1657
+ #
1658
+ class LambdaFunctionRecommendationFilter < Struct.new(
1659
+ :name,
1660
+ :values)
1661
+ SENSITIVE = []
1662
+ include Aws::Structure
1663
+ end
1664
+
1665
+ # Describes a utilization metric of an AWS Lambda function.
1666
+ #
1667
+ # @!attribute [rw] name
1668
+ # The name of the utilization metric.
1669
+ # @return [String]
1670
+ #
1671
+ # @!attribute [rw] statistic
1672
+ # The statistic of the utilization metric.
1673
+ # @return [String]
1674
+ #
1675
+ # @!attribute [rw] value
1676
+ # The value of the utilization metric.
1677
+ # @return [Float]
1678
+ #
1679
+ # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/LambdaFunctionUtilizationMetric AWS API Documentation
1680
+ #
1681
+ class LambdaFunctionUtilizationMetric < Struct.new(
1682
+ :name,
1683
+ :statistic,
1684
+ :value)
1685
+ SENSITIVE = []
1686
+ include Aws::Structure
1687
+ end
1688
+
1339
1689
  # The request exceeds a limit of the service.
1340
1690
  #
1341
1691
  # @!attribute [rw] message
@@ -1451,6 +1801,25 @@ module Aws::ComputeOptimizer
1451
1801
  include Aws::Structure
1452
1802
  end
1453
1803
 
1804
+ # A summary of a finding reason code.
1805
+ #
1806
+ # @!attribute [rw] name
1807
+ # The name of the finding reason code.
1808
+ # @return [String]
1809
+ #
1810
+ # @!attribute [rw] value
1811
+ # The value of the finding reason code summary.
1812
+ # @return [Float]
1813
+ #
1814
+ # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/ReasonCodeSummary AWS API Documentation
1815
+ #
1816
+ class ReasonCodeSummary < Struct.new(
1817
+ :name,
1818
+ :value)
1819
+ SENSITIVE = []
1820
+ include Aws::Structure
1821
+ end
1822
+
1454
1823
  # Describes a recommendation export job.
1455
1824
  #
1456
1825
  # Use the `DescribeRecommendationExportJobs` action to view your
@@ -1702,11 +2071,16 @@ module Aws::ComputeOptimizer
1702
2071
  # The value of the recommendation summary.
1703
2072
  # @return [Float]
1704
2073
  #
2074
+ # @!attribute [rw] reason_code_summaries
2075
+ # An array of objects that summarize a finding reason code.
2076
+ # @return [Array<Types::ReasonCodeSummary>]
2077
+ #
1705
2078
  # @see http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/Summary AWS API Documentation
1706
2079
  #
1707
2080
  class Summary < Struct.new(
1708
2081
  :name,
1709
- :value)
2082
+ :value,
2083
+ :reason_code_summaries)
1710
2084
  SENSITIVE = []
1711
2085
  include Aws::Structure
1712
2086
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-computeoptimizer
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.10.0
4
+ version: 1.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-12-03 00:00:00.000000000 Z
11
+ date: 2020-12-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core