aws-sdk-applicationautoscaling 1.0.0.rc1 → 1.0.0.rc2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/aws-sdk-applicationautoscaling/client.rb +832 -701
- data/lib/aws-sdk-applicationautoscaling/client_api.rb +309 -311
- data/lib/aws-sdk-applicationautoscaling/errors.rb +4 -13
- data/lib/aws-sdk-applicationautoscaling/resource.rb +12 -14
- data/lib/aws-sdk-applicationautoscaling/types.rb +1092 -962
- data/lib/aws-sdk-applicationautoscaling.rb +2 -2
- metadata +2 -2
@@ -1,6 +1,6 @@
|
|
1
1
|
# WARNING ABOUT GENERATED CODE
|
2
2
|
#
|
3
|
-
# This file is generated. See the contributing for
|
3
|
+
# This file is generated. See the contributing guide for more information:
|
4
4
|
# https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
|
5
5
|
#
|
6
6
|
# WARNING ABOUT GENERATED CODE
|
@@ -18,731 +18,862 @@ require 'aws-sdk-core/plugins/regional_endpoint.rb'
|
|
18
18
|
require 'aws-sdk-core/plugins/response_paging.rb'
|
19
19
|
require 'aws-sdk-core/plugins/stub_responses.rb'
|
20
20
|
require 'aws-sdk-core/plugins/idempotency_token.rb'
|
21
|
+
require 'aws-sdk-core/plugins/jsonvalue_converter.rb'
|
21
22
|
require 'aws-sdk-core/plugins/signature_v4.rb'
|
22
23
|
require 'aws-sdk-core/plugins/protocols/json_rpc.rb'
|
23
24
|
|
24
25
|
Aws::Plugins::GlobalConfiguration.add_identifier(:applicationautoscaling)
|
25
26
|
|
26
|
-
module Aws
|
27
|
-
|
28
|
-
class Client < Seahorse::Client::Base
|
27
|
+
module Aws::ApplicationAutoScaling
|
28
|
+
class Client < Seahorse::Client::Base
|
29
29
|
|
30
|
-
|
30
|
+
include Aws::ClientStubs
|
31
31
|
|
32
|
-
|
32
|
+
@identifier = :applicationautoscaling
|
33
33
|
|
34
|
-
|
34
|
+
set_api(ClientApi::API)
|
35
35
|
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
36
|
+
add_plugin(Seahorse::Client::Plugins::ContentLength)
|
37
|
+
add_plugin(Aws::Plugins::CredentialsConfiguration)
|
38
|
+
add_plugin(Aws::Plugins::Logging)
|
39
|
+
add_plugin(Aws::Plugins::ParamConverter)
|
40
|
+
add_plugin(Aws::Plugins::ParamValidator)
|
41
|
+
add_plugin(Aws::Plugins::UserAgent)
|
42
|
+
add_plugin(Aws::Plugins::HelpfulSocketErrors)
|
43
|
+
add_plugin(Aws::Plugins::RetryErrors)
|
44
|
+
add_plugin(Aws::Plugins::GlobalConfiguration)
|
45
|
+
add_plugin(Aws::Plugins::RegionalEndpoint)
|
46
|
+
add_plugin(Aws::Plugins::ResponsePaging)
|
47
|
+
add_plugin(Aws::Plugins::StubResponses)
|
48
|
+
add_plugin(Aws::Plugins::IdempotencyToken)
|
49
|
+
add_plugin(Aws::Plugins::JsonvalueConverter)
|
50
|
+
add_plugin(Aws::Plugins::SignatureV4)
|
51
|
+
add_plugin(Aws::Plugins::Protocols::JsonRpc)
|
51
52
|
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
53
|
+
# @option options [required, Aws::CredentialProvider] :credentials
|
54
|
+
# Your AWS credentials. This can be an instance of any one of the
|
55
|
+
# following classes:
|
56
|
+
#
|
57
|
+
# * `Aws::Credentials` - Used for configuring static, non-refreshing
|
58
|
+
# credentials.
|
59
|
+
#
|
60
|
+
# * `Aws::InstanceProfileCredentials` - Used for loading credentials
|
61
|
+
# from an EC2 IMDS on an EC2 instance.
|
62
|
+
#
|
63
|
+
# * `Aws::SharedCredentials` - Used for loading credentials from a
|
64
|
+
# shared file, such as `~/.aws/config`.
|
65
|
+
#
|
66
|
+
# * `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
|
67
|
+
#
|
68
|
+
# When `:credentials` are not configured directly, the following
|
69
|
+
# locations will be searched for credentials:
|
70
|
+
#
|
71
|
+
# * `Aws.config[:credentials]`
|
72
|
+
# * The `:access_key_id`, `:secret_access_key`, and `:session_token` options.
|
73
|
+
# * ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY']
|
74
|
+
# * `~/.aws/credentials`
|
75
|
+
# * `~/.aws/config`
|
76
|
+
# * EC2 IMDS instance profile - When used by default, the timeouts are
|
77
|
+
# very aggressive. Construct and pass an instance of
|
78
|
+
# `Aws::InstanceProfileCredentails` to enable retries and extended
|
79
|
+
# timeouts.
|
80
|
+
#
|
81
|
+
# @option options [required, String] :region
|
82
|
+
# The AWS region to connect to. The configured `:region` is
|
83
|
+
# used to determine the service `:endpoint`. When not passed,
|
84
|
+
# a default `:region` is search for in the following locations:
|
85
|
+
#
|
86
|
+
# * `Aws.config[:region]`
|
87
|
+
# * `ENV['AWS_REGION']`
|
88
|
+
# * `ENV['AMAZON_REGION']`
|
89
|
+
# * `ENV['AWS_DEFAULT_REGION']`
|
90
|
+
# * `~/.aws/credentials`
|
91
|
+
# * `~/.aws/config`
|
92
|
+
#
|
93
|
+
# @option options [String] :access_key_id
|
94
|
+
#
|
95
|
+
# @option options [Boolean] :convert_params (true)
|
96
|
+
# When `true`, an attempt is made to coerce request parameters into
|
97
|
+
# the required types.
|
98
|
+
#
|
99
|
+
# @option options [String] :endpoint
|
100
|
+
# The client endpoint is normally constructed from the `:region`
|
101
|
+
# option. You should only configure an `:endpoint` when connecting
|
102
|
+
# to test endpoints. This should be avalid HTTP(S) URI.
|
103
|
+
#
|
104
|
+
# @option options [Aws::Log::Formatter] :log_formatter (Aws::Log::Formatter.default)
|
105
|
+
# The log formatter.
|
106
|
+
#
|
107
|
+
# @option options [Symbol] :log_level (:info)
|
108
|
+
# The log level to send messages to the `:logger` at.
|
109
|
+
#
|
110
|
+
# @option options [Logger] :logger
|
111
|
+
# The Logger instance to send log messages to. If this option
|
112
|
+
# is not set, logging will be disabled.
|
113
|
+
#
|
114
|
+
# @option options [String] :profile ("default")
|
115
|
+
# Used when loading credentials from the shared credentials file
|
116
|
+
# at HOME/.aws/credentials. When not specified, 'default' is used.
|
117
|
+
#
|
118
|
+
# @option options [Integer] :retry_limit (3)
|
119
|
+
# The maximum number of times to retry failed requests. Only
|
120
|
+
# ~ 500 level server errors and certain ~ 400 level client errors
|
121
|
+
# are retried. Generally, these are throttling errors, data
|
122
|
+
# checksum errors, networking errors, timeout errors and auth
|
123
|
+
# errors from expired credentials.
|
124
|
+
#
|
125
|
+
# @option options [String] :secret_access_key
|
126
|
+
#
|
127
|
+
# @option options [String] :session_token
|
128
|
+
#
|
129
|
+
# @option options [Boolean] :simple_json (false)
|
130
|
+
# Disables request parameter conversion, validation, and formatting.
|
131
|
+
# Also disable response data type conversions. This option is useful
|
132
|
+
# when you want to ensure the highest level of performance by
|
133
|
+
# avoiding overhead of walking request parameters and response data
|
134
|
+
# structures.
|
135
|
+
#
|
136
|
+
# When `:simple_json` is enabled, the request parameters hash must
|
137
|
+
# be formatted exactly as the DynamoDB API expects.
|
138
|
+
#
|
139
|
+
# @option options [Boolean] :stub_responses (false)
|
140
|
+
# Causes the client to return stubbed responses. By default
|
141
|
+
# fake responses are generated and returned. You can specify
|
142
|
+
# the response data to return or errors to raise by calling
|
143
|
+
# {ClientStubs#stub_responses}. See {ClientStubs} for more information.
|
144
|
+
#
|
145
|
+
# ** Please note ** When response stubbing is enabled, no HTTP
|
146
|
+
# requests are made, and retries are disabled.
|
147
|
+
#
|
148
|
+
# @option options [Boolean] :validate_params (true)
|
149
|
+
# When `true`, request parameters are validated before
|
150
|
+
# sending the request.
|
151
|
+
#
|
152
|
+
def initialize(*args)
|
153
|
+
super
|
154
|
+
end
|
141
155
|
|
142
|
-
|
143
|
-
#
|
144
|
-
# Deleting a policy deletes the underlying alarm action, but does not
|
145
|
-
# delete the CloudWatch alarm associated with the scaling policy, even
|
146
|
-
# if it no longer has an associated action.
|
147
|
-
#
|
148
|
-
# To create a scaling policy or update an existing one, see
|
149
|
-
# PutScalingPolicy.
|
150
|
-
# @option params [required, String] :policy_name
|
151
|
-
# The name of the scaling policy.
|
152
|
-
# @option params [required, String] :service_namespace
|
153
|
-
# The namespace of the AWS service. For more information, see [AWS
|
154
|
-
# Service Namespaces][1] in the *Amazon Web Services General Reference*.
|
155
|
-
#
|
156
|
-
#
|
157
|
-
#
|
158
|
-
# [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-aws-service-namespaces
|
159
|
-
# @option params [required, String] :resource_id
|
160
|
-
# The identifier of the resource associated with the scalable target.
|
161
|
-
# This string consists of the resource type and unique identifier.
|
162
|
-
#
|
163
|
-
# * ECS service - The resource type is `service` and the unique
|
164
|
-
# identifier is the cluster name and service name. Example:
|
165
|
-
# `service/default/sample-webapp`.
|
166
|
-
#
|
167
|
-
# * Spot fleet request - The resource type is `spot-fleet-request` and
|
168
|
-
# the unique identifier is the Spot fleet request ID. Example:
|
169
|
-
# `spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE`.
|
170
|
-
#
|
171
|
-
# * EMR cluster - The resource type is `instancegroup` and the unique
|
172
|
-
# identifier is the cluster ID and instance group ID. Example:
|
173
|
-
# `instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0`.
|
174
|
-
# @option params [required, String] :scalable_dimension
|
175
|
-
# The scalable dimension. This string consists of the service namespace,
|
176
|
-
# resource type, and scaling property.
|
177
|
-
#
|
178
|
-
# * `ecs:service:DesiredCount` - The desired task count of an ECS
|
179
|
-
# service.
|
180
|
-
#
|
181
|
-
# * `ec2:spot-fleet-request:TargetCapacity` - The target capacity of a
|
182
|
-
# Spot fleet request.
|
183
|
-
#
|
184
|
-
# * `elasticmapreduce:instancegroup:InstanceCount` - The instance count
|
185
|
-
# of an EMR Instance Group.
|
186
|
-
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
187
|
-
#
|
188
|
-
# @example Request syntax with placeholder values
|
189
|
-
# resp = client.delete_scaling_policy({
|
190
|
-
# policy_name: "ResourceIdMaxLen1600", # required
|
191
|
-
# service_namespace: "ecs", # required, accepts ecs, elasticmapreduce, ec2
|
192
|
-
# resource_id: "ResourceIdMaxLen1600", # required
|
193
|
-
# scalable_dimension: "ecs:service:DesiredCount", # required, accepts ecs:service:DesiredCount, ec2:spot-fleet-request:TargetCapacity, elasticmapreduce:instancegroup:InstanceCount
|
194
|
-
# })
|
195
|
-
# @overload delete_scaling_policy(params = {})
|
196
|
-
# @param [Hash] params ({})
|
197
|
-
def delete_scaling_policy(params = {}, options = {})
|
198
|
-
req = build_request(:delete_scaling_policy, params)
|
199
|
-
req.send_request(options)
|
200
|
-
end
|
156
|
+
# @!group API Operations
|
201
157
|
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
158
|
+
# Deletes the specified Application Auto Scaling scaling policy.
|
159
|
+
#
|
160
|
+
# Deleting a policy deletes the underlying alarm action, but does not
|
161
|
+
# delete the CloudWatch alarm associated with the scaling policy, even
|
162
|
+
# if it no longer has an associated action.
|
163
|
+
#
|
164
|
+
# To create a scaling policy or update an existing one, see
|
165
|
+
# PutScalingPolicy.
|
166
|
+
#
|
167
|
+
# @option params [required, String] :policy_name
|
168
|
+
# The name of the scaling policy.
|
169
|
+
#
|
170
|
+
# @option params [required, String] :service_namespace
|
171
|
+
# The namespace of the AWS service. For more information, see [AWS
|
172
|
+
# Service Namespaces][1] in the *Amazon Web Services General Reference*.
|
173
|
+
#
|
174
|
+
#
|
175
|
+
#
|
176
|
+
# [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-aws-service-namespaces
|
177
|
+
#
|
178
|
+
# @option params [required, String] :resource_id
|
179
|
+
# The identifier of the resource associated with the scalable target.
|
180
|
+
# This string consists of the resource type and unique identifier.
|
181
|
+
#
|
182
|
+
# * ECS service - The resource type is `service` and the unique
|
183
|
+
# identifier is the cluster name and service name. Example:
|
184
|
+
# `service/default/sample-webapp`.
|
185
|
+
#
|
186
|
+
# * Spot fleet request - The resource type is `spot-fleet-request` and
|
187
|
+
# the unique identifier is the Spot fleet request ID. Example:
|
188
|
+
# `spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE`.
|
189
|
+
#
|
190
|
+
# * EMR cluster - The resource type is `instancegroup` and the unique
|
191
|
+
# identifier is the cluster ID and instance group ID. Example:
|
192
|
+
# `instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0`.
|
193
|
+
#
|
194
|
+
# * AppStream 2.0 fleet - The resource type is `fleet` and the unique
|
195
|
+
# identifier is the fleet name. Example: `fleet/sample-fleet`.
|
196
|
+
#
|
197
|
+
# @option params [required, String] :scalable_dimension
|
198
|
+
# The scalable dimension. This string consists of the service namespace,
|
199
|
+
# resource type, and scaling property.
|
200
|
+
#
|
201
|
+
# * `ecs:service:DesiredCount` - The desired task count of an ECS
|
202
|
+
# service.
|
203
|
+
#
|
204
|
+
# * `ec2:spot-fleet-request:TargetCapacity` - The target capacity of a
|
205
|
+
# Spot fleet request.
|
206
|
+
#
|
207
|
+
# * `elasticmapreduce:instancegroup:InstanceCount` - The instance count
|
208
|
+
# of an EMR Instance Group.
|
209
|
+
#
|
210
|
+
# * `appstream:fleet:DesiredCapacity` - The desired capacity of an
|
211
|
+
# AppStream 2.0 fleet.
|
212
|
+
#
|
213
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
214
|
+
#
|
215
|
+
# @example Request syntax with placeholder values
|
216
|
+
#
|
217
|
+
# resp = client.delete_scaling_policy({
|
218
|
+
# policy_name: "ResourceIdMaxLen1600", # required
|
219
|
+
# service_namespace: "ecs", # required, accepts ecs, elasticmapreduce, ec2, appstream
|
220
|
+
# resource_id: "ResourceIdMaxLen1600", # required
|
221
|
+
# scalable_dimension: "ecs:service:DesiredCount", # required, accepts ecs:service:DesiredCount, ec2:spot-fleet-request:TargetCapacity, elasticmapreduce:instancegroup:InstanceCount, appstream:fleet:DesiredCapacity
|
222
|
+
# })
|
223
|
+
#
|
224
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DeleteScalingPolicy AWS API Documentation
|
225
|
+
#
|
226
|
+
# @overload delete_scaling_policy(params = {})
|
227
|
+
# @param [Hash] params ({})
|
228
|
+
def delete_scaling_policy(params = {}, options = {})
|
229
|
+
req = build_request(:delete_scaling_policy, params)
|
230
|
+
req.send_request(options)
|
231
|
+
end
|
258
232
|
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
276
|
-
|
277
|
-
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
293
|
-
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
|
327
|
-
|
328
|
-
|
329
|
-
#
|
330
|
-
# @example Response structure
|
331
|
-
# resp.scalable_targets #=> Array
|
332
|
-
# resp.scalable_targets[0].service_namespace #=> String, one of "ecs", "elasticmapreduce", "ec2"
|
333
|
-
# resp.scalable_targets[0].resource_id #=> String
|
334
|
-
# resp.scalable_targets[0].scalable_dimension #=> String, one of "ecs:service:DesiredCount", "ec2:spot-fleet-request:TargetCapacity", "elasticmapreduce:instancegroup:InstanceCount"
|
335
|
-
# resp.scalable_targets[0].min_capacity #=> Integer
|
336
|
-
# resp.scalable_targets[0].max_capacity #=> Integer
|
337
|
-
# resp.scalable_targets[0].role_arn #=> String
|
338
|
-
# resp.scalable_targets[0].creation_time #=> Time
|
339
|
-
# resp.next_token #=> String
|
340
|
-
# @overload describe_scalable_targets(params = {})
|
341
|
-
# @param [Hash] params ({})
|
342
|
-
def describe_scalable_targets(params = {}, options = {})
|
343
|
-
req = build_request(:describe_scalable_targets, params)
|
344
|
-
req.send_request(options)
|
345
|
-
end
|
233
|
+
# Deregisters a scalable target.
|
234
|
+
#
|
235
|
+
# Deregistering a scalable target deletes the scaling policies that are
|
236
|
+
# associated with it.
|
237
|
+
#
|
238
|
+
# To create a scalable target or update an existing one, see
|
239
|
+
# RegisterScalableTarget.
|
240
|
+
#
|
241
|
+
# @option params [required, String] :service_namespace
|
242
|
+
# The namespace of the AWS service. For more information, see [AWS
|
243
|
+
# Service Namespaces][1] in the *Amazon Web Services General Reference*.
|
244
|
+
#
|
245
|
+
#
|
246
|
+
#
|
247
|
+
# [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-aws-service-namespaces
|
248
|
+
#
|
249
|
+
# @option params [required, String] :resource_id
|
250
|
+
# The identifier of the resource associated with the scalable target.
|
251
|
+
# This string consists of the resource type and unique identifier.
|
252
|
+
#
|
253
|
+
# * ECS service - The resource type is `service` and the unique
|
254
|
+
# identifier is the cluster name and service name. Example:
|
255
|
+
# `service/default/sample-webapp`.
|
256
|
+
#
|
257
|
+
# * Spot fleet request - The resource type is `spot-fleet-request` and
|
258
|
+
# the unique identifier is the Spot fleet request ID. Example:
|
259
|
+
# `spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE`.
|
260
|
+
#
|
261
|
+
# * EMR cluster - The resource type is `instancegroup` and the unique
|
262
|
+
# identifier is the cluster ID and instance group ID. Example:
|
263
|
+
# `instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0`.
|
264
|
+
#
|
265
|
+
# * AppStream 2.0 fleet - The resource type is `fleet` and the unique
|
266
|
+
# identifier is the fleet name. Example: `fleet/sample-fleet`.
|
267
|
+
#
|
268
|
+
# @option params [required, String] :scalable_dimension
|
269
|
+
# The scalable dimension associated with the scalable target. This
|
270
|
+
# string consists of the service namespace, resource type, and scaling
|
271
|
+
# property.
|
272
|
+
#
|
273
|
+
# * `ecs:service:DesiredCount` - The desired task count of an ECS
|
274
|
+
# service.
|
275
|
+
#
|
276
|
+
# * `ec2:spot-fleet-request:TargetCapacity` - The target capacity of a
|
277
|
+
# Spot fleet request.
|
278
|
+
#
|
279
|
+
# * `elasticmapreduce:instancegroup:InstanceCount` - The instance count
|
280
|
+
# of an EMR Instance Group.
|
281
|
+
#
|
282
|
+
# * `appstream:fleet:DesiredCapacity` - The desired capacity of an
|
283
|
+
# AppStream 2.0 fleet.
|
284
|
+
#
|
285
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
286
|
+
#
|
287
|
+
# @example Request syntax with placeholder values
|
288
|
+
#
|
289
|
+
# resp = client.deregister_scalable_target({
|
290
|
+
# service_namespace: "ecs", # required, accepts ecs, elasticmapreduce, ec2, appstream
|
291
|
+
# resource_id: "ResourceIdMaxLen1600", # required
|
292
|
+
# scalable_dimension: "ecs:service:DesiredCount", # required, accepts ecs:service:DesiredCount, ec2:spot-fleet-request:TargetCapacity, elasticmapreduce:instancegroup:InstanceCount, appstream:fleet:DesiredCapacity
|
293
|
+
# })
|
294
|
+
#
|
295
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DeregisterScalableTarget AWS API Documentation
|
296
|
+
#
|
297
|
+
# @overload deregister_scalable_target(params = {})
|
298
|
+
# @param [Hash] params ({})
|
299
|
+
def deregister_scalable_target(params = {}, options = {})
|
300
|
+
req = build_request(:deregister_scalable_target, params)
|
301
|
+
req.send_request(options)
|
302
|
+
end
|
346
303
|
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
357
|
-
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
377
|
-
|
378
|
-
|
379
|
-
|
380
|
-
|
381
|
-
|
382
|
-
|
383
|
-
|
384
|
-
|
385
|
-
|
386
|
-
|
387
|
-
|
388
|
-
|
389
|
-
|
390
|
-
|
391
|
-
|
392
|
-
|
393
|
-
|
394
|
-
|
395
|
-
|
396
|
-
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
402
|
-
|
403
|
-
|
404
|
-
|
405
|
-
|
406
|
-
|
407
|
-
|
408
|
-
|
409
|
-
|
410
|
-
|
411
|
-
|
412
|
-
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
|
417
|
-
|
418
|
-
|
419
|
-
|
420
|
-
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
|
425
|
-
|
426
|
-
|
427
|
-
|
428
|
-
|
429
|
-
|
430
|
-
|
431
|
-
|
432
|
-
|
433
|
-
|
434
|
-
|
435
|
-
|
436
|
-
|
437
|
-
|
304
|
+
# Provides descriptive information about the scalable targets in the
|
305
|
+
# specified namespace.
|
306
|
+
#
|
307
|
+
# You can filter the results using the `ResourceIds` and
|
308
|
+
# `ScalableDimension` parameters.
|
309
|
+
#
|
310
|
+
# To create a scalable target or update an existing one, see
|
311
|
+
# RegisterScalableTarget. If you are no longer using a scalable target,
|
312
|
+
# you can deregister it using DeregisterScalableTarget.
|
313
|
+
#
|
314
|
+
# @option params [required, String] :service_namespace
|
315
|
+
# The namespace of the AWS service. For more information, see [AWS
|
316
|
+
# Service Namespaces][1] in the *Amazon Web Services General Reference*.
|
317
|
+
#
|
318
|
+
#
|
319
|
+
#
|
320
|
+
# [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-aws-service-namespaces
|
321
|
+
#
|
322
|
+
# @option params [Array<String>] :resource_ids
|
323
|
+
# The identifier of the resource associated with the scalable target.
|
324
|
+
# This string consists of the resource type and unique identifier. If
|
325
|
+
# you specify a scalable dimension, you must also specify a resource ID.
|
326
|
+
#
|
327
|
+
# * ECS service - The resource type is `service` and the unique
|
328
|
+
# identifier is the cluster name and service name. Example:
|
329
|
+
# `service/default/sample-webapp`.
|
330
|
+
#
|
331
|
+
# * Spot fleet request - The resource type is `spot-fleet-request` and
|
332
|
+
# the unique identifier is the Spot fleet request ID. Example:
|
333
|
+
# `spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE`.
|
334
|
+
#
|
335
|
+
# * EMR cluster - The resource type is `instancegroup` and the unique
|
336
|
+
# identifier is the cluster ID and instance group ID. Example:
|
337
|
+
# `instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0`.
|
338
|
+
#
|
339
|
+
# * AppStream 2.0 fleet - The resource type is `fleet` and the unique
|
340
|
+
# identifier is the fleet name. Example: `fleet/sample-fleet`.
|
341
|
+
#
|
342
|
+
# @option params [String] :scalable_dimension
|
343
|
+
# The scalable dimension associated with the scalable target. This
|
344
|
+
# string consists of the service namespace, resource type, and scaling
|
345
|
+
# property. If you specify a scalable dimension, you must also specify a
|
346
|
+
# resource ID.
|
347
|
+
#
|
348
|
+
# * `ecs:service:DesiredCount` - The desired task count of an ECS
|
349
|
+
# service.
|
350
|
+
#
|
351
|
+
# * `ec2:spot-fleet-request:TargetCapacity` - The target capacity of a
|
352
|
+
# Spot fleet request.
|
353
|
+
#
|
354
|
+
# * `elasticmapreduce:instancegroup:InstanceCount` - The instance count
|
355
|
+
# of an EMR Instance Group.
|
356
|
+
#
|
357
|
+
# * `appstream:fleet:DesiredCapacity` - The desired capacity of an
|
358
|
+
# AppStream 2.0 fleet.
|
359
|
+
#
|
360
|
+
# @option params [Integer] :max_results
|
361
|
+
# The maximum number of scalable target results. This value can be
|
362
|
+
# between 1 and 50. The default value is 50.
|
363
|
+
#
|
364
|
+
# If this parameter is used, the operation returns up to `MaxResults`
|
365
|
+
# results at a time, along with a `NextToken` value. To get the next set
|
366
|
+
# of results, include the `NextToken` value in a subsequent call. If
|
367
|
+
# this parameter is not used, the operation returns up to 50 results and
|
368
|
+
# a `NextToken` value, if applicable.
|
369
|
+
#
|
370
|
+
# @option params [String] :next_token
|
371
|
+
# The token for the next set of results.
|
372
|
+
#
|
373
|
+
# @return [Types::DescribeScalableTargetsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
374
|
+
#
|
375
|
+
# * {Types::DescribeScalableTargetsResponse#scalable_targets #scalable_targets} => Array<Types::ScalableTarget>
|
376
|
+
# * {Types::DescribeScalableTargetsResponse#next_token #next_token} => String
|
377
|
+
#
|
378
|
+
# @example Request syntax with placeholder values
|
379
|
+
#
|
380
|
+
# resp = client.describe_scalable_targets({
|
381
|
+
# service_namespace: "ecs", # required, accepts ecs, elasticmapreduce, ec2, appstream
|
382
|
+
# resource_ids: ["ResourceIdMaxLen1600"],
|
383
|
+
# scalable_dimension: "ecs:service:DesiredCount", # accepts ecs:service:DesiredCount, ec2:spot-fleet-request:TargetCapacity, elasticmapreduce:instancegroup:InstanceCount, appstream:fleet:DesiredCapacity
|
384
|
+
# max_results: 1,
|
385
|
+
# next_token: "XmlString",
|
386
|
+
# })
|
387
|
+
#
|
388
|
+
# @example Response structure
|
389
|
+
#
|
390
|
+
# resp.scalable_targets #=> Array
|
391
|
+
# resp.scalable_targets[0].service_namespace #=> String, one of "ecs", "elasticmapreduce", "ec2", "appstream"
|
392
|
+
# resp.scalable_targets[0].resource_id #=> String
|
393
|
+
# resp.scalable_targets[0].scalable_dimension #=> String, one of "ecs:service:DesiredCount", "ec2:spot-fleet-request:TargetCapacity", "elasticmapreduce:instancegroup:InstanceCount", "appstream:fleet:DesiredCapacity"
|
394
|
+
# resp.scalable_targets[0].min_capacity #=> Integer
|
395
|
+
# resp.scalable_targets[0].max_capacity #=> Integer
|
396
|
+
# resp.scalable_targets[0].role_arn #=> String
|
397
|
+
# resp.scalable_targets[0].creation_time #=> Time
|
398
|
+
# resp.next_token #=> String
|
399
|
+
#
|
400
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DescribeScalableTargets AWS API Documentation
|
401
|
+
#
|
402
|
+
# @overload describe_scalable_targets(params = {})
|
403
|
+
# @param [Hash] params ({})
|
404
|
+
def describe_scalable_targets(params = {}, options = {})
|
405
|
+
req = build_request(:describe_scalable_targets, params)
|
406
|
+
req.send_request(options)
|
407
|
+
end
|
438
408
|
|
439
|
-
|
440
|
-
|
441
|
-
|
442
|
-
|
443
|
-
|
444
|
-
|
445
|
-
|
446
|
-
|
447
|
-
|
448
|
-
|
449
|
-
|
450
|
-
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
|
455
|
-
|
456
|
-
|
457
|
-
|
458
|
-
|
459
|
-
|
460
|
-
|
461
|
-
|
462
|
-
|
463
|
-
|
464
|
-
|
465
|
-
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
|
483
|
-
|
484
|
-
|
485
|
-
|
486
|
-
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
|
492
|
-
|
493
|
-
|
494
|
-
|
495
|
-
|
496
|
-
|
497
|
-
|
498
|
-
|
499
|
-
|
500
|
-
|
501
|
-
|
502
|
-
|
503
|
-
|
504
|
-
|
505
|
-
|
506
|
-
|
507
|
-
|
508
|
-
|
509
|
-
|
510
|
-
|
511
|
-
|
512
|
-
|
513
|
-
|
514
|
-
|
515
|
-
|
516
|
-
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
|
521
|
-
|
522
|
-
|
523
|
-
|
524
|
-
|
525
|
-
|
526
|
-
|
527
|
-
|
528
|
-
|
529
|
-
|
530
|
-
|
531
|
-
|
532
|
-
|
533
|
-
|
534
|
-
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
|
409
|
+
# Provides descriptive information about the scaling activities in the
|
410
|
+
# specified namespace from the previous six weeks.
|
411
|
+
#
|
412
|
+
# You can filter the results using the `ResourceId` and
|
413
|
+
# `ScalableDimension` parameters.
|
414
|
+
#
|
415
|
+
# Scaling activities are triggered by CloudWatch alarms that are
|
416
|
+
# associated with scaling policies. To view the scaling policies for a
|
417
|
+
# service namespace, see DescribeScalingPolicies. To create a scaling
|
418
|
+
# policy or update an existing one, see PutScalingPolicy.
|
419
|
+
#
|
420
|
+
# @option params [required, String] :service_namespace
|
421
|
+
# The namespace of the AWS service. For more information, see [AWS
|
422
|
+
# Service Namespaces][1] in the *Amazon Web Services General Reference*.
|
423
|
+
#
|
424
|
+
#
|
425
|
+
#
|
426
|
+
# [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-aws-service-namespaces
|
427
|
+
#
|
428
|
+
# @option params [String] :resource_id
|
429
|
+
# The identifier of the resource associated with the scaling activity.
|
430
|
+
# This string consists of the resource type and unique identifier. If
|
431
|
+
# you specify a scalable dimension, you must also specify a resource ID.
|
432
|
+
#
|
433
|
+
# * ECS service - The resource type is `service` and the unique
|
434
|
+
# identifier is the cluster name and service name. Example:
|
435
|
+
# `service/default/sample-webapp`.
|
436
|
+
#
|
437
|
+
# * Spot fleet request - The resource type is `spot-fleet-request` and
|
438
|
+
# the unique identifier is the Spot fleet request ID. Example:
|
439
|
+
# `spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE`.
|
440
|
+
#
|
441
|
+
# * EMR cluster - The resource type is `instancegroup` and the unique
|
442
|
+
# identifier is the cluster ID and instance group ID. Example:
|
443
|
+
# `instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0`.
|
444
|
+
#
|
445
|
+
# * AppStream 2.0 fleet - The resource type is `fleet` and the unique
|
446
|
+
# identifier is the fleet name. Example: `fleet/sample-fleet`.
|
447
|
+
#
|
448
|
+
# @option params [String] :scalable_dimension
|
449
|
+
# The scalable dimension. This string consists of the service namespace,
|
450
|
+
# resource type, and scaling property. If you specify a scalable
|
451
|
+
# dimension, you must also specify a resource ID.
|
452
|
+
#
|
453
|
+
# * `ecs:service:DesiredCount` - The desired task count of an ECS
|
454
|
+
# service.
|
455
|
+
#
|
456
|
+
# * `ec2:spot-fleet-request:TargetCapacity` - The target capacity of a
|
457
|
+
# Spot fleet request.
|
458
|
+
#
|
459
|
+
# * `elasticmapreduce:instancegroup:InstanceCount` - The instance count
|
460
|
+
# of an EMR Instance Group.
|
461
|
+
#
|
462
|
+
# * `appstream:fleet:DesiredCapacity` - The desired capacity of an
|
463
|
+
# AppStream 2.0 fleet.
|
464
|
+
#
|
465
|
+
# @option params [Integer] :max_results
|
466
|
+
# The maximum number of scalable target results. This value can be
|
467
|
+
# between 1 and 50. The default value is 50.
|
468
|
+
#
|
469
|
+
# If this parameter is used, the operation returns up to `MaxResults`
|
470
|
+
# results at a time, along with a `NextToken` value. To get the next set
|
471
|
+
# of results, include the `NextToken` value in a subsequent call. If
|
472
|
+
# this parameter is not used, the operation returns up to 50 results and
|
473
|
+
# a `NextToken` value, if applicable.
|
474
|
+
#
|
475
|
+
# @option params [String] :next_token
|
476
|
+
# The token for the next set of results.
|
477
|
+
#
|
478
|
+
# @return [Types::DescribeScalingActivitiesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
479
|
+
#
|
480
|
+
# * {Types::DescribeScalingActivitiesResponse#scaling_activities #scaling_activities} => Array<Types::ScalingActivity>
|
481
|
+
# * {Types::DescribeScalingActivitiesResponse#next_token #next_token} => String
|
482
|
+
#
|
483
|
+
# @example Request syntax with placeholder values
|
484
|
+
#
|
485
|
+
# resp = client.describe_scaling_activities({
|
486
|
+
# service_namespace: "ecs", # required, accepts ecs, elasticmapreduce, ec2, appstream
|
487
|
+
# resource_id: "ResourceIdMaxLen1600",
|
488
|
+
# scalable_dimension: "ecs:service:DesiredCount", # accepts ecs:service:DesiredCount, ec2:spot-fleet-request:TargetCapacity, elasticmapreduce:instancegroup:InstanceCount, appstream:fleet:DesiredCapacity
|
489
|
+
# max_results: 1,
|
490
|
+
# next_token: "XmlString",
|
491
|
+
# })
|
492
|
+
#
|
493
|
+
# @example Response structure
|
494
|
+
#
|
495
|
+
# resp.scaling_activities #=> Array
|
496
|
+
# resp.scaling_activities[0].activity_id #=> String
|
497
|
+
# resp.scaling_activities[0].service_namespace #=> String, one of "ecs", "elasticmapreduce", "ec2", "appstream"
|
498
|
+
# resp.scaling_activities[0].resource_id #=> String
|
499
|
+
# resp.scaling_activities[0].scalable_dimension #=> String, one of "ecs:service:DesiredCount", "ec2:spot-fleet-request:TargetCapacity", "elasticmapreduce:instancegroup:InstanceCount", "appstream:fleet:DesiredCapacity"
|
500
|
+
# resp.scaling_activities[0].description #=> String
|
501
|
+
# resp.scaling_activities[0].cause #=> String
|
502
|
+
# resp.scaling_activities[0].start_time #=> Time
|
503
|
+
# resp.scaling_activities[0].end_time #=> Time
|
504
|
+
# resp.scaling_activities[0].status_code #=> String, one of "Pending", "InProgress", "Successful", "Overridden", "Unfulfilled", "Failed"
|
505
|
+
# resp.scaling_activities[0].status_message #=> String
|
506
|
+
# resp.scaling_activities[0].details #=> String
|
507
|
+
# resp.next_token #=> String
|
508
|
+
#
|
509
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DescribeScalingActivities AWS API Documentation
|
510
|
+
#
|
511
|
+
# @overload describe_scaling_activities(params = {})
|
512
|
+
# @param [Hash] params ({})
|
513
|
+
def describe_scaling_activities(params = {}, options = {})
|
514
|
+
req = build_request(:describe_scaling_activities, params)
|
515
|
+
req.send_request(options)
|
516
|
+
end
|
539
517
|
|
540
|
-
|
541
|
-
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
546
|
-
|
547
|
-
|
548
|
-
|
549
|
-
|
550
|
-
|
551
|
-
|
552
|
-
|
553
|
-
|
554
|
-
|
555
|
-
|
556
|
-
|
557
|
-
|
558
|
-
|
559
|
-
|
560
|
-
|
561
|
-
|
562
|
-
|
563
|
-
|
564
|
-
|
565
|
-
|
566
|
-
|
567
|
-
|
568
|
-
|
569
|
-
|
570
|
-
|
571
|
-
|
572
|
-
|
573
|
-
|
574
|
-
|
575
|
-
|
576
|
-
|
577
|
-
|
578
|
-
|
579
|
-
|
580
|
-
|
581
|
-
|
582
|
-
|
583
|
-
|
584
|
-
|
585
|
-
|
586
|
-
|
587
|
-
|
588
|
-
|
589
|
-
|
590
|
-
|
591
|
-
|
592
|
-
|
593
|
-
|
594
|
-
|
595
|
-
|
596
|
-
|
597
|
-
|
598
|
-
|
599
|
-
|
600
|
-
|
601
|
-
|
602
|
-
|
603
|
-
|
604
|
-
|
605
|
-
|
606
|
-
|
607
|
-
|
608
|
-
|
609
|
-
|
610
|
-
|
611
|
-
|
612
|
-
|
613
|
-
|
614
|
-
|
615
|
-
|
616
|
-
|
617
|
-
|
618
|
-
|
619
|
-
|
620
|
-
|
621
|
-
|
622
|
-
|
623
|
-
|
624
|
-
|
625
|
-
|
626
|
-
|
627
|
-
|
628
|
-
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
|
633
|
-
|
634
|
-
|
518
|
+
# Provides descriptive information about the scaling policies in the
|
519
|
+
# specified namespace.
|
520
|
+
#
|
521
|
+
# You can filter the results using the `ResourceId`,
|
522
|
+
# `ScalableDimension`, and `PolicyNames` parameters.
|
523
|
+
#
|
524
|
+
# To create a scaling policy or update an existing one, see
|
525
|
+
# PutScalingPolicy. If you are no longer using a scaling policy, you can
|
526
|
+
# delete it using DeleteScalingPolicy.
|
527
|
+
#
|
528
|
+
# @option params [Array<String>] :policy_names
|
529
|
+
# The names of the scaling policies to describe.
|
530
|
+
#
|
531
|
+
# @option params [required, String] :service_namespace
|
532
|
+
# The namespace of the AWS service. For more information, see [AWS
|
533
|
+
# Service Namespaces][1] in the *Amazon Web Services General Reference*.
|
534
|
+
#
|
535
|
+
#
|
536
|
+
#
|
537
|
+
# [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-aws-service-namespaces
|
538
|
+
#
|
539
|
+
# @option params [String] :resource_id
|
540
|
+
# The identifier of the resource associated with the scaling policy.
|
541
|
+
# This string consists of the resource type and unique identifier. If
|
542
|
+
# you specify a scalable dimension, you must also specify a resource ID.
|
543
|
+
#
|
544
|
+
# * ECS service - The resource type is `service` and the unique
|
545
|
+
# identifier is the cluster name and service name. Example:
|
546
|
+
# `service/default/sample-webapp`.
|
547
|
+
#
|
548
|
+
# * Spot fleet request - The resource type is `spot-fleet-request` and
|
549
|
+
# the unique identifier is the Spot fleet request ID. Example:
|
550
|
+
# `spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE`.
|
551
|
+
#
|
552
|
+
# * EMR cluster - The resource type is `instancegroup` and the unique
|
553
|
+
# identifier is the cluster ID and instance group ID. Example:
|
554
|
+
# `instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0`.
|
555
|
+
#
|
556
|
+
# * AppStream 2.0 fleet - The resource type is `fleet` and the unique
|
557
|
+
# identifier is the fleet name. Example: `fleet/sample-fleet`.
|
558
|
+
#
|
559
|
+
# @option params [String] :scalable_dimension
|
560
|
+
# The scalable dimension. This string consists of the service namespace,
|
561
|
+
# resource type, and scaling property. If you specify a scalable
|
562
|
+
# dimension, you must also specify a resource ID.
|
563
|
+
#
|
564
|
+
# * `ecs:service:DesiredCount` - The desired task count of an ECS
|
565
|
+
# service.
|
566
|
+
#
|
567
|
+
# * `ec2:spot-fleet-request:TargetCapacity` - The target capacity of a
|
568
|
+
# Spot fleet request.
|
569
|
+
#
|
570
|
+
# * `elasticmapreduce:instancegroup:InstanceCount` - The instance count
|
571
|
+
# of an EMR Instance Group.
|
572
|
+
#
|
573
|
+
# * `appstream:fleet:DesiredCapacity` - The desired capacity of an
|
574
|
+
# AppStream 2.0 fleet.
|
575
|
+
#
|
576
|
+
# @option params [Integer] :max_results
|
577
|
+
# The maximum number of scalable target results. This value can be
|
578
|
+
# between 1 and 50. The default value is 50.
|
579
|
+
#
|
580
|
+
# If this parameter is used, the operation returns up to `MaxResults`
|
581
|
+
# results at a time, along with a `NextToken` value. To get the next set
|
582
|
+
# of results, include the `NextToken` value in a subsequent call. If
|
583
|
+
# this parameter is not used, the operation returns up to 50 results and
|
584
|
+
# a `NextToken` value, if applicable.
|
585
|
+
#
|
586
|
+
# @option params [String] :next_token
|
587
|
+
# The token for the next set of results.
|
588
|
+
#
|
589
|
+
# @return [Types::DescribeScalingPoliciesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
590
|
+
#
|
591
|
+
# * {Types::DescribeScalingPoliciesResponse#scaling_policies #scaling_policies} => Array<Types::ScalingPolicy>
|
592
|
+
# * {Types::DescribeScalingPoliciesResponse#next_token #next_token} => String
|
593
|
+
#
|
594
|
+
# @example Request syntax with placeholder values
|
595
|
+
#
|
596
|
+
# resp = client.describe_scaling_policies({
|
597
|
+
# policy_names: ["ResourceIdMaxLen1600"],
|
598
|
+
# service_namespace: "ecs", # required, accepts ecs, elasticmapreduce, ec2, appstream
|
599
|
+
# resource_id: "ResourceIdMaxLen1600",
|
600
|
+
# scalable_dimension: "ecs:service:DesiredCount", # accepts ecs:service:DesiredCount, ec2:spot-fleet-request:TargetCapacity, elasticmapreduce:instancegroup:InstanceCount, appstream:fleet:DesiredCapacity
|
601
|
+
# max_results: 1,
|
602
|
+
# next_token: "XmlString",
|
603
|
+
# })
|
604
|
+
#
|
605
|
+
# @example Response structure
|
606
|
+
#
|
607
|
+
# resp.scaling_policies #=> Array
|
608
|
+
# resp.scaling_policies[0].policy_arn #=> String
|
609
|
+
# resp.scaling_policies[0].policy_name #=> String
|
610
|
+
# resp.scaling_policies[0].service_namespace #=> String, one of "ecs", "elasticmapreduce", "ec2", "appstream"
|
611
|
+
# resp.scaling_policies[0].resource_id #=> String
|
612
|
+
# resp.scaling_policies[0].scalable_dimension #=> String, one of "ecs:service:DesiredCount", "ec2:spot-fleet-request:TargetCapacity", "elasticmapreduce:instancegroup:InstanceCount", "appstream:fleet:DesiredCapacity"
|
613
|
+
# resp.scaling_policies[0].policy_type #=> String, one of "StepScaling"
|
614
|
+
# resp.scaling_policies[0].step_scaling_policy_configuration.adjustment_type #=> String, one of "ChangeInCapacity", "PercentChangeInCapacity", "ExactCapacity"
|
615
|
+
# resp.scaling_policies[0].step_scaling_policy_configuration.step_adjustments #=> Array
|
616
|
+
# resp.scaling_policies[0].step_scaling_policy_configuration.step_adjustments[0].metric_interval_lower_bound #=> Float
|
617
|
+
# resp.scaling_policies[0].step_scaling_policy_configuration.step_adjustments[0].metric_interval_upper_bound #=> Float
|
618
|
+
# resp.scaling_policies[0].step_scaling_policy_configuration.step_adjustments[0].scaling_adjustment #=> Integer
|
619
|
+
# resp.scaling_policies[0].step_scaling_policy_configuration.min_adjustment_magnitude #=> Integer
|
620
|
+
# resp.scaling_policies[0].step_scaling_policy_configuration.cooldown #=> Integer
|
621
|
+
# resp.scaling_policies[0].step_scaling_policy_configuration.metric_aggregation_type #=> String, one of "Average", "Minimum", "Maximum"
|
622
|
+
# resp.scaling_policies[0].alarms #=> Array
|
623
|
+
# resp.scaling_policies[0].alarms[0].alarm_name #=> String
|
624
|
+
# resp.scaling_policies[0].alarms[0].alarm_arn #=> String
|
625
|
+
# resp.scaling_policies[0].creation_time #=> Time
|
626
|
+
# resp.next_token #=> String
|
627
|
+
#
|
628
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DescribeScalingPolicies AWS API Documentation
|
629
|
+
#
|
630
|
+
# @overload describe_scaling_policies(params = {})
|
631
|
+
# @param [Hash] params ({})
|
632
|
+
def describe_scaling_policies(params = {}, options = {})
|
633
|
+
req = build_request(:describe_scaling_policies, params)
|
634
|
+
req.send_request(options)
|
635
|
+
end
|
635
636
|
|
636
|
-
|
637
|
-
|
638
|
-
|
639
|
-
|
640
|
-
|
641
|
-
|
642
|
-
|
643
|
-
|
644
|
-
|
645
|
-
|
646
|
-
|
647
|
-
|
648
|
-
|
649
|
-
|
650
|
-
|
651
|
-
|
652
|
-
|
653
|
-
|
654
|
-
|
655
|
-
|
656
|
-
|
657
|
-
|
658
|
-
|
659
|
-
|
660
|
-
|
661
|
-
|
662
|
-
|
663
|
-
|
664
|
-
|
665
|
-
|
666
|
-
|
667
|
-
|
668
|
-
|
669
|
-
|
670
|
-
|
671
|
-
|
672
|
-
|
673
|
-
|
674
|
-
|
675
|
-
|
676
|
-
|
677
|
-
|
678
|
-
|
679
|
-
|
680
|
-
|
681
|
-
|
682
|
-
|
683
|
-
|
684
|
-
|
685
|
-
|
686
|
-
|
687
|
-
|
688
|
-
|
689
|
-
|
690
|
-
|
691
|
-
|
692
|
-
|
693
|
-
|
694
|
-
|
695
|
-
|
696
|
-
|
697
|
-
|
698
|
-
|
699
|
-
|
700
|
-
|
701
|
-
|
702
|
-
|
703
|
-
|
704
|
-
|
705
|
-
|
706
|
-
|
707
|
-
|
708
|
-
|
709
|
-
|
710
|
-
|
637
|
+
# Creates or updates a policy for an Application Auto Scaling scalable
|
638
|
+
# target.
|
639
|
+
#
|
640
|
+
# Each scalable target is identified by a service namespace, resource
|
641
|
+
# ID, and scalable dimension. A scaling policy applies to the scalable
|
642
|
+
# target identified by those three attributes. You cannot create a
|
643
|
+
# scaling policy without first registering a scalable target using
|
644
|
+
# RegisterScalableTarget.
|
645
|
+
#
|
646
|
+
# To update a policy, specify its policy name and the parameters that
|
647
|
+
# you want to change. Any parameters that you don't specify are not
|
648
|
+
# changed by this update request.
|
649
|
+
#
|
650
|
+
# You can view the scaling policies for a service namespace using
|
651
|
+
# DescribeScalingPolicies. If you are no longer using a scaling policy,
|
652
|
+
# you can delete it using DeleteScalingPolicy.
|
653
|
+
#
|
654
|
+
# @option params [required, String] :policy_name
|
655
|
+
# The name of the scaling policy.
|
656
|
+
#
|
657
|
+
# @option params [required, String] :service_namespace
|
658
|
+
# The namespace of the AWS service. For more information, see [AWS
|
659
|
+
# Service Namespaces][1] in the *Amazon Web Services General Reference*.
|
660
|
+
#
|
661
|
+
#
|
662
|
+
#
|
663
|
+
# [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-aws-service-namespaces
|
664
|
+
#
|
665
|
+
# @option params [required, String] :resource_id
|
666
|
+
# The identifier of the resource associated with the scaling policy.
|
667
|
+
# This string consists of the resource type and unique identifier.
|
668
|
+
#
|
669
|
+
# * ECS service - The resource type is `service` and the unique
|
670
|
+
# identifier is the cluster name and service name. Example:
|
671
|
+
# `service/default/sample-webapp`.
|
672
|
+
#
|
673
|
+
# * Spot fleet request - The resource type is `spot-fleet-request` and
|
674
|
+
# the unique identifier is the Spot fleet request ID. Example:
|
675
|
+
# `spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE`.
|
676
|
+
#
|
677
|
+
# * EMR cluster - The resource type is `instancegroup` and the unique
|
678
|
+
# identifier is the cluster ID and instance group ID. Example:
|
679
|
+
# `instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0`.
|
680
|
+
#
|
681
|
+
# * AppStream 2.0 fleet - The resource type is `fleet` and the unique
|
682
|
+
# identifier is the fleet name. Example: `fleet/sample-fleet`.
|
683
|
+
#
|
684
|
+
# @option params [required, String] :scalable_dimension
|
685
|
+
# The scalable dimension. This string consists of the service namespace,
|
686
|
+
# resource type, and scaling property.
|
687
|
+
#
|
688
|
+
# * `ecs:service:DesiredCount` - The desired task count of an ECS
|
689
|
+
# service.
|
690
|
+
#
|
691
|
+
# * `ec2:spot-fleet-request:TargetCapacity` - The target capacity of a
|
692
|
+
# Spot fleet request.
|
693
|
+
#
|
694
|
+
# * `elasticmapreduce:instancegroup:InstanceCount` - The instance count
|
695
|
+
# of an EMR Instance Group.
|
696
|
+
#
|
697
|
+
# * `appstream:fleet:DesiredCapacity` - The desired capacity of an
|
698
|
+
# AppStream 2.0 fleet.
|
699
|
+
#
|
700
|
+
# @option params [String] :policy_type
|
701
|
+
# The policy type. If you are creating a new policy, this parameter is
|
702
|
+
# required. If you are updating a policy, this parameter is not
|
703
|
+
# required.
|
704
|
+
#
|
705
|
+
# @option params [Types::StepScalingPolicyConfiguration] :step_scaling_policy_configuration
|
706
|
+
# The configuration for the step scaling policy. If you are creating a
|
707
|
+
# new policy, this parameter is required. If you are updating a policy,
|
708
|
+
# this parameter is not required. For more information, see
|
709
|
+
# StepScalingPolicyConfiguration and StepAdjustment.
|
710
|
+
#
|
711
|
+
# @return [Types::PutScalingPolicyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
712
|
+
#
|
713
|
+
# * {Types::PutScalingPolicyResponse#policy_arn #policy_arn} => String
|
714
|
+
#
|
715
|
+
# @example Request syntax with placeholder values
|
716
|
+
#
|
717
|
+
# resp = client.put_scaling_policy({
|
718
|
+
# policy_name: "PolicyName", # required
|
719
|
+
# service_namespace: "ecs", # required, accepts ecs, elasticmapreduce, ec2, appstream
|
720
|
+
# resource_id: "ResourceIdMaxLen1600", # required
|
721
|
+
# scalable_dimension: "ecs:service:DesiredCount", # required, accepts ecs:service:DesiredCount, ec2:spot-fleet-request:TargetCapacity, elasticmapreduce:instancegroup:InstanceCount, appstream:fleet:DesiredCapacity
|
722
|
+
# policy_type: "StepScaling", # accepts StepScaling
|
723
|
+
# step_scaling_policy_configuration: {
|
724
|
+
# adjustment_type: "ChangeInCapacity", # accepts ChangeInCapacity, PercentChangeInCapacity, ExactCapacity
|
725
|
+
# step_adjustments: [
|
726
|
+
# {
|
727
|
+
# metric_interval_lower_bound: 1.0,
|
728
|
+
# metric_interval_upper_bound: 1.0,
|
729
|
+
# scaling_adjustment: 1, # required
|
730
|
+
# },
|
731
|
+
# ],
|
732
|
+
# min_adjustment_magnitude: 1,
|
733
|
+
# cooldown: 1,
|
734
|
+
# metric_aggregation_type: "Average", # accepts Average, Minimum, Maximum
|
735
|
+
# },
|
736
|
+
# })
|
737
|
+
#
|
738
|
+
# @example Response structure
|
739
|
+
#
|
740
|
+
# resp.policy_arn #=> String
|
741
|
+
#
|
742
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/PutScalingPolicy AWS API Documentation
|
743
|
+
#
|
744
|
+
# @overload put_scaling_policy(params = {})
|
745
|
+
# @param [Hash] params ({})
|
746
|
+
def put_scaling_policy(params = {}, options = {})
|
747
|
+
req = build_request(:put_scaling_policy, params)
|
748
|
+
req.send_request(options)
|
749
|
+
end
|
711
750
|
|
712
|
-
|
751
|
+
# Registers or updates a scalable target. A scalable target is a
|
752
|
+
# resource that Application Auto Scaling can scale out or scale in.
|
753
|
+
# After you have registered a scalable target, you can use this
|
754
|
+
# operation to update the minimum and maximum values for your scalable
|
755
|
+
# dimension.
|
756
|
+
#
|
757
|
+
# After you register a scalable target, you can create and apply scaling
|
758
|
+
# policies using PutScalingPolicy. You can view the scaling policies for
|
759
|
+
# a service namespace using DescribeScalableTargets. If you are no
|
760
|
+
# longer using a scalable target, you can deregister it using
|
761
|
+
# DeregisterScalableTarget.
|
762
|
+
#
|
763
|
+
# @option params [required, String] :service_namespace
|
764
|
+
# The namespace of the AWS service. For more information, see [AWS
|
765
|
+
# Service Namespaces][1] in the *Amazon Web Services General Reference*.
|
766
|
+
#
|
767
|
+
#
|
768
|
+
#
|
769
|
+
# [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-aws-service-namespaces
|
770
|
+
#
|
771
|
+
# @option params [required, String] :resource_id
|
772
|
+
# The identifier of the resource associated with the scalable target.
|
773
|
+
# This string consists of the resource type and unique identifier.
|
774
|
+
#
|
775
|
+
# * ECS service - The resource type is `service` and the unique
|
776
|
+
# identifier is the cluster name and service name. Example:
|
777
|
+
# `service/default/sample-webapp`.
|
778
|
+
#
|
779
|
+
# * Spot fleet request - The resource type is `spot-fleet-request` and
|
780
|
+
# the unique identifier is the Spot fleet request ID. Example:
|
781
|
+
# `spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE`.
|
782
|
+
#
|
783
|
+
# * EMR cluster - The resource type is `instancegroup` and the unique
|
784
|
+
# identifier is the cluster ID and instance group ID. Example:
|
785
|
+
# `instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0`.
|
786
|
+
#
|
787
|
+
# * AppStream 2.0 fleet - The resource type is `fleet` and the unique
|
788
|
+
# identifier is the fleet name. Example: `fleet/sample-fleet`.
|
789
|
+
#
|
790
|
+
# @option params [required, String] :scalable_dimension
|
791
|
+
# The scalable dimension associated with the scalable target. This
|
792
|
+
# string consists of the service namespace, resource type, and scaling
|
793
|
+
# property.
|
794
|
+
#
|
795
|
+
# * `ecs:service:DesiredCount` - The desired task count of an ECS
|
796
|
+
# service.
|
797
|
+
#
|
798
|
+
# * `ec2:spot-fleet-request:TargetCapacity` - The target capacity of a
|
799
|
+
# Spot fleet request.
|
800
|
+
#
|
801
|
+
# * `elasticmapreduce:instancegroup:InstanceCount` - The instance count
|
802
|
+
# of an EMR Instance Group.
|
803
|
+
#
|
804
|
+
# * `appstream:fleet:DesiredCapacity` - The desired capacity of an
|
805
|
+
# AppStream 2.0 fleet.
|
806
|
+
#
|
807
|
+
# @option params [Integer] :min_capacity
|
808
|
+
# The minimum value to scale to in response to a scale in event. This
|
809
|
+
# parameter is required if you are registering a scalable target and
|
810
|
+
# optional if you are updating one.
|
811
|
+
#
|
812
|
+
# @option params [Integer] :max_capacity
|
813
|
+
# The maximum value to scale to in response to a scale out event. This
|
814
|
+
# parameter is required if you are registering a scalable target and
|
815
|
+
# optional if you are updating one.
|
816
|
+
#
|
817
|
+
# @option params [String] :role_arn
|
818
|
+
# The ARN of an IAM role that allows Application Auto Scaling to modify
|
819
|
+
# the scalable target on your behalf. This parameter is required when
|
820
|
+
# you register a scalable target and optional when you update one.
|
821
|
+
#
|
822
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
823
|
+
#
|
824
|
+
# @example Request syntax with placeholder values
|
825
|
+
#
|
826
|
+
# resp = client.register_scalable_target({
|
827
|
+
# service_namespace: "ecs", # required, accepts ecs, elasticmapreduce, ec2, appstream
|
828
|
+
# resource_id: "ResourceIdMaxLen1600", # required
|
829
|
+
# scalable_dimension: "ecs:service:DesiredCount", # required, accepts ecs:service:DesiredCount, ec2:spot-fleet-request:TargetCapacity, elasticmapreduce:instancegroup:InstanceCount, appstream:fleet:DesiredCapacity
|
830
|
+
# min_capacity: 1,
|
831
|
+
# max_capacity: 1,
|
832
|
+
# role_arn: "ResourceIdMaxLen1600",
|
833
|
+
# })
|
834
|
+
#
|
835
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/RegisterScalableTarget AWS API Documentation
|
836
|
+
#
|
837
|
+
# @overload register_scalable_target(params = {})
|
838
|
+
# @param [Hash] params ({})
|
839
|
+
def register_scalable_target(params = {}, options = {})
|
840
|
+
req = build_request(:register_scalable_target, params)
|
841
|
+
req.send_request(options)
|
842
|
+
end
|
713
843
|
|
714
|
-
|
715
|
-
# @api private
|
716
|
-
def build_request(operation_name, params = {})
|
717
|
-
handlers = @handlers.for(operation_name)
|
718
|
-
context = Seahorse::Client::RequestContext.new(
|
719
|
-
operation_name: operation_name,
|
720
|
-
operation: config.api.operation(operation_name),
|
721
|
-
client: self,
|
722
|
-
params: params,
|
723
|
-
config: config)
|
724
|
-
context[:gem_name] = 'aws-sdk-applicationautoscaling'
|
725
|
-
context[:gem_version] = '1.0.0.rc1'
|
726
|
-
Seahorse::Client::Request.new(handlers, context)
|
727
|
-
end
|
844
|
+
# @!endgroup
|
728
845
|
|
729
|
-
|
730
|
-
|
731
|
-
|
732
|
-
|
733
|
-
|
846
|
+
# @param params ({})
|
847
|
+
# @api private
|
848
|
+
def build_request(operation_name, params = {})
|
849
|
+
handlers = @handlers.for(operation_name)
|
850
|
+
context = Seahorse::Client::RequestContext.new(
|
851
|
+
operation_name: operation_name,
|
852
|
+
operation: config.api.operation(operation_name),
|
853
|
+
client: self,
|
854
|
+
params: params,
|
855
|
+
config: config)
|
856
|
+
context[:gem_name] = 'aws-sdk-applicationautoscaling'
|
857
|
+
context[:gem_version] = '1.0.0.rc2'
|
858
|
+
Seahorse::Client::Request.new(handlers, context)
|
859
|
+
end
|
734
860
|
|
735
|
-
|
861
|
+
# @api private
|
862
|
+
# @deprecated
|
863
|
+
def waiter_names
|
864
|
+
[]
|
865
|
+
end
|
736
866
|
|
737
|
-
|
738
|
-
attr_reader :identifier
|
867
|
+
class << self
|
739
868
|
|
740
|
-
|
741
|
-
|
742
|
-
Errors
|
743
|
-
end
|
869
|
+
# @api private
|
870
|
+
attr_reader :identifier
|
744
871
|
|
872
|
+
# @api private
|
873
|
+
def errors_module
|
874
|
+
Errors
|
745
875
|
end
|
876
|
+
|
746
877
|
end
|
747
878
|
end
|
748
879
|
end
|