@aws-sdk/client-application-auto-scaling 3.183.0 → 3.185.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/dist-cjs/protocols/Aws_json1_1.js +2 -2
- package/dist-es/ApplicationAutoScaling.js +49 -42
- package/dist-es/ApplicationAutoScalingClient.js +28 -22
- package/dist-es/commands/DeleteScalingPolicyCommand.js +28 -21
- package/dist-es/commands/DeleteScheduledActionCommand.js +28 -21
- package/dist-es/commands/DeregisterScalableTargetCommand.js +28 -21
- package/dist-es/commands/DescribeScalableTargetsCommand.js +28 -21
- package/dist-es/commands/DescribeScalingActivitiesCommand.js +28 -21
- package/dist-es/commands/DescribeScalingPoliciesCommand.js +28 -21
- package/dist-es/commands/DescribeScheduledActionsCommand.js +28 -21
- package/dist-es/commands/PutScalingPolicyCommand.js +28 -21
- package/dist-es/commands/PutScheduledActionCommand.js +28 -21
- package/dist-es/commands/RegisterScalableTargetCommand.js +28 -21
- package/dist-es/endpoints.js +8 -8
- package/dist-es/models/ApplicationAutoScalingServiceException.js +10 -5
- package/dist-es/models/models_0.js +118 -183
- package/dist-es/pagination/DescribeScalableTargetsPaginator.js +68 -25
- package/dist-es/pagination/DescribeScalingActivitiesPaginator.js +68 -25
- package/dist-es/pagination/DescribeScalingPoliciesPaginator.js +68 -25
- package/dist-es/pagination/DescribeScheduledActionsPaginator.js +68 -25
- package/dist-es/protocols/Aws_json1_1.js +1004 -848
- package/dist-es/runtimeConfig.browser.js +12 -26
- package/dist-es/runtimeConfig.js +12 -30
- package/dist-es/runtimeConfig.native.js +5 -8
- package/dist-es/runtimeConfig.shared.js +11 -8
- package/package.json +5 -5
|
@@ -1,803 +1,936 @@
|
|
|
1
|
+
import { __assign, __awaiter, __generator } from "tslib";
|
|
1
2
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
2
3
|
import { decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectString as __expectString, limitedParseDouble as __limitedParseDouble, parseEpochTimestamp as __parseEpochTimestamp, serializeFloat as __serializeFloat, throwDefaultError, } from "@aws-sdk/smithy-client";
|
|
3
4
|
import { ApplicationAutoScalingServiceException as __BaseException } from "../models/ApplicationAutoScalingServiceException";
|
|
4
5
|
import { ConcurrentUpdateException, FailedResourceAccessException, InternalServiceException, InvalidNextTokenException, LimitExceededException, ObjectNotFoundException, ValidationException, } from "../models/models_0";
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
export const serializeAws_json1_1DeleteScheduledActionCommand = async (input, context) => {
|
|
15
|
-
const headers = {
|
|
16
|
-
"content-type": "application/x-amz-json-1.1",
|
|
17
|
-
"x-amz-target": "AnyScaleFrontendService.DeleteScheduledAction",
|
|
18
|
-
};
|
|
19
|
-
let body;
|
|
20
|
-
body = JSON.stringify(serializeAws_json1_1DeleteScheduledActionRequest(input, context));
|
|
21
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
22
|
-
};
|
|
23
|
-
export const serializeAws_json1_1DeregisterScalableTargetCommand = async (input, context) => {
|
|
24
|
-
const headers = {
|
|
25
|
-
"content-type": "application/x-amz-json-1.1",
|
|
26
|
-
"x-amz-target": "AnyScaleFrontendService.DeregisterScalableTarget",
|
|
27
|
-
};
|
|
28
|
-
let body;
|
|
29
|
-
body = JSON.stringify(serializeAws_json1_1DeregisterScalableTargetRequest(input, context));
|
|
30
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
31
|
-
};
|
|
32
|
-
export const serializeAws_json1_1DescribeScalableTargetsCommand = async (input, context) => {
|
|
33
|
-
const headers = {
|
|
34
|
-
"content-type": "application/x-amz-json-1.1",
|
|
35
|
-
"x-amz-target": "AnyScaleFrontendService.DescribeScalableTargets",
|
|
36
|
-
};
|
|
37
|
-
let body;
|
|
38
|
-
body = JSON.stringify(serializeAws_json1_1DescribeScalableTargetsRequest(input, context));
|
|
39
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
40
|
-
};
|
|
41
|
-
export const serializeAws_json1_1DescribeScalingActivitiesCommand = async (input, context) => {
|
|
42
|
-
const headers = {
|
|
43
|
-
"content-type": "application/x-amz-json-1.1",
|
|
44
|
-
"x-amz-target": "AnyScaleFrontendService.DescribeScalingActivities",
|
|
45
|
-
};
|
|
46
|
-
let body;
|
|
47
|
-
body = JSON.stringify(serializeAws_json1_1DescribeScalingActivitiesRequest(input, context));
|
|
48
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
49
|
-
};
|
|
50
|
-
export const serializeAws_json1_1DescribeScalingPoliciesCommand = async (input, context) => {
|
|
51
|
-
const headers = {
|
|
52
|
-
"content-type": "application/x-amz-json-1.1",
|
|
53
|
-
"x-amz-target": "AnyScaleFrontendService.DescribeScalingPolicies",
|
|
54
|
-
};
|
|
55
|
-
let body;
|
|
56
|
-
body = JSON.stringify(serializeAws_json1_1DescribeScalingPoliciesRequest(input, context));
|
|
57
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
58
|
-
};
|
|
59
|
-
export const serializeAws_json1_1DescribeScheduledActionsCommand = async (input, context) => {
|
|
60
|
-
const headers = {
|
|
61
|
-
"content-type": "application/x-amz-json-1.1",
|
|
62
|
-
"x-amz-target": "AnyScaleFrontendService.DescribeScheduledActions",
|
|
63
|
-
};
|
|
64
|
-
let body;
|
|
65
|
-
body = JSON.stringify(serializeAws_json1_1DescribeScheduledActionsRequest(input, context));
|
|
66
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
67
|
-
};
|
|
68
|
-
export const serializeAws_json1_1PutScalingPolicyCommand = async (input, context) => {
|
|
69
|
-
const headers = {
|
|
70
|
-
"content-type": "application/x-amz-json-1.1",
|
|
71
|
-
"x-amz-target": "AnyScaleFrontendService.PutScalingPolicy",
|
|
72
|
-
};
|
|
73
|
-
let body;
|
|
74
|
-
body = JSON.stringify(serializeAws_json1_1PutScalingPolicyRequest(input, context));
|
|
75
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
76
|
-
};
|
|
77
|
-
export const serializeAws_json1_1PutScheduledActionCommand = async (input, context) => {
|
|
78
|
-
const headers = {
|
|
79
|
-
"content-type": "application/x-amz-json-1.1",
|
|
80
|
-
"x-amz-target": "AnyScaleFrontendService.PutScheduledAction",
|
|
81
|
-
};
|
|
82
|
-
let body;
|
|
83
|
-
body = JSON.stringify(serializeAws_json1_1PutScheduledActionRequest(input, context));
|
|
84
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
85
|
-
};
|
|
86
|
-
export const serializeAws_json1_1RegisterScalableTargetCommand = async (input, context) => {
|
|
87
|
-
const headers = {
|
|
88
|
-
"content-type": "application/x-amz-json-1.1",
|
|
89
|
-
"x-amz-target": "AnyScaleFrontendService.RegisterScalableTarget",
|
|
90
|
-
};
|
|
91
|
-
let body;
|
|
92
|
-
body = JSON.stringify(serializeAws_json1_1RegisterScalableTargetRequest(input, context));
|
|
93
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
94
|
-
};
|
|
95
|
-
export const deserializeAws_json1_1DeleteScalingPolicyCommand = async (output, context) => {
|
|
96
|
-
if (output.statusCode >= 300) {
|
|
97
|
-
return deserializeAws_json1_1DeleteScalingPolicyCommandError(output, context);
|
|
98
|
-
}
|
|
99
|
-
const data = await parseBody(output.body, context);
|
|
100
|
-
let contents = {};
|
|
101
|
-
contents = deserializeAws_json1_1DeleteScalingPolicyResponse(data, context);
|
|
102
|
-
const response = {
|
|
103
|
-
$metadata: deserializeMetadata(output),
|
|
104
|
-
...contents,
|
|
105
|
-
};
|
|
106
|
-
return Promise.resolve(response);
|
|
107
|
-
};
|
|
108
|
-
const deserializeAws_json1_1DeleteScalingPolicyCommandError = async (output, context) => {
|
|
109
|
-
const parsedOutput = {
|
|
110
|
-
...output,
|
|
111
|
-
body: await parseErrorBody(output.body, context),
|
|
112
|
-
};
|
|
113
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
114
|
-
switch (errorCode) {
|
|
115
|
-
case "ConcurrentUpdateException":
|
|
116
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
117
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
118
|
-
case "InternalServiceException":
|
|
119
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
120
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
121
|
-
case "ObjectNotFoundException":
|
|
122
|
-
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException":
|
|
123
|
-
throw await deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context);
|
|
124
|
-
case "ValidationException":
|
|
125
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
126
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
127
|
-
default:
|
|
128
|
-
const parsedBody = parsedOutput.body;
|
|
129
|
-
throwDefaultError({
|
|
130
|
-
output,
|
|
131
|
-
parsedBody,
|
|
132
|
-
exceptionCtor: __BaseException,
|
|
133
|
-
errorCode,
|
|
134
|
-
});
|
|
135
|
-
}
|
|
136
|
-
};
|
|
137
|
-
export const deserializeAws_json1_1DeleteScheduledActionCommand = async (output, context) => {
|
|
138
|
-
if (output.statusCode >= 300) {
|
|
139
|
-
return deserializeAws_json1_1DeleteScheduledActionCommandError(output, context);
|
|
140
|
-
}
|
|
141
|
-
const data = await parseBody(output.body, context);
|
|
142
|
-
let contents = {};
|
|
143
|
-
contents = deserializeAws_json1_1DeleteScheduledActionResponse(data, context);
|
|
144
|
-
const response = {
|
|
145
|
-
$metadata: deserializeMetadata(output),
|
|
146
|
-
...contents,
|
|
147
|
-
};
|
|
148
|
-
return Promise.resolve(response);
|
|
149
|
-
};
|
|
150
|
-
const deserializeAws_json1_1DeleteScheduledActionCommandError = async (output, context) => {
|
|
151
|
-
const parsedOutput = {
|
|
152
|
-
...output,
|
|
153
|
-
body: await parseErrorBody(output.body, context),
|
|
154
|
-
};
|
|
155
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
156
|
-
switch (errorCode) {
|
|
157
|
-
case "ConcurrentUpdateException":
|
|
158
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
159
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
160
|
-
case "InternalServiceException":
|
|
161
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
162
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
163
|
-
case "ObjectNotFoundException":
|
|
164
|
-
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException":
|
|
165
|
-
throw await deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context);
|
|
166
|
-
case "ValidationException":
|
|
167
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
168
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
169
|
-
default:
|
|
170
|
-
const parsedBody = parsedOutput.body;
|
|
171
|
-
throwDefaultError({
|
|
172
|
-
output,
|
|
173
|
-
parsedBody,
|
|
174
|
-
exceptionCtor: __BaseException,
|
|
175
|
-
errorCode,
|
|
176
|
-
});
|
|
177
|
-
}
|
|
178
|
-
};
|
|
179
|
-
export const deserializeAws_json1_1DeregisterScalableTargetCommand = async (output, context) => {
|
|
180
|
-
if (output.statusCode >= 300) {
|
|
181
|
-
return deserializeAws_json1_1DeregisterScalableTargetCommandError(output, context);
|
|
182
|
-
}
|
|
183
|
-
const data = await parseBody(output.body, context);
|
|
184
|
-
let contents = {};
|
|
185
|
-
contents = deserializeAws_json1_1DeregisterScalableTargetResponse(data, context);
|
|
186
|
-
const response = {
|
|
187
|
-
$metadata: deserializeMetadata(output),
|
|
188
|
-
...contents,
|
|
189
|
-
};
|
|
190
|
-
return Promise.resolve(response);
|
|
191
|
-
};
|
|
192
|
-
const deserializeAws_json1_1DeregisterScalableTargetCommandError = async (output, context) => {
|
|
193
|
-
const parsedOutput = {
|
|
194
|
-
...output,
|
|
195
|
-
body: await parseErrorBody(output.body, context),
|
|
196
|
-
};
|
|
197
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
198
|
-
switch (errorCode) {
|
|
199
|
-
case "ConcurrentUpdateException":
|
|
200
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
201
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
202
|
-
case "InternalServiceException":
|
|
203
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
204
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
205
|
-
case "ObjectNotFoundException":
|
|
206
|
-
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException":
|
|
207
|
-
throw await deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context);
|
|
208
|
-
case "ValidationException":
|
|
209
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
210
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
211
|
-
default:
|
|
212
|
-
const parsedBody = parsedOutput.body;
|
|
213
|
-
throwDefaultError({
|
|
214
|
-
output,
|
|
215
|
-
parsedBody,
|
|
216
|
-
exceptionCtor: __BaseException,
|
|
217
|
-
errorCode,
|
|
218
|
-
});
|
|
219
|
-
}
|
|
220
|
-
};
|
|
221
|
-
export const deserializeAws_json1_1DescribeScalableTargetsCommand = async (output, context) => {
|
|
222
|
-
if (output.statusCode >= 300) {
|
|
223
|
-
return deserializeAws_json1_1DescribeScalableTargetsCommandError(output, context);
|
|
224
|
-
}
|
|
225
|
-
const data = await parseBody(output.body, context);
|
|
226
|
-
let contents = {};
|
|
227
|
-
contents = deserializeAws_json1_1DescribeScalableTargetsResponse(data, context);
|
|
228
|
-
const response = {
|
|
229
|
-
$metadata: deserializeMetadata(output),
|
|
230
|
-
...contents,
|
|
231
|
-
};
|
|
232
|
-
return Promise.resolve(response);
|
|
233
|
-
};
|
|
234
|
-
const deserializeAws_json1_1DescribeScalableTargetsCommandError = async (output, context) => {
|
|
235
|
-
const parsedOutput = {
|
|
236
|
-
...output,
|
|
237
|
-
body: await parseErrorBody(output.body, context),
|
|
238
|
-
};
|
|
239
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
240
|
-
switch (errorCode) {
|
|
241
|
-
case "ConcurrentUpdateException":
|
|
242
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
243
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
244
|
-
case "InternalServiceException":
|
|
245
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
246
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
247
|
-
case "InvalidNextTokenException":
|
|
248
|
-
case "com.amazonaws.applicationautoscaling#InvalidNextTokenException":
|
|
249
|
-
throw await deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context);
|
|
250
|
-
case "ValidationException":
|
|
251
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
252
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
253
|
-
default:
|
|
254
|
-
const parsedBody = parsedOutput.body;
|
|
255
|
-
throwDefaultError({
|
|
256
|
-
output,
|
|
257
|
-
parsedBody,
|
|
258
|
-
exceptionCtor: __BaseException,
|
|
259
|
-
errorCode,
|
|
260
|
-
});
|
|
261
|
-
}
|
|
262
|
-
};
|
|
263
|
-
export const deserializeAws_json1_1DescribeScalingActivitiesCommand = async (output, context) => {
|
|
264
|
-
if (output.statusCode >= 300) {
|
|
265
|
-
return deserializeAws_json1_1DescribeScalingActivitiesCommandError(output, context);
|
|
266
|
-
}
|
|
267
|
-
const data = await parseBody(output.body, context);
|
|
268
|
-
let contents = {};
|
|
269
|
-
contents = deserializeAws_json1_1DescribeScalingActivitiesResponse(data, context);
|
|
270
|
-
const response = {
|
|
271
|
-
$metadata: deserializeMetadata(output),
|
|
272
|
-
...contents,
|
|
273
|
-
};
|
|
274
|
-
return Promise.resolve(response);
|
|
275
|
-
};
|
|
276
|
-
const deserializeAws_json1_1DescribeScalingActivitiesCommandError = async (output, context) => {
|
|
277
|
-
const parsedOutput = {
|
|
278
|
-
...output,
|
|
279
|
-
body: await parseErrorBody(output.body, context),
|
|
280
|
-
};
|
|
281
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
282
|
-
switch (errorCode) {
|
|
283
|
-
case "ConcurrentUpdateException":
|
|
284
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
285
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
286
|
-
case "InternalServiceException":
|
|
287
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
288
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
289
|
-
case "InvalidNextTokenException":
|
|
290
|
-
case "com.amazonaws.applicationautoscaling#InvalidNextTokenException":
|
|
291
|
-
throw await deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context);
|
|
292
|
-
case "ValidationException":
|
|
293
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
294
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
295
|
-
default:
|
|
296
|
-
const parsedBody = parsedOutput.body;
|
|
297
|
-
throwDefaultError({
|
|
298
|
-
output,
|
|
299
|
-
parsedBody,
|
|
300
|
-
exceptionCtor: __BaseException,
|
|
301
|
-
errorCode,
|
|
302
|
-
});
|
|
303
|
-
}
|
|
304
|
-
};
|
|
305
|
-
export const deserializeAws_json1_1DescribeScalingPoliciesCommand = async (output, context) => {
|
|
306
|
-
if (output.statusCode >= 300) {
|
|
307
|
-
return deserializeAws_json1_1DescribeScalingPoliciesCommandError(output, context);
|
|
308
|
-
}
|
|
309
|
-
const data = await parseBody(output.body, context);
|
|
310
|
-
let contents = {};
|
|
311
|
-
contents = deserializeAws_json1_1DescribeScalingPoliciesResponse(data, context);
|
|
312
|
-
const response = {
|
|
313
|
-
$metadata: deserializeMetadata(output),
|
|
314
|
-
...contents,
|
|
315
|
-
};
|
|
316
|
-
return Promise.resolve(response);
|
|
317
|
-
};
|
|
318
|
-
const deserializeAws_json1_1DescribeScalingPoliciesCommandError = async (output, context) => {
|
|
319
|
-
const parsedOutput = {
|
|
320
|
-
...output,
|
|
321
|
-
body: await parseErrorBody(output.body, context),
|
|
322
|
-
};
|
|
323
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
324
|
-
switch (errorCode) {
|
|
325
|
-
case "ConcurrentUpdateException":
|
|
326
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
327
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
328
|
-
case "FailedResourceAccessException":
|
|
329
|
-
case "com.amazonaws.applicationautoscaling#FailedResourceAccessException":
|
|
330
|
-
throw await deserializeAws_json1_1FailedResourceAccessExceptionResponse(parsedOutput, context);
|
|
331
|
-
case "InternalServiceException":
|
|
332
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
333
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
334
|
-
case "InvalidNextTokenException":
|
|
335
|
-
case "com.amazonaws.applicationautoscaling#InvalidNextTokenException":
|
|
336
|
-
throw await deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context);
|
|
337
|
-
case "ValidationException":
|
|
338
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
339
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
340
|
-
default:
|
|
341
|
-
const parsedBody = parsedOutput.body;
|
|
342
|
-
throwDefaultError({
|
|
343
|
-
output,
|
|
344
|
-
parsedBody,
|
|
345
|
-
exceptionCtor: __BaseException,
|
|
346
|
-
errorCode,
|
|
347
|
-
});
|
|
348
|
-
}
|
|
349
|
-
};
|
|
350
|
-
export const deserializeAws_json1_1DescribeScheduledActionsCommand = async (output, context) => {
|
|
351
|
-
if (output.statusCode >= 300) {
|
|
352
|
-
return deserializeAws_json1_1DescribeScheduledActionsCommandError(output, context);
|
|
353
|
-
}
|
|
354
|
-
const data = await parseBody(output.body, context);
|
|
355
|
-
let contents = {};
|
|
356
|
-
contents = deserializeAws_json1_1DescribeScheduledActionsResponse(data, context);
|
|
357
|
-
const response = {
|
|
358
|
-
$metadata: deserializeMetadata(output),
|
|
359
|
-
...contents,
|
|
360
|
-
};
|
|
361
|
-
return Promise.resolve(response);
|
|
362
|
-
};
|
|
363
|
-
const deserializeAws_json1_1DescribeScheduledActionsCommandError = async (output, context) => {
|
|
364
|
-
const parsedOutput = {
|
|
365
|
-
...output,
|
|
366
|
-
body: await parseErrorBody(output.body, context),
|
|
367
|
-
};
|
|
368
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
369
|
-
switch (errorCode) {
|
|
370
|
-
case "ConcurrentUpdateException":
|
|
371
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
372
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
373
|
-
case "InternalServiceException":
|
|
374
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
375
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
376
|
-
case "InvalidNextTokenException":
|
|
377
|
-
case "com.amazonaws.applicationautoscaling#InvalidNextTokenException":
|
|
378
|
-
throw await deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context);
|
|
379
|
-
case "ValidationException":
|
|
380
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
381
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
382
|
-
default:
|
|
383
|
-
const parsedBody = parsedOutput.body;
|
|
384
|
-
throwDefaultError({
|
|
385
|
-
output,
|
|
386
|
-
parsedBody,
|
|
387
|
-
exceptionCtor: __BaseException,
|
|
388
|
-
errorCode,
|
|
389
|
-
});
|
|
390
|
-
}
|
|
391
|
-
};
|
|
392
|
-
export const deserializeAws_json1_1PutScalingPolicyCommand = async (output, context) => {
|
|
393
|
-
if (output.statusCode >= 300) {
|
|
394
|
-
return deserializeAws_json1_1PutScalingPolicyCommandError(output, context);
|
|
395
|
-
}
|
|
396
|
-
const data = await parseBody(output.body, context);
|
|
397
|
-
let contents = {};
|
|
398
|
-
contents = deserializeAws_json1_1PutScalingPolicyResponse(data, context);
|
|
399
|
-
const response = {
|
|
400
|
-
$metadata: deserializeMetadata(output),
|
|
401
|
-
...contents,
|
|
402
|
-
};
|
|
403
|
-
return Promise.resolve(response);
|
|
404
|
-
};
|
|
405
|
-
const deserializeAws_json1_1PutScalingPolicyCommandError = async (output, context) => {
|
|
406
|
-
const parsedOutput = {
|
|
407
|
-
...output,
|
|
408
|
-
body: await parseErrorBody(output.body, context),
|
|
409
|
-
};
|
|
410
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
411
|
-
switch (errorCode) {
|
|
412
|
-
case "ConcurrentUpdateException":
|
|
413
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
414
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
415
|
-
case "FailedResourceAccessException":
|
|
416
|
-
case "com.amazonaws.applicationautoscaling#FailedResourceAccessException":
|
|
417
|
-
throw await deserializeAws_json1_1FailedResourceAccessExceptionResponse(parsedOutput, context);
|
|
418
|
-
case "InternalServiceException":
|
|
419
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
420
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
421
|
-
case "LimitExceededException":
|
|
422
|
-
case "com.amazonaws.applicationautoscaling#LimitExceededException":
|
|
423
|
-
throw await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context);
|
|
424
|
-
case "ObjectNotFoundException":
|
|
425
|
-
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException":
|
|
426
|
-
throw await deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context);
|
|
427
|
-
case "ValidationException":
|
|
428
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
429
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
430
|
-
default:
|
|
431
|
-
const parsedBody = parsedOutput.body;
|
|
432
|
-
throwDefaultError({
|
|
433
|
-
output,
|
|
434
|
-
parsedBody,
|
|
435
|
-
exceptionCtor: __BaseException,
|
|
436
|
-
errorCode,
|
|
437
|
-
});
|
|
438
|
-
}
|
|
439
|
-
};
|
|
440
|
-
export const deserializeAws_json1_1PutScheduledActionCommand = async (output, context) => {
|
|
441
|
-
if (output.statusCode >= 300) {
|
|
442
|
-
return deserializeAws_json1_1PutScheduledActionCommandError(output, context);
|
|
443
|
-
}
|
|
444
|
-
const data = await parseBody(output.body, context);
|
|
445
|
-
let contents = {};
|
|
446
|
-
contents = deserializeAws_json1_1PutScheduledActionResponse(data, context);
|
|
447
|
-
const response = {
|
|
448
|
-
$metadata: deserializeMetadata(output),
|
|
449
|
-
...contents,
|
|
450
|
-
};
|
|
451
|
-
return Promise.resolve(response);
|
|
452
|
-
};
|
|
453
|
-
const deserializeAws_json1_1PutScheduledActionCommandError = async (output, context) => {
|
|
454
|
-
const parsedOutput = {
|
|
455
|
-
...output,
|
|
456
|
-
body: await parseErrorBody(output.body, context),
|
|
457
|
-
};
|
|
458
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
459
|
-
switch (errorCode) {
|
|
460
|
-
case "ConcurrentUpdateException":
|
|
461
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
462
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
463
|
-
case "InternalServiceException":
|
|
464
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
465
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
466
|
-
case "LimitExceededException":
|
|
467
|
-
case "com.amazonaws.applicationautoscaling#LimitExceededException":
|
|
468
|
-
throw await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context);
|
|
469
|
-
case "ObjectNotFoundException":
|
|
470
|
-
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException":
|
|
471
|
-
throw await deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context);
|
|
472
|
-
case "ValidationException":
|
|
473
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
474
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
475
|
-
default:
|
|
476
|
-
const parsedBody = parsedOutput.body;
|
|
477
|
-
throwDefaultError({
|
|
478
|
-
output,
|
|
479
|
-
parsedBody,
|
|
480
|
-
exceptionCtor: __BaseException,
|
|
481
|
-
errorCode,
|
|
482
|
-
});
|
|
483
|
-
}
|
|
484
|
-
};
|
|
485
|
-
export const deserializeAws_json1_1RegisterScalableTargetCommand = async (output, context) => {
|
|
486
|
-
if (output.statusCode >= 300) {
|
|
487
|
-
return deserializeAws_json1_1RegisterScalableTargetCommandError(output, context);
|
|
488
|
-
}
|
|
489
|
-
const data = await parseBody(output.body, context);
|
|
490
|
-
let contents = {};
|
|
491
|
-
contents = deserializeAws_json1_1RegisterScalableTargetResponse(data, context);
|
|
492
|
-
const response = {
|
|
493
|
-
$metadata: deserializeMetadata(output),
|
|
494
|
-
...contents,
|
|
495
|
-
};
|
|
496
|
-
return Promise.resolve(response);
|
|
497
|
-
};
|
|
498
|
-
const deserializeAws_json1_1RegisterScalableTargetCommandError = async (output, context) => {
|
|
499
|
-
const parsedOutput = {
|
|
500
|
-
...output,
|
|
501
|
-
body: await parseErrorBody(output.body, context),
|
|
502
|
-
};
|
|
503
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
504
|
-
switch (errorCode) {
|
|
505
|
-
case "ConcurrentUpdateException":
|
|
506
|
-
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException":
|
|
507
|
-
throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
|
|
508
|
-
case "InternalServiceException":
|
|
509
|
-
case "com.amazonaws.applicationautoscaling#InternalServiceException":
|
|
510
|
-
throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
|
|
511
|
-
case "LimitExceededException":
|
|
512
|
-
case "com.amazonaws.applicationautoscaling#LimitExceededException":
|
|
513
|
-
throw await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context);
|
|
514
|
-
case "ValidationException":
|
|
515
|
-
case "com.amazonaws.applicationautoscaling#ValidationException":
|
|
516
|
-
throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
|
|
517
|
-
default:
|
|
518
|
-
const parsedBody = parsedOutput.body;
|
|
519
|
-
throwDefaultError({
|
|
520
|
-
output,
|
|
521
|
-
parsedBody,
|
|
522
|
-
exceptionCtor: __BaseException,
|
|
523
|
-
errorCode,
|
|
524
|
-
});
|
|
525
|
-
}
|
|
526
|
-
};
|
|
527
|
-
const deserializeAws_json1_1ConcurrentUpdateExceptionResponse = async (parsedOutput, context) => {
|
|
528
|
-
const body = parsedOutput.body;
|
|
529
|
-
const deserialized = deserializeAws_json1_1ConcurrentUpdateException(body, context);
|
|
530
|
-
const exception = new ConcurrentUpdateException({
|
|
531
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
532
|
-
...deserialized,
|
|
6
|
+
export var serializeAws_json1_1DeleteScalingPolicyCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
7
|
+
var headers, body;
|
|
8
|
+
return __generator(this, function (_a) {
|
|
9
|
+
headers = {
|
|
10
|
+
"content-type": "application/x-amz-json-1.1",
|
|
11
|
+
"x-amz-target": "AnyScaleFrontendService.DeleteScalingPolicy",
|
|
12
|
+
};
|
|
13
|
+
body = JSON.stringify(serializeAws_json1_1DeleteScalingPolicyRequest(input, context));
|
|
14
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
533
15
|
});
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
16
|
+
}); };
|
|
17
|
+
export var serializeAws_json1_1DeleteScheduledActionCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
18
|
+
var headers, body;
|
|
19
|
+
return __generator(this, function (_a) {
|
|
20
|
+
headers = {
|
|
21
|
+
"content-type": "application/x-amz-json-1.1",
|
|
22
|
+
"x-amz-target": "AnyScaleFrontendService.DeleteScheduledAction",
|
|
23
|
+
};
|
|
24
|
+
body = JSON.stringify(serializeAws_json1_1DeleteScheduledActionRequest(input, context));
|
|
25
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
542
26
|
});
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
27
|
+
}); };
|
|
28
|
+
export var serializeAws_json1_1DeregisterScalableTargetCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
29
|
+
var headers, body;
|
|
30
|
+
return __generator(this, function (_a) {
|
|
31
|
+
headers = {
|
|
32
|
+
"content-type": "application/x-amz-json-1.1",
|
|
33
|
+
"x-amz-target": "AnyScaleFrontendService.DeregisterScalableTarget",
|
|
34
|
+
};
|
|
35
|
+
body = JSON.stringify(serializeAws_json1_1DeregisterScalableTargetRequest(input, context));
|
|
36
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
551
37
|
});
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
38
|
+
}); };
|
|
39
|
+
export var serializeAws_json1_1DescribeScalableTargetsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
40
|
+
var headers, body;
|
|
41
|
+
return __generator(this, function (_a) {
|
|
42
|
+
headers = {
|
|
43
|
+
"content-type": "application/x-amz-json-1.1",
|
|
44
|
+
"x-amz-target": "AnyScaleFrontendService.DescribeScalableTargets",
|
|
45
|
+
};
|
|
46
|
+
body = JSON.stringify(serializeAws_json1_1DescribeScalableTargetsRequest(input, context));
|
|
47
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
560
48
|
});
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
49
|
+
}); };
|
|
50
|
+
export var serializeAws_json1_1DescribeScalingActivitiesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
51
|
+
var headers, body;
|
|
52
|
+
return __generator(this, function (_a) {
|
|
53
|
+
headers = {
|
|
54
|
+
"content-type": "application/x-amz-json-1.1",
|
|
55
|
+
"x-amz-target": "AnyScaleFrontendService.DescribeScalingActivities",
|
|
56
|
+
};
|
|
57
|
+
body = JSON.stringify(serializeAws_json1_1DescribeScalingActivitiesRequest(input, context));
|
|
58
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
569
59
|
});
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
60
|
+
}); };
|
|
61
|
+
export var serializeAws_json1_1DescribeScalingPoliciesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
62
|
+
var headers, body;
|
|
63
|
+
return __generator(this, function (_a) {
|
|
64
|
+
headers = {
|
|
65
|
+
"content-type": "application/x-amz-json-1.1",
|
|
66
|
+
"x-amz-target": "AnyScaleFrontendService.DescribeScalingPolicies",
|
|
67
|
+
};
|
|
68
|
+
body = JSON.stringify(serializeAws_json1_1DescribeScalingPoliciesRequest(input, context));
|
|
69
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
578
70
|
});
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
71
|
+
}); };
|
|
72
|
+
export var serializeAws_json1_1DescribeScheduledActionsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
73
|
+
var headers, body;
|
|
74
|
+
return __generator(this, function (_a) {
|
|
75
|
+
headers = {
|
|
76
|
+
"content-type": "application/x-amz-json-1.1",
|
|
77
|
+
"x-amz-target": "AnyScaleFrontendService.DescribeScheduledActions",
|
|
78
|
+
};
|
|
79
|
+
body = JSON.stringify(serializeAws_json1_1DescribeScheduledActionsRequest(input, context));
|
|
80
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
587
81
|
});
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
return {
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
82
|
+
}); };
|
|
83
|
+
export var serializeAws_json1_1PutScalingPolicyCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
84
|
+
var headers, body;
|
|
85
|
+
return __generator(this, function (_a) {
|
|
86
|
+
headers = {
|
|
87
|
+
"content-type": "application/x-amz-json-1.1",
|
|
88
|
+
"x-amz-target": "AnyScaleFrontendService.PutScalingPolicy",
|
|
89
|
+
};
|
|
90
|
+
body = JSON.stringify(serializeAws_json1_1PutScalingPolicyRequest(input, context));
|
|
91
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
92
|
+
});
|
|
93
|
+
}); };
|
|
94
|
+
export var serializeAws_json1_1PutScheduledActionCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
95
|
+
var headers, body;
|
|
96
|
+
return __generator(this, function (_a) {
|
|
97
|
+
headers = {
|
|
98
|
+
"content-type": "application/x-amz-json-1.1",
|
|
99
|
+
"x-amz-target": "AnyScaleFrontendService.PutScheduledAction",
|
|
100
|
+
};
|
|
101
|
+
body = JSON.stringify(serializeAws_json1_1PutScheduledActionRequest(input, context));
|
|
102
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
103
|
+
});
|
|
104
|
+
}); };
|
|
105
|
+
export var serializeAws_json1_1RegisterScalableTargetCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
106
|
+
var headers, body;
|
|
107
|
+
return __generator(this, function (_a) {
|
|
108
|
+
headers = {
|
|
109
|
+
"content-type": "application/x-amz-json-1.1",
|
|
110
|
+
"x-amz-target": "AnyScaleFrontendService.RegisterScalableTarget",
|
|
111
|
+
};
|
|
112
|
+
body = JSON.stringify(serializeAws_json1_1RegisterScalableTargetRequest(input, context));
|
|
113
|
+
return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
|
|
114
|
+
});
|
|
115
|
+
}); };
|
|
116
|
+
export var deserializeAws_json1_1DeleteScalingPolicyCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
117
|
+
var data, contents, response;
|
|
118
|
+
return __generator(this, function (_a) {
|
|
119
|
+
switch (_a.label) {
|
|
120
|
+
case 0:
|
|
121
|
+
if (output.statusCode >= 300) {
|
|
122
|
+
return [2, deserializeAws_json1_1DeleteScalingPolicyCommandError(output, context)];
|
|
123
|
+
}
|
|
124
|
+
return [4, parseBody(output.body, context)];
|
|
125
|
+
case 1:
|
|
126
|
+
data = _a.sent();
|
|
127
|
+
contents = {};
|
|
128
|
+
contents = deserializeAws_json1_1DeleteScalingPolicyResponse(data, context);
|
|
129
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
130
|
+
return [2, Promise.resolve(response)];
|
|
131
|
+
}
|
|
132
|
+
});
|
|
133
|
+
}); };
|
|
134
|
+
var deserializeAws_json1_1DeleteScalingPolicyCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
135
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
136
|
+
var _c;
|
|
137
|
+
return __generator(this, function (_d) {
|
|
138
|
+
switch (_d.label) {
|
|
139
|
+
case 0:
|
|
140
|
+
_a = [__assign({}, output)];
|
|
141
|
+
_c = {};
|
|
142
|
+
return [4, parseErrorBody(output.body, context)];
|
|
143
|
+
case 1:
|
|
144
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
145
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
146
|
+
_b = errorCode;
|
|
147
|
+
switch (_b) {
|
|
148
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
149
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
150
|
+
case "InternalServiceException": return [3, 4];
|
|
151
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 4];
|
|
152
|
+
case "ObjectNotFoundException": return [3, 6];
|
|
153
|
+
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException": return [3, 6];
|
|
154
|
+
case "ValidationException": return [3, 8];
|
|
155
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 8];
|
|
156
|
+
}
|
|
157
|
+
return [3, 10];
|
|
158
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
159
|
+
case 3: throw _d.sent();
|
|
160
|
+
case 4: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
161
|
+
case 5: throw _d.sent();
|
|
162
|
+
case 6: return [4, deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context)];
|
|
163
|
+
case 7: throw _d.sent();
|
|
164
|
+
case 8: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
165
|
+
case 9: throw _d.sent();
|
|
166
|
+
case 10:
|
|
167
|
+
parsedBody = parsedOutput.body;
|
|
168
|
+
throwDefaultError({
|
|
169
|
+
output: output,
|
|
170
|
+
parsedBody: parsedBody,
|
|
171
|
+
exceptionCtor: __BaseException,
|
|
172
|
+
errorCode: errorCode,
|
|
173
|
+
});
|
|
174
|
+
_d.label = 11;
|
|
175
|
+
case 11: return [2];
|
|
176
|
+
}
|
|
177
|
+
});
|
|
178
|
+
}); };
|
|
179
|
+
export var deserializeAws_json1_1DeleteScheduledActionCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
180
|
+
var data, contents, response;
|
|
181
|
+
return __generator(this, function (_a) {
|
|
182
|
+
switch (_a.label) {
|
|
183
|
+
case 0:
|
|
184
|
+
if (output.statusCode >= 300) {
|
|
185
|
+
return [2, deserializeAws_json1_1DeleteScheduledActionCommandError(output, context)];
|
|
186
|
+
}
|
|
187
|
+
return [4, parseBody(output.body, context)];
|
|
188
|
+
case 1:
|
|
189
|
+
data = _a.sent();
|
|
190
|
+
contents = {};
|
|
191
|
+
contents = deserializeAws_json1_1DeleteScheduledActionResponse(data, context);
|
|
192
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
193
|
+
return [2, Promise.resolve(response)];
|
|
194
|
+
}
|
|
195
|
+
});
|
|
196
|
+
}); };
|
|
197
|
+
var deserializeAws_json1_1DeleteScheduledActionCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
198
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
199
|
+
var _c;
|
|
200
|
+
return __generator(this, function (_d) {
|
|
201
|
+
switch (_d.label) {
|
|
202
|
+
case 0:
|
|
203
|
+
_a = [__assign({}, output)];
|
|
204
|
+
_c = {};
|
|
205
|
+
return [4, parseErrorBody(output.body, context)];
|
|
206
|
+
case 1:
|
|
207
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
208
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
209
|
+
_b = errorCode;
|
|
210
|
+
switch (_b) {
|
|
211
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
212
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
213
|
+
case "InternalServiceException": return [3, 4];
|
|
214
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 4];
|
|
215
|
+
case "ObjectNotFoundException": return [3, 6];
|
|
216
|
+
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException": return [3, 6];
|
|
217
|
+
case "ValidationException": return [3, 8];
|
|
218
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 8];
|
|
219
|
+
}
|
|
220
|
+
return [3, 10];
|
|
221
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
222
|
+
case 3: throw _d.sent();
|
|
223
|
+
case 4: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
224
|
+
case 5: throw _d.sent();
|
|
225
|
+
case 6: return [4, deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context)];
|
|
226
|
+
case 7: throw _d.sent();
|
|
227
|
+
case 8: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
228
|
+
case 9: throw _d.sent();
|
|
229
|
+
case 10:
|
|
230
|
+
parsedBody = parsedOutput.body;
|
|
231
|
+
throwDefaultError({
|
|
232
|
+
output: output,
|
|
233
|
+
parsedBody: parsedBody,
|
|
234
|
+
exceptionCtor: __BaseException,
|
|
235
|
+
errorCode: errorCode,
|
|
236
|
+
});
|
|
237
|
+
_d.label = 11;
|
|
238
|
+
case 11: return [2];
|
|
239
|
+
}
|
|
240
|
+
});
|
|
241
|
+
}); };
|
|
242
|
+
export var deserializeAws_json1_1DeregisterScalableTargetCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
243
|
+
var data, contents, response;
|
|
244
|
+
return __generator(this, function (_a) {
|
|
245
|
+
switch (_a.label) {
|
|
246
|
+
case 0:
|
|
247
|
+
if (output.statusCode >= 300) {
|
|
248
|
+
return [2, deserializeAws_json1_1DeregisterScalableTargetCommandError(output, context)];
|
|
249
|
+
}
|
|
250
|
+
return [4, parseBody(output.body, context)];
|
|
251
|
+
case 1:
|
|
252
|
+
data = _a.sent();
|
|
253
|
+
contents = {};
|
|
254
|
+
contents = deserializeAws_json1_1DeregisterScalableTargetResponse(data, context);
|
|
255
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
256
|
+
return [2, Promise.resolve(response)];
|
|
257
|
+
}
|
|
258
|
+
});
|
|
259
|
+
}); };
|
|
260
|
+
var deserializeAws_json1_1DeregisterScalableTargetCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
261
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
262
|
+
var _c;
|
|
263
|
+
return __generator(this, function (_d) {
|
|
264
|
+
switch (_d.label) {
|
|
265
|
+
case 0:
|
|
266
|
+
_a = [__assign({}, output)];
|
|
267
|
+
_c = {};
|
|
268
|
+
return [4, parseErrorBody(output.body, context)];
|
|
269
|
+
case 1:
|
|
270
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
271
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
272
|
+
_b = errorCode;
|
|
273
|
+
switch (_b) {
|
|
274
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
275
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
276
|
+
case "InternalServiceException": return [3, 4];
|
|
277
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 4];
|
|
278
|
+
case "ObjectNotFoundException": return [3, 6];
|
|
279
|
+
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException": return [3, 6];
|
|
280
|
+
case "ValidationException": return [3, 8];
|
|
281
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 8];
|
|
282
|
+
}
|
|
283
|
+
return [3, 10];
|
|
284
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
285
|
+
case 3: throw _d.sent();
|
|
286
|
+
case 4: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
287
|
+
case 5: throw _d.sent();
|
|
288
|
+
case 6: return [4, deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context)];
|
|
289
|
+
case 7: throw _d.sent();
|
|
290
|
+
case 8: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
291
|
+
case 9: throw _d.sent();
|
|
292
|
+
case 10:
|
|
293
|
+
parsedBody = parsedOutput.body;
|
|
294
|
+
throwDefaultError({
|
|
295
|
+
output: output,
|
|
296
|
+
parsedBody: parsedBody,
|
|
297
|
+
exceptionCtor: __BaseException,
|
|
298
|
+
errorCode: errorCode,
|
|
299
|
+
});
|
|
300
|
+
_d.label = 11;
|
|
301
|
+
case 11: return [2];
|
|
302
|
+
}
|
|
303
|
+
});
|
|
304
|
+
}); };
|
|
305
|
+
export var deserializeAws_json1_1DescribeScalableTargetsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
306
|
+
var data, contents, response;
|
|
307
|
+
return __generator(this, function (_a) {
|
|
308
|
+
switch (_a.label) {
|
|
309
|
+
case 0:
|
|
310
|
+
if (output.statusCode >= 300) {
|
|
311
|
+
return [2, deserializeAws_json1_1DescribeScalableTargetsCommandError(output, context)];
|
|
312
|
+
}
|
|
313
|
+
return [4, parseBody(output.body, context)];
|
|
314
|
+
case 1:
|
|
315
|
+
data = _a.sent();
|
|
316
|
+
contents = {};
|
|
317
|
+
contents = deserializeAws_json1_1DescribeScalableTargetsResponse(data, context);
|
|
318
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
319
|
+
return [2, Promise.resolve(response)];
|
|
320
|
+
}
|
|
321
|
+
});
|
|
322
|
+
}); };
|
|
323
|
+
var deserializeAws_json1_1DescribeScalableTargetsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
324
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
325
|
+
var _c;
|
|
326
|
+
return __generator(this, function (_d) {
|
|
327
|
+
switch (_d.label) {
|
|
328
|
+
case 0:
|
|
329
|
+
_a = [__assign({}, output)];
|
|
330
|
+
_c = {};
|
|
331
|
+
return [4, parseErrorBody(output.body, context)];
|
|
332
|
+
case 1:
|
|
333
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
334
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
335
|
+
_b = errorCode;
|
|
336
|
+
switch (_b) {
|
|
337
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
338
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
339
|
+
case "InternalServiceException": return [3, 4];
|
|
340
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 4];
|
|
341
|
+
case "InvalidNextTokenException": return [3, 6];
|
|
342
|
+
case "com.amazonaws.applicationautoscaling#InvalidNextTokenException": return [3, 6];
|
|
343
|
+
case "ValidationException": return [3, 8];
|
|
344
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 8];
|
|
345
|
+
}
|
|
346
|
+
return [3, 10];
|
|
347
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
348
|
+
case 3: throw _d.sent();
|
|
349
|
+
case 4: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
350
|
+
case 5: throw _d.sent();
|
|
351
|
+
case 6: return [4, deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context)];
|
|
352
|
+
case 7: throw _d.sent();
|
|
353
|
+
case 8: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
354
|
+
case 9: throw _d.sent();
|
|
355
|
+
case 10:
|
|
356
|
+
parsedBody = parsedOutput.body;
|
|
357
|
+
throwDefaultError({
|
|
358
|
+
output: output,
|
|
359
|
+
parsedBody: parsedBody,
|
|
360
|
+
exceptionCtor: __BaseException,
|
|
361
|
+
errorCode: errorCode,
|
|
362
|
+
});
|
|
363
|
+
_d.label = 11;
|
|
364
|
+
case 11: return [2];
|
|
365
|
+
}
|
|
366
|
+
});
|
|
367
|
+
}); };
|
|
368
|
+
export var deserializeAws_json1_1DescribeScalingActivitiesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
369
|
+
var data, contents, response;
|
|
370
|
+
return __generator(this, function (_a) {
|
|
371
|
+
switch (_a.label) {
|
|
372
|
+
case 0:
|
|
373
|
+
if (output.statusCode >= 300) {
|
|
374
|
+
return [2, deserializeAws_json1_1DescribeScalingActivitiesCommandError(output, context)];
|
|
375
|
+
}
|
|
376
|
+
return [4, parseBody(output.body, context)];
|
|
377
|
+
case 1:
|
|
378
|
+
data = _a.sent();
|
|
379
|
+
contents = {};
|
|
380
|
+
contents = deserializeAws_json1_1DescribeScalingActivitiesResponse(data, context);
|
|
381
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
382
|
+
return [2, Promise.resolve(response)];
|
|
383
|
+
}
|
|
384
|
+
});
|
|
385
|
+
}); };
|
|
386
|
+
var deserializeAws_json1_1DescribeScalingActivitiesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
387
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
388
|
+
var _c;
|
|
389
|
+
return __generator(this, function (_d) {
|
|
390
|
+
switch (_d.label) {
|
|
391
|
+
case 0:
|
|
392
|
+
_a = [__assign({}, output)];
|
|
393
|
+
_c = {};
|
|
394
|
+
return [4, parseErrorBody(output.body, context)];
|
|
395
|
+
case 1:
|
|
396
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
397
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
398
|
+
_b = errorCode;
|
|
399
|
+
switch (_b) {
|
|
400
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
401
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
402
|
+
case "InternalServiceException": return [3, 4];
|
|
403
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 4];
|
|
404
|
+
case "InvalidNextTokenException": return [3, 6];
|
|
405
|
+
case "com.amazonaws.applicationautoscaling#InvalidNextTokenException": return [3, 6];
|
|
406
|
+
case "ValidationException": return [3, 8];
|
|
407
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 8];
|
|
408
|
+
}
|
|
409
|
+
return [3, 10];
|
|
410
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
411
|
+
case 3: throw _d.sent();
|
|
412
|
+
case 4: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
413
|
+
case 5: throw _d.sent();
|
|
414
|
+
case 6: return [4, deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context)];
|
|
415
|
+
case 7: throw _d.sent();
|
|
416
|
+
case 8: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
417
|
+
case 9: throw _d.sent();
|
|
418
|
+
case 10:
|
|
419
|
+
parsedBody = parsedOutput.body;
|
|
420
|
+
throwDefaultError({
|
|
421
|
+
output: output,
|
|
422
|
+
parsedBody: parsedBody,
|
|
423
|
+
exceptionCtor: __BaseException,
|
|
424
|
+
errorCode: errorCode,
|
|
425
|
+
});
|
|
426
|
+
_d.label = 11;
|
|
427
|
+
case 11: return [2];
|
|
428
|
+
}
|
|
429
|
+
});
|
|
430
|
+
}); };
|
|
431
|
+
export var deserializeAws_json1_1DescribeScalingPoliciesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
432
|
+
var data, contents, response;
|
|
433
|
+
return __generator(this, function (_a) {
|
|
434
|
+
switch (_a.label) {
|
|
435
|
+
case 0:
|
|
436
|
+
if (output.statusCode >= 300) {
|
|
437
|
+
return [2, deserializeAws_json1_1DescribeScalingPoliciesCommandError(output, context)];
|
|
438
|
+
}
|
|
439
|
+
return [4, parseBody(output.body, context)];
|
|
440
|
+
case 1:
|
|
441
|
+
data = _a.sent();
|
|
442
|
+
contents = {};
|
|
443
|
+
contents = deserializeAws_json1_1DescribeScalingPoliciesResponse(data, context);
|
|
444
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
445
|
+
return [2, Promise.resolve(response)];
|
|
446
|
+
}
|
|
447
|
+
});
|
|
448
|
+
}); };
|
|
449
|
+
var deserializeAws_json1_1DescribeScalingPoliciesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
450
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
451
|
+
var _c;
|
|
452
|
+
return __generator(this, function (_d) {
|
|
453
|
+
switch (_d.label) {
|
|
454
|
+
case 0:
|
|
455
|
+
_a = [__assign({}, output)];
|
|
456
|
+
_c = {};
|
|
457
|
+
return [4, parseErrorBody(output.body, context)];
|
|
458
|
+
case 1:
|
|
459
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
460
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
461
|
+
_b = errorCode;
|
|
462
|
+
switch (_b) {
|
|
463
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
464
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
465
|
+
case "FailedResourceAccessException": return [3, 4];
|
|
466
|
+
case "com.amazonaws.applicationautoscaling#FailedResourceAccessException": return [3, 4];
|
|
467
|
+
case "InternalServiceException": return [3, 6];
|
|
468
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 6];
|
|
469
|
+
case "InvalidNextTokenException": return [3, 8];
|
|
470
|
+
case "com.amazonaws.applicationautoscaling#InvalidNextTokenException": return [3, 8];
|
|
471
|
+
case "ValidationException": return [3, 10];
|
|
472
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 10];
|
|
473
|
+
}
|
|
474
|
+
return [3, 12];
|
|
475
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
476
|
+
case 3: throw _d.sent();
|
|
477
|
+
case 4: return [4, deserializeAws_json1_1FailedResourceAccessExceptionResponse(parsedOutput, context)];
|
|
478
|
+
case 5: throw _d.sent();
|
|
479
|
+
case 6: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
480
|
+
case 7: throw _d.sent();
|
|
481
|
+
case 8: return [4, deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context)];
|
|
482
|
+
case 9: throw _d.sent();
|
|
483
|
+
case 10: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
484
|
+
case 11: throw _d.sent();
|
|
485
|
+
case 12:
|
|
486
|
+
parsedBody = parsedOutput.body;
|
|
487
|
+
throwDefaultError({
|
|
488
|
+
output: output,
|
|
489
|
+
parsedBody: parsedBody,
|
|
490
|
+
exceptionCtor: __BaseException,
|
|
491
|
+
errorCode: errorCode,
|
|
492
|
+
});
|
|
493
|
+
_d.label = 13;
|
|
494
|
+
case 13: return [2];
|
|
495
|
+
}
|
|
496
|
+
});
|
|
497
|
+
}); };
|
|
498
|
+
export var deserializeAws_json1_1DescribeScheduledActionsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
499
|
+
var data, contents, response;
|
|
500
|
+
return __generator(this, function (_a) {
|
|
501
|
+
switch (_a.label) {
|
|
502
|
+
case 0:
|
|
503
|
+
if (output.statusCode >= 300) {
|
|
504
|
+
return [2, deserializeAws_json1_1DescribeScheduledActionsCommandError(output, context)];
|
|
505
|
+
}
|
|
506
|
+
return [4, parseBody(output.body, context)];
|
|
507
|
+
case 1:
|
|
508
|
+
data = _a.sent();
|
|
509
|
+
contents = {};
|
|
510
|
+
contents = deserializeAws_json1_1DescribeScheduledActionsResponse(data, context);
|
|
511
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
512
|
+
return [2, Promise.resolve(response)];
|
|
513
|
+
}
|
|
514
|
+
});
|
|
515
|
+
}); };
|
|
516
|
+
var deserializeAws_json1_1DescribeScheduledActionsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
517
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
518
|
+
var _c;
|
|
519
|
+
return __generator(this, function (_d) {
|
|
520
|
+
switch (_d.label) {
|
|
521
|
+
case 0:
|
|
522
|
+
_a = [__assign({}, output)];
|
|
523
|
+
_c = {};
|
|
524
|
+
return [4, parseErrorBody(output.body, context)];
|
|
525
|
+
case 1:
|
|
526
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
527
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
528
|
+
_b = errorCode;
|
|
529
|
+
switch (_b) {
|
|
530
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
531
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
532
|
+
case "InternalServiceException": return [3, 4];
|
|
533
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 4];
|
|
534
|
+
case "InvalidNextTokenException": return [3, 6];
|
|
535
|
+
case "com.amazonaws.applicationautoscaling#InvalidNextTokenException": return [3, 6];
|
|
536
|
+
case "ValidationException": return [3, 8];
|
|
537
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 8];
|
|
538
|
+
}
|
|
539
|
+
return [3, 10];
|
|
540
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
541
|
+
case 3: throw _d.sent();
|
|
542
|
+
case 4: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
543
|
+
case 5: throw _d.sent();
|
|
544
|
+
case 6: return [4, deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context)];
|
|
545
|
+
case 7: throw _d.sent();
|
|
546
|
+
case 8: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
547
|
+
case 9: throw _d.sent();
|
|
548
|
+
case 10:
|
|
549
|
+
parsedBody = parsedOutput.body;
|
|
550
|
+
throwDefaultError({
|
|
551
|
+
output: output,
|
|
552
|
+
parsedBody: parsedBody,
|
|
553
|
+
exceptionCtor: __BaseException,
|
|
554
|
+
errorCode: errorCode,
|
|
555
|
+
});
|
|
556
|
+
_d.label = 11;
|
|
557
|
+
case 11: return [2];
|
|
558
|
+
}
|
|
559
|
+
});
|
|
560
|
+
}); };
|
|
561
|
+
export var deserializeAws_json1_1PutScalingPolicyCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
562
|
+
var data, contents, response;
|
|
563
|
+
return __generator(this, function (_a) {
|
|
564
|
+
switch (_a.label) {
|
|
565
|
+
case 0:
|
|
566
|
+
if (output.statusCode >= 300) {
|
|
567
|
+
return [2, deserializeAws_json1_1PutScalingPolicyCommandError(output, context)];
|
|
568
|
+
}
|
|
569
|
+
return [4, parseBody(output.body, context)];
|
|
570
|
+
case 1:
|
|
571
|
+
data = _a.sent();
|
|
572
|
+
contents = {};
|
|
573
|
+
contents = deserializeAws_json1_1PutScalingPolicyResponse(data, context);
|
|
574
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
575
|
+
return [2, Promise.resolve(response)];
|
|
576
|
+
}
|
|
577
|
+
});
|
|
578
|
+
}); };
|
|
579
|
+
var deserializeAws_json1_1PutScalingPolicyCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
580
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
581
|
+
var _c;
|
|
582
|
+
return __generator(this, function (_d) {
|
|
583
|
+
switch (_d.label) {
|
|
584
|
+
case 0:
|
|
585
|
+
_a = [__assign({}, output)];
|
|
586
|
+
_c = {};
|
|
587
|
+
return [4, parseErrorBody(output.body, context)];
|
|
588
|
+
case 1:
|
|
589
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
590
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
591
|
+
_b = errorCode;
|
|
592
|
+
switch (_b) {
|
|
593
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
594
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
595
|
+
case "FailedResourceAccessException": return [3, 4];
|
|
596
|
+
case "com.amazonaws.applicationautoscaling#FailedResourceAccessException": return [3, 4];
|
|
597
|
+
case "InternalServiceException": return [3, 6];
|
|
598
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 6];
|
|
599
|
+
case "LimitExceededException": return [3, 8];
|
|
600
|
+
case "com.amazonaws.applicationautoscaling#LimitExceededException": return [3, 8];
|
|
601
|
+
case "ObjectNotFoundException": return [3, 10];
|
|
602
|
+
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException": return [3, 10];
|
|
603
|
+
case "ValidationException": return [3, 12];
|
|
604
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 12];
|
|
605
|
+
}
|
|
606
|
+
return [3, 14];
|
|
607
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
608
|
+
case 3: throw _d.sent();
|
|
609
|
+
case 4: return [4, deserializeAws_json1_1FailedResourceAccessExceptionResponse(parsedOutput, context)];
|
|
610
|
+
case 5: throw _d.sent();
|
|
611
|
+
case 6: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
612
|
+
case 7: throw _d.sent();
|
|
613
|
+
case 8: return [4, deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)];
|
|
614
|
+
case 9: throw _d.sent();
|
|
615
|
+
case 10: return [4, deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context)];
|
|
616
|
+
case 11: throw _d.sent();
|
|
617
|
+
case 12: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
618
|
+
case 13: throw _d.sent();
|
|
619
|
+
case 14:
|
|
620
|
+
parsedBody = parsedOutput.body;
|
|
621
|
+
throwDefaultError({
|
|
622
|
+
output: output,
|
|
623
|
+
parsedBody: parsedBody,
|
|
624
|
+
exceptionCtor: __BaseException,
|
|
625
|
+
errorCode: errorCode,
|
|
626
|
+
});
|
|
627
|
+
_d.label = 15;
|
|
628
|
+
case 15: return [2];
|
|
629
|
+
}
|
|
630
|
+
});
|
|
631
|
+
}); };
|
|
632
|
+
export var deserializeAws_json1_1PutScheduledActionCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
633
|
+
var data, contents, response;
|
|
634
|
+
return __generator(this, function (_a) {
|
|
635
|
+
switch (_a.label) {
|
|
636
|
+
case 0:
|
|
637
|
+
if (output.statusCode >= 300) {
|
|
638
|
+
return [2, deserializeAws_json1_1PutScheduledActionCommandError(output, context)];
|
|
639
|
+
}
|
|
640
|
+
return [4, parseBody(output.body, context)];
|
|
641
|
+
case 1:
|
|
642
|
+
data = _a.sent();
|
|
643
|
+
contents = {};
|
|
644
|
+
contents = deserializeAws_json1_1PutScheduledActionResponse(data, context);
|
|
645
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
646
|
+
return [2, Promise.resolve(response)];
|
|
647
|
+
}
|
|
648
|
+
});
|
|
649
|
+
}); };
|
|
650
|
+
var deserializeAws_json1_1PutScheduledActionCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
651
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
652
|
+
var _c;
|
|
653
|
+
return __generator(this, function (_d) {
|
|
654
|
+
switch (_d.label) {
|
|
655
|
+
case 0:
|
|
656
|
+
_a = [__assign({}, output)];
|
|
657
|
+
_c = {};
|
|
658
|
+
return [4, parseErrorBody(output.body, context)];
|
|
659
|
+
case 1:
|
|
660
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
661
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
662
|
+
_b = errorCode;
|
|
663
|
+
switch (_b) {
|
|
664
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
665
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
666
|
+
case "InternalServiceException": return [3, 4];
|
|
667
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 4];
|
|
668
|
+
case "LimitExceededException": return [3, 6];
|
|
669
|
+
case "com.amazonaws.applicationautoscaling#LimitExceededException": return [3, 6];
|
|
670
|
+
case "ObjectNotFoundException": return [3, 8];
|
|
671
|
+
case "com.amazonaws.applicationautoscaling#ObjectNotFoundException": return [3, 8];
|
|
672
|
+
case "ValidationException": return [3, 10];
|
|
673
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 10];
|
|
674
|
+
}
|
|
675
|
+
return [3, 12];
|
|
676
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
677
|
+
case 3: throw _d.sent();
|
|
678
|
+
case 4: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
679
|
+
case 5: throw _d.sent();
|
|
680
|
+
case 6: return [4, deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)];
|
|
681
|
+
case 7: throw _d.sent();
|
|
682
|
+
case 8: return [4, deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context)];
|
|
683
|
+
case 9: throw _d.sent();
|
|
684
|
+
case 10: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
685
|
+
case 11: throw _d.sent();
|
|
686
|
+
case 12:
|
|
687
|
+
parsedBody = parsedOutput.body;
|
|
688
|
+
throwDefaultError({
|
|
689
|
+
output: output,
|
|
690
|
+
parsedBody: parsedBody,
|
|
691
|
+
exceptionCtor: __BaseException,
|
|
692
|
+
errorCode: errorCode,
|
|
693
|
+
});
|
|
694
|
+
_d.label = 13;
|
|
695
|
+
case 13: return [2];
|
|
696
|
+
}
|
|
697
|
+
});
|
|
698
|
+
}); };
|
|
699
|
+
export var deserializeAws_json1_1RegisterScalableTargetCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
700
|
+
var data, contents, response;
|
|
701
|
+
return __generator(this, function (_a) {
|
|
702
|
+
switch (_a.label) {
|
|
703
|
+
case 0:
|
|
704
|
+
if (output.statusCode >= 300) {
|
|
705
|
+
return [2, deserializeAws_json1_1RegisterScalableTargetCommandError(output, context)];
|
|
706
|
+
}
|
|
707
|
+
return [4, parseBody(output.body, context)];
|
|
708
|
+
case 1:
|
|
709
|
+
data = _a.sent();
|
|
710
|
+
contents = {};
|
|
711
|
+
contents = deserializeAws_json1_1RegisterScalableTargetResponse(data, context);
|
|
712
|
+
response = __assign({ $metadata: deserializeMetadata(output) }, contents);
|
|
713
|
+
return [2, Promise.resolve(response)];
|
|
714
|
+
}
|
|
715
|
+
});
|
|
716
|
+
}); };
|
|
717
|
+
var deserializeAws_json1_1RegisterScalableTargetCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
718
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
719
|
+
var _c;
|
|
720
|
+
return __generator(this, function (_d) {
|
|
721
|
+
switch (_d.label) {
|
|
722
|
+
case 0:
|
|
723
|
+
_a = [__assign({}, output)];
|
|
724
|
+
_c = {};
|
|
725
|
+
return [4, parseErrorBody(output.body, context)];
|
|
726
|
+
case 1:
|
|
727
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
728
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
729
|
+
_b = errorCode;
|
|
730
|
+
switch (_b) {
|
|
731
|
+
case "ConcurrentUpdateException": return [3, 2];
|
|
732
|
+
case "com.amazonaws.applicationautoscaling#ConcurrentUpdateException": return [3, 2];
|
|
733
|
+
case "InternalServiceException": return [3, 4];
|
|
734
|
+
case "com.amazonaws.applicationautoscaling#InternalServiceException": return [3, 4];
|
|
735
|
+
case "LimitExceededException": return [3, 6];
|
|
736
|
+
case "com.amazonaws.applicationautoscaling#LimitExceededException": return [3, 6];
|
|
737
|
+
case "ValidationException": return [3, 8];
|
|
738
|
+
case "com.amazonaws.applicationautoscaling#ValidationException": return [3, 8];
|
|
739
|
+
}
|
|
740
|
+
return [3, 10];
|
|
741
|
+
case 2: return [4, deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)];
|
|
742
|
+
case 3: throw _d.sent();
|
|
743
|
+
case 4: return [4, deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)];
|
|
744
|
+
case 5: throw _d.sent();
|
|
745
|
+
case 6: return [4, deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)];
|
|
746
|
+
case 7: throw _d.sent();
|
|
747
|
+
case 8: return [4, deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)];
|
|
748
|
+
case 9: throw _d.sent();
|
|
749
|
+
case 10:
|
|
750
|
+
parsedBody = parsedOutput.body;
|
|
751
|
+
throwDefaultError({
|
|
752
|
+
output: output,
|
|
753
|
+
parsedBody: parsedBody,
|
|
754
|
+
exceptionCtor: __BaseException,
|
|
755
|
+
errorCode: errorCode,
|
|
756
|
+
});
|
|
757
|
+
_d.label = 11;
|
|
758
|
+
case 11: return [2];
|
|
759
|
+
}
|
|
760
|
+
});
|
|
761
|
+
}); };
|
|
762
|
+
var deserializeAws_json1_1ConcurrentUpdateExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
763
|
+
var body, deserialized, exception;
|
|
764
|
+
return __generator(this, function (_a) {
|
|
765
|
+
body = parsedOutput.body;
|
|
766
|
+
deserialized = deserializeAws_json1_1ConcurrentUpdateException(body, context);
|
|
767
|
+
exception = new ConcurrentUpdateException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, deserialized));
|
|
768
|
+
return [2, __decorateServiceException(exception, body)];
|
|
769
|
+
});
|
|
770
|
+
}); };
|
|
771
|
+
var deserializeAws_json1_1FailedResourceAccessExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
772
|
+
var body, deserialized, exception;
|
|
773
|
+
return __generator(this, function (_a) {
|
|
774
|
+
body = parsedOutput.body;
|
|
775
|
+
deserialized = deserializeAws_json1_1FailedResourceAccessException(body, context);
|
|
776
|
+
exception = new FailedResourceAccessException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, deserialized));
|
|
777
|
+
return [2, __decorateServiceException(exception, body)];
|
|
778
|
+
});
|
|
779
|
+
}); };
|
|
780
|
+
var deserializeAws_json1_1InternalServiceExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
781
|
+
var body, deserialized, exception;
|
|
782
|
+
return __generator(this, function (_a) {
|
|
783
|
+
body = parsedOutput.body;
|
|
784
|
+
deserialized = deserializeAws_json1_1InternalServiceException(body, context);
|
|
785
|
+
exception = new InternalServiceException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, deserialized));
|
|
786
|
+
return [2, __decorateServiceException(exception, body)];
|
|
787
|
+
});
|
|
788
|
+
}); };
|
|
789
|
+
var deserializeAws_json1_1InvalidNextTokenExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
790
|
+
var body, deserialized, exception;
|
|
791
|
+
return __generator(this, function (_a) {
|
|
792
|
+
body = parsedOutput.body;
|
|
793
|
+
deserialized = deserializeAws_json1_1InvalidNextTokenException(body, context);
|
|
794
|
+
exception = new InvalidNextTokenException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, deserialized));
|
|
795
|
+
return [2, __decorateServiceException(exception, body)];
|
|
796
|
+
});
|
|
797
|
+
}); };
|
|
798
|
+
var deserializeAws_json1_1LimitExceededExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
799
|
+
var body, deserialized, exception;
|
|
800
|
+
return __generator(this, function (_a) {
|
|
801
|
+
body = parsedOutput.body;
|
|
802
|
+
deserialized = deserializeAws_json1_1LimitExceededException(body, context);
|
|
803
|
+
exception = new LimitExceededException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, deserialized));
|
|
804
|
+
return [2, __decorateServiceException(exception, body)];
|
|
805
|
+
});
|
|
806
|
+
}); };
|
|
807
|
+
var deserializeAws_json1_1ObjectNotFoundExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
808
|
+
var body, deserialized, exception;
|
|
809
|
+
return __generator(this, function (_a) {
|
|
810
|
+
body = parsedOutput.body;
|
|
811
|
+
deserialized = deserializeAws_json1_1ObjectNotFoundException(body, context);
|
|
812
|
+
exception = new ObjectNotFoundException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, deserialized));
|
|
813
|
+
return [2, __decorateServiceException(exception, body)];
|
|
814
|
+
});
|
|
815
|
+
}); };
|
|
816
|
+
var deserializeAws_json1_1ValidationExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
817
|
+
var body, deserialized, exception;
|
|
818
|
+
return __generator(this, function (_a) {
|
|
819
|
+
body = parsedOutput.body;
|
|
820
|
+
deserialized = deserializeAws_json1_1ValidationException(body, context);
|
|
821
|
+
exception = new ValidationException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, deserialized));
|
|
822
|
+
return [2, __decorateServiceException(exception, body)];
|
|
823
|
+
});
|
|
824
|
+
}); };
|
|
825
|
+
var serializeAws_json1_1CustomizedMetricSpecification = function (input, context) {
|
|
826
|
+
return __assign(__assign(__assign(__assign(__assign({}, (input.Dimensions != null && { Dimensions: serializeAws_json1_1MetricDimensions(input.Dimensions, context) })), (input.MetricName != null && { MetricName: input.MetricName })), (input.Namespace != null && { Namespace: input.Namespace })), (input.Statistic != null && { Statistic: input.Statistic })), (input.Unit != null && { Unit: input.Unit }));
|
|
598
827
|
};
|
|
599
|
-
|
|
600
|
-
return {
|
|
601
|
-
...(input.PolicyName != null && { PolicyName: input.PolicyName }),
|
|
602
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
603
|
-
...(input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension }),
|
|
604
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
605
|
-
};
|
|
828
|
+
var serializeAws_json1_1DeleteScalingPolicyRequest = function (input, context) {
|
|
829
|
+
return __assign(__assign(__assign(__assign({}, (input.PolicyName != null && { PolicyName: input.PolicyName })), (input.ResourceId != null && { ResourceId: input.ResourceId })), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }));
|
|
606
830
|
};
|
|
607
|
-
|
|
608
|
-
return {
|
|
609
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
610
|
-
...(input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension }),
|
|
611
|
-
...(input.ScheduledActionName != null && { ScheduledActionName: input.ScheduledActionName }),
|
|
612
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
613
|
-
};
|
|
831
|
+
var serializeAws_json1_1DeleteScheduledActionRequest = function (input, context) {
|
|
832
|
+
return __assign(__assign(__assign(__assign({}, (input.ResourceId != null && { ResourceId: input.ResourceId })), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ScheduledActionName != null && { ScheduledActionName: input.ScheduledActionName })), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }));
|
|
614
833
|
};
|
|
615
|
-
|
|
616
|
-
return {
|
|
617
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
618
|
-
...(input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension }),
|
|
619
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
620
|
-
};
|
|
834
|
+
var serializeAws_json1_1DeregisterScalableTargetRequest = function (input, context) {
|
|
835
|
+
return __assign(__assign(__assign({}, (input.ResourceId != null && { ResourceId: input.ResourceId })), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }));
|
|
621
836
|
};
|
|
622
|
-
|
|
623
|
-
return {
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
...(input.ResourceIds != null && {
|
|
627
|
-
ResourceIds: serializeAws_json1_1ResourceIdsMaxLen1600(input.ResourceIds, context),
|
|
628
|
-
}),
|
|
629
|
-
...(input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension }),
|
|
630
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
631
|
-
};
|
|
837
|
+
var serializeAws_json1_1DescribeScalableTargetsRequest = function (input, context) {
|
|
838
|
+
return __assign(__assign(__assign(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })), (input.ResourceIds != null && {
|
|
839
|
+
ResourceIds: serializeAws_json1_1ResourceIdsMaxLen1600(input.ResourceIds, context),
|
|
840
|
+
})), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }));
|
|
632
841
|
};
|
|
633
|
-
|
|
634
|
-
return {
|
|
635
|
-
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
636
|
-
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
637
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
638
|
-
...(input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension }),
|
|
639
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
640
|
-
};
|
|
842
|
+
var serializeAws_json1_1DescribeScalingActivitiesRequest = function (input, context) {
|
|
843
|
+
return __assign(__assign(__assign(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })), (input.ResourceId != null && { ResourceId: input.ResourceId })), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }));
|
|
641
844
|
};
|
|
642
|
-
|
|
643
|
-
return {
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
...(input.PolicyNames != null && {
|
|
647
|
-
PolicyNames: serializeAws_json1_1ResourceIdsMaxLen1600(input.PolicyNames, context),
|
|
648
|
-
}),
|
|
649
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
650
|
-
...(input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension }),
|
|
651
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
652
|
-
};
|
|
845
|
+
var serializeAws_json1_1DescribeScalingPoliciesRequest = function (input, context) {
|
|
846
|
+
return __assign(__assign(__assign(__assign(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })), (input.PolicyNames != null && {
|
|
847
|
+
PolicyNames: serializeAws_json1_1ResourceIdsMaxLen1600(input.PolicyNames, context),
|
|
848
|
+
})), (input.ResourceId != null && { ResourceId: input.ResourceId })), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }));
|
|
653
849
|
};
|
|
654
|
-
|
|
655
|
-
return {
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
659
|
-
...(input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension }),
|
|
660
|
-
...(input.ScheduledActionNames != null && {
|
|
661
|
-
ScheduledActionNames: serializeAws_json1_1ResourceIdsMaxLen1600(input.ScheduledActionNames, context),
|
|
662
|
-
}),
|
|
663
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
664
|
-
};
|
|
850
|
+
var serializeAws_json1_1DescribeScheduledActionsRequest = function (input, context) {
|
|
851
|
+
return __assign(__assign(__assign(__assign(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })), (input.ResourceId != null && { ResourceId: input.ResourceId })), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ScheduledActionNames != null && {
|
|
852
|
+
ScheduledActionNames: serializeAws_json1_1ResourceIdsMaxLen1600(input.ScheduledActionNames, context),
|
|
853
|
+
})), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }));
|
|
665
854
|
};
|
|
666
|
-
|
|
667
|
-
return {
|
|
668
|
-
...(input.Name != null && { Name: input.Name }),
|
|
669
|
-
...(input.Value != null && { Value: input.Value }),
|
|
670
|
-
};
|
|
855
|
+
var serializeAws_json1_1MetricDimension = function (input, context) {
|
|
856
|
+
return __assign(__assign({}, (input.Name != null && { Name: input.Name })), (input.Value != null && { Value: input.Value }));
|
|
671
857
|
};
|
|
672
|
-
|
|
858
|
+
var serializeAws_json1_1MetricDimensions = function (input, context) {
|
|
673
859
|
return input
|
|
674
|
-
.filter((e)
|
|
675
|
-
.map((entry)
|
|
860
|
+
.filter(function (e) { return e != null; })
|
|
861
|
+
.map(function (entry) {
|
|
676
862
|
return serializeAws_json1_1MetricDimension(entry, context);
|
|
677
863
|
});
|
|
678
864
|
};
|
|
679
|
-
|
|
680
|
-
return {
|
|
681
|
-
...(input.PredefinedMetricType != null && { PredefinedMetricType: input.PredefinedMetricType }),
|
|
682
|
-
...(input.ResourceLabel != null && { ResourceLabel: input.ResourceLabel }),
|
|
683
|
-
};
|
|
865
|
+
var serializeAws_json1_1PredefinedMetricSpecification = function (input, context) {
|
|
866
|
+
return __assign(__assign({}, (input.PredefinedMetricType != null && { PredefinedMetricType: input.PredefinedMetricType })), (input.ResourceLabel != null && { ResourceLabel: input.ResourceLabel }));
|
|
684
867
|
};
|
|
685
|
-
|
|
686
|
-
return {
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
692
|
-
...(input.StepScalingPolicyConfiguration != null && {
|
|
693
|
-
StepScalingPolicyConfiguration: serializeAws_json1_1StepScalingPolicyConfiguration(input.StepScalingPolicyConfiguration, context),
|
|
694
|
-
}),
|
|
695
|
-
...(input.TargetTrackingScalingPolicyConfiguration != null && {
|
|
696
|
-
TargetTrackingScalingPolicyConfiguration: serializeAws_json1_1TargetTrackingScalingPolicyConfiguration(input.TargetTrackingScalingPolicyConfiguration, context),
|
|
697
|
-
}),
|
|
698
|
-
};
|
|
868
|
+
var serializeAws_json1_1PutScalingPolicyRequest = function (input, context) {
|
|
869
|
+
return __assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.PolicyName != null && { PolicyName: input.PolicyName })), (input.PolicyType != null && { PolicyType: input.PolicyType })), (input.ResourceId != null && { ResourceId: input.ResourceId })), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace })), (input.StepScalingPolicyConfiguration != null && {
|
|
870
|
+
StepScalingPolicyConfiguration: serializeAws_json1_1StepScalingPolicyConfiguration(input.StepScalingPolicyConfiguration, context),
|
|
871
|
+
})), (input.TargetTrackingScalingPolicyConfiguration != null && {
|
|
872
|
+
TargetTrackingScalingPolicyConfiguration: serializeAws_json1_1TargetTrackingScalingPolicyConfiguration(input.TargetTrackingScalingPolicyConfiguration, context),
|
|
873
|
+
}));
|
|
699
874
|
};
|
|
700
|
-
|
|
701
|
-
return {
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
...(input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension }),
|
|
705
|
-
...(input.ScalableTargetAction != null && {
|
|
706
|
-
ScalableTargetAction: serializeAws_json1_1ScalableTargetAction(input.ScalableTargetAction, context),
|
|
707
|
-
}),
|
|
708
|
-
...(input.Schedule != null && { Schedule: input.Schedule }),
|
|
709
|
-
...(input.ScheduledActionName != null && { ScheduledActionName: input.ScheduledActionName }),
|
|
710
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
711
|
-
...(input.StartTime != null && { StartTime: Math.round(input.StartTime.getTime() / 1000) }),
|
|
712
|
-
...(input.Timezone != null && { Timezone: input.Timezone }),
|
|
713
|
-
};
|
|
875
|
+
var serializeAws_json1_1PutScheduledActionRequest = function (input, context) {
|
|
876
|
+
return __assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.EndTime != null && { EndTime: Math.round(input.EndTime.getTime() / 1000) })), (input.ResourceId != null && { ResourceId: input.ResourceId })), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ScalableTargetAction != null && {
|
|
877
|
+
ScalableTargetAction: serializeAws_json1_1ScalableTargetAction(input.ScalableTargetAction, context),
|
|
878
|
+
})), (input.Schedule != null && { Schedule: input.Schedule })), (input.ScheduledActionName != null && { ScheduledActionName: input.ScheduledActionName })), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace })), (input.StartTime != null && { StartTime: Math.round(input.StartTime.getTime() / 1000) })), (input.Timezone != null && { Timezone: input.Timezone }));
|
|
714
879
|
};
|
|
715
|
-
|
|
716
|
-
return {
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
720
|
-
...(input.RoleARN != null && { RoleARN: input.RoleARN }),
|
|
721
|
-
...(input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension }),
|
|
722
|
-
...(input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace }),
|
|
723
|
-
...(input.SuspendedState != null && {
|
|
724
|
-
SuspendedState: serializeAws_json1_1SuspendedState(input.SuspendedState, context),
|
|
725
|
-
}),
|
|
726
|
-
};
|
|
880
|
+
var serializeAws_json1_1RegisterScalableTargetRequest = function (input, context) {
|
|
881
|
+
return __assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.MaxCapacity != null && { MaxCapacity: input.MaxCapacity })), (input.MinCapacity != null && { MinCapacity: input.MinCapacity })), (input.ResourceId != null && { ResourceId: input.ResourceId })), (input.RoleARN != null && { RoleARN: input.RoleARN })), (input.ScalableDimension != null && { ScalableDimension: input.ScalableDimension })), (input.ServiceNamespace != null && { ServiceNamespace: input.ServiceNamespace })), (input.SuspendedState != null && {
|
|
882
|
+
SuspendedState: serializeAws_json1_1SuspendedState(input.SuspendedState, context),
|
|
883
|
+
}));
|
|
727
884
|
};
|
|
728
|
-
|
|
885
|
+
var serializeAws_json1_1ResourceIdsMaxLen1600 = function (input, context) {
|
|
729
886
|
return input
|
|
730
|
-
.filter((e)
|
|
731
|
-
.map((entry)
|
|
887
|
+
.filter(function (e) { return e != null; })
|
|
888
|
+
.map(function (entry) {
|
|
732
889
|
return entry;
|
|
733
890
|
});
|
|
734
891
|
};
|
|
735
|
-
|
|
736
|
-
return {
|
|
737
|
-
...(input.MaxCapacity != null && { MaxCapacity: input.MaxCapacity }),
|
|
738
|
-
...(input.MinCapacity != null && { MinCapacity: input.MinCapacity }),
|
|
739
|
-
};
|
|
892
|
+
var serializeAws_json1_1ScalableTargetAction = function (input, context) {
|
|
893
|
+
return __assign(__assign({}, (input.MaxCapacity != null && { MaxCapacity: input.MaxCapacity })), (input.MinCapacity != null && { MinCapacity: input.MinCapacity }));
|
|
740
894
|
};
|
|
741
|
-
|
|
742
|
-
return {
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
MetricIntervalUpperBound: __serializeFloat(input.MetricIntervalUpperBound),
|
|
748
|
-
}),
|
|
749
|
-
...(input.ScalingAdjustment != null && { ScalingAdjustment: input.ScalingAdjustment }),
|
|
750
|
-
};
|
|
895
|
+
var serializeAws_json1_1StepAdjustment = function (input, context) {
|
|
896
|
+
return __assign(__assign(__assign({}, (input.MetricIntervalLowerBound != null && {
|
|
897
|
+
MetricIntervalLowerBound: __serializeFloat(input.MetricIntervalLowerBound),
|
|
898
|
+
})), (input.MetricIntervalUpperBound != null && {
|
|
899
|
+
MetricIntervalUpperBound: __serializeFloat(input.MetricIntervalUpperBound),
|
|
900
|
+
})), (input.ScalingAdjustment != null && { ScalingAdjustment: input.ScalingAdjustment }));
|
|
751
901
|
};
|
|
752
|
-
|
|
902
|
+
var serializeAws_json1_1StepAdjustments = function (input, context) {
|
|
753
903
|
return input
|
|
754
|
-
.filter((e)
|
|
755
|
-
.map((entry)
|
|
904
|
+
.filter(function (e) { return e != null; })
|
|
905
|
+
.map(function (entry) {
|
|
756
906
|
return serializeAws_json1_1StepAdjustment(entry, context);
|
|
757
907
|
});
|
|
758
908
|
};
|
|
759
|
-
|
|
760
|
-
return {
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
...(input.MetricAggregationType != null && { MetricAggregationType: input.MetricAggregationType }),
|
|
764
|
-
...(input.MinAdjustmentMagnitude != null && { MinAdjustmentMagnitude: input.MinAdjustmentMagnitude }),
|
|
765
|
-
...(input.StepAdjustments != null && {
|
|
766
|
-
StepAdjustments: serializeAws_json1_1StepAdjustments(input.StepAdjustments, context),
|
|
767
|
-
}),
|
|
768
|
-
};
|
|
909
|
+
var serializeAws_json1_1StepScalingPolicyConfiguration = function (input, context) {
|
|
910
|
+
return __assign(__assign(__assign(__assign(__assign({}, (input.AdjustmentType != null && { AdjustmentType: input.AdjustmentType })), (input.Cooldown != null && { Cooldown: input.Cooldown })), (input.MetricAggregationType != null && { MetricAggregationType: input.MetricAggregationType })), (input.MinAdjustmentMagnitude != null && { MinAdjustmentMagnitude: input.MinAdjustmentMagnitude })), (input.StepAdjustments != null && {
|
|
911
|
+
StepAdjustments: serializeAws_json1_1StepAdjustments(input.StepAdjustments, context),
|
|
912
|
+
}));
|
|
769
913
|
};
|
|
770
|
-
|
|
771
|
-
return {
|
|
772
|
-
...(input.DynamicScalingInSuspended != null && { DynamicScalingInSuspended: input.DynamicScalingInSuspended }),
|
|
773
|
-
...(input.DynamicScalingOutSuspended != null && { DynamicScalingOutSuspended: input.DynamicScalingOutSuspended }),
|
|
774
|
-
...(input.ScheduledScalingSuspended != null && { ScheduledScalingSuspended: input.ScheduledScalingSuspended }),
|
|
775
|
-
};
|
|
914
|
+
var serializeAws_json1_1SuspendedState = function (input, context) {
|
|
915
|
+
return __assign(__assign(__assign({}, (input.DynamicScalingInSuspended != null && { DynamicScalingInSuspended: input.DynamicScalingInSuspended })), (input.DynamicScalingOutSuspended != null && { DynamicScalingOutSuspended: input.DynamicScalingOutSuspended })), (input.ScheduledScalingSuspended != null && { ScheduledScalingSuspended: input.ScheduledScalingSuspended }));
|
|
776
916
|
};
|
|
777
|
-
|
|
778
|
-
return {
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
...(input.PredefinedMetricSpecification != null && {
|
|
784
|
-
PredefinedMetricSpecification: serializeAws_json1_1PredefinedMetricSpecification(input.PredefinedMetricSpecification, context),
|
|
785
|
-
}),
|
|
786
|
-
...(input.ScaleInCooldown != null && { ScaleInCooldown: input.ScaleInCooldown }),
|
|
787
|
-
...(input.ScaleOutCooldown != null && { ScaleOutCooldown: input.ScaleOutCooldown }),
|
|
788
|
-
...(input.TargetValue != null && { TargetValue: __serializeFloat(input.TargetValue) }),
|
|
789
|
-
};
|
|
917
|
+
var serializeAws_json1_1TargetTrackingScalingPolicyConfiguration = function (input, context) {
|
|
918
|
+
return __assign(__assign(__assign(__assign(__assign(__assign({}, (input.CustomizedMetricSpecification != null && {
|
|
919
|
+
CustomizedMetricSpecification: serializeAws_json1_1CustomizedMetricSpecification(input.CustomizedMetricSpecification, context),
|
|
920
|
+
})), (input.DisableScaleIn != null && { DisableScaleIn: input.DisableScaleIn })), (input.PredefinedMetricSpecification != null && {
|
|
921
|
+
PredefinedMetricSpecification: serializeAws_json1_1PredefinedMetricSpecification(input.PredefinedMetricSpecification, context),
|
|
922
|
+
})), (input.ScaleInCooldown != null && { ScaleInCooldown: input.ScaleInCooldown })), (input.ScaleOutCooldown != null && { ScaleOutCooldown: input.ScaleOutCooldown })), (input.TargetValue != null && { TargetValue: __serializeFloat(input.TargetValue) }));
|
|
790
923
|
};
|
|
791
|
-
|
|
924
|
+
var deserializeAws_json1_1Alarm = function (output, context) {
|
|
792
925
|
return {
|
|
793
926
|
AlarmARN: __expectString(output.AlarmARN),
|
|
794
927
|
AlarmName: __expectString(output.AlarmName),
|
|
795
928
|
};
|
|
796
929
|
};
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
.filter((e)
|
|
800
|
-
.map((entry)
|
|
930
|
+
var deserializeAws_json1_1Alarms = function (output, context) {
|
|
931
|
+
var retVal = (output || [])
|
|
932
|
+
.filter(function (e) { return e != null; })
|
|
933
|
+
.map(function (entry) {
|
|
801
934
|
if (entry === null) {
|
|
802
935
|
return null;
|
|
803
936
|
}
|
|
@@ -805,12 +938,12 @@ const deserializeAws_json1_1Alarms = (output, context) => {
|
|
|
805
938
|
});
|
|
806
939
|
return retVal;
|
|
807
940
|
};
|
|
808
|
-
|
|
941
|
+
var deserializeAws_json1_1ConcurrentUpdateException = function (output, context) {
|
|
809
942
|
return {
|
|
810
943
|
Message: __expectString(output.Message),
|
|
811
944
|
};
|
|
812
945
|
};
|
|
813
|
-
|
|
946
|
+
var deserializeAws_json1_1CustomizedMetricSpecification = function (output, context) {
|
|
814
947
|
return {
|
|
815
948
|
Dimensions: output.Dimensions != null ? deserializeAws_json1_1MetricDimensions(output.Dimensions, context) : undefined,
|
|
816
949
|
MetricName: __expectString(output.MetricName),
|
|
@@ -819,16 +952,16 @@ const deserializeAws_json1_1CustomizedMetricSpecification = (output, context) =>
|
|
|
819
952
|
Unit: __expectString(output.Unit),
|
|
820
953
|
};
|
|
821
954
|
};
|
|
822
|
-
|
|
955
|
+
var deserializeAws_json1_1DeleteScalingPolicyResponse = function (output, context) {
|
|
823
956
|
return {};
|
|
824
957
|
};
|
|
825
|
-
|
|
958
|
+
var deserializeAws_json1_1DeleteScheduledActionResponse = function (output, context) {
|
|
826
959
|
return {};
|
|
827
960
|
};
|
|
828
|
-
|
|
961
|
+
var deserializeAws_json1_1DeregisterScalableTargetResponse = function (output, context) {
|
|
829
962
|
return {};
|
|
830
963
|
};
|
|
831
|
-
|
|
964
|
+
var deserializeAws_json1_1DescribeScalableTargetsResponse = function (output, context) {
|
|
832
965
|
return {
|
|
833
966
|
NextToken: __expectString(output.NextToken),
|
|
834
967
|
ScalableTargets: output.ScalableTargets != null
|
|
@@ -836,7 +969,7 @@ const deserializeAws_json1_1DescribeScalableTargetsResponse = (output, context)
|
|
|
836
969
|
: undefined,
|
|
837
970
|
};
|
|
838
971
|
};
|
|
839
|
-
|
|
972
|
+
var deserializeAws_json1_1DescribeScalingActivitiesResponse = function (output, context) {
|
|
840
973
|
return {
|
|
841
974
|
NextToken: __expectString(output.NextToken),
|
|
842
975
|
ScalingActivities: output.ScalingActivities != null
|
|
@@ -844,7 +977,7 @@ const deserializeAws_json1_1DescribeScalingActivitiesResponse = (output, context
|
|
|
844
977
|
: undefined,
|
|
845
978
|
};
|
|
846
979
|
};
|
|
847
|
-
|
|
980
|
+
var deserializeAws_json1_1DescribeScalingPoliciesResponse = function (output, context) {
|
|
848
981
|
return {
|
|
849
982
|
NextToken: __expectString(output.NextToken),
|
|
850
983
|
ScalingPolicies: output.ScalingPolicies != null
|
|
@@ -852,7 +985,7 @@ const deserializeAws_json1_1DescribeScalingPoliciesResponse = (output, context)
|
|
|
852
985
|
: undefined,
|
|
853
986
|
};
|
|
854
987
|
};
|
|
855
|
-
|
|
988
|
+
var deserializeAws_json1_1DescribeScheduledActionsResponse = function (output, context) {
|
|
856
989
|
return {
|
|
857
990
|
NextToken: __expectString(output.NextToken),
|
|
858
991
|
ScheduledActions: output.ScheduledActions != null
|
|
@@ -860,36 +993,36 @@ const deserializeAws_json1_1DescribeScheduledActionsResponse = (output, context)
|
|
|
860
993
|
: undefined,
|
|
861
994
|
};
|
|
862
995
|
};
|
|
863
|
-
|
|
996
|
+
var deserializeAws_json1_1FailedResourceAccessException = function (output, context) {
|
|
864
997
|
return {
|
|
865
998
|
Message: __expectString(output.Message),
|
|
866
999
|
};
|
|
867
1000
|
};
|
|
868
|
-
|
|
1001
|
+
var deserializeAws_json1_1InternalServiceException = function (output, context) {
|
|
869
1002
|
return {
|
|
870
1003
|
Message: __expectString(output.Message),
|
|
871
1004
|
};
|
|
872
1005
|
};
|
|
873
|
-
|
|
1006
|
+
var deserializeAws_json1_1InvalidNextTokenException = function (output, context) {
|
|
874
1007
|
return {
|
|
875
1008
|
Message: __expectString(output.Message),
|
|
876
1009
|
};
|
|
877
1010
|
};
|
|
878
|
-
|
|
1011
|
+
var deserializeAws_json1_1LimitExceededException = function (output, context) {
|
|
879
1012
|
return {
|
|
880
1013
|
Message: __expectString(output.Message),
|
|
881
1014
|
};
|
|
882
1015
|
};
|
|
883
|
-
|
|
1016
|
+
var deserializeAws_json1_1MetricDimension = function (output, context) {
|
|
884
1017
|
return {
|
|
885
1018
|
Name: __expectString(output.Name),
|
|
886
1019
|
Value: __expectString(output.Value),
|
|
887
1020
|
};
|
|
888
1021
|
};
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
.filter((e)
|
|
892
|
-
.map((entry)
|
|
1022
|
+
var deserializeAws_json1_1MetricDimensions = function (output, context) {
|
|
1023
|
+
var retVal = (output || [])
|
|
1024
|
+
.filter(function (e) { return e != null; })
|
|
1025
|
+
.map(function (entry) {
|
|
893
1026
|
if (entry === null) {
|
|
894
1027
|
return null;
|
|
895
1028
|
}
|
|
@@ -897,30 +1030,30 @@ const deserializeAws_json1_1MetricDimensions = (output, context) => {
|
|
|
897
1030
|
});
|
|
898
1031
|
return retVal;
|
|
899
1032
|
};
|
|
900
|
-
|
|
1033
|
+
var deserializeAws_json1_1ObjectNotFoundException = function (output, context) {
|
|
901
1034
|
return {
|
|
902
1035
|
Message: __expectString(output.Message),
|
|
903
1036
|
};
|
|
904
1037
|
};
|
|
905
|
-
|
|
1038
|
+
var deserializeAws_json1_1PredefinedMetricSpecification = function (output, context) {
|
|
906
1039
|
return {
|
|
907
1040
|
PredefinedMetricType: __expectString(output.PredefinedMetricType),
|
|
908
1041
|
ResourceLabel: __expectString(output.ResourceLabel),
|
|
909
1042
|
};
|
|
910
1043
|
};
|
|
911
|
-
|
|
1044
|
+
var deserializeAws_json1_1PutScalingPolicyResponse = function (output, context) {
|
|
912
1045
|
return {
|
|
913
1046
|
Alarms: output.Alarms != null ? deserializeAws_json1_1Alarms(output.Alarms, context) : undefined,
|
|
914
1047
|
PolicyARN: __expectString(output.PolicyARN),
|
|
915
1048
|
};
|
|
916
1049
|
};
|
|
917
|
-
|
|
1050
|
+
var deserializeAws_json1_1PutScheduledActionResponse = function (output, context) {
|
|
918
1051
|
return {};
|
|
919
1052
|
};
|
|
920
|
-
|
|
1053
|
+
var deserializeAws_json1_1RegisterScalableTargetResponse = function (output, context) {
|
|
921
1054
|
return {};
|
|
922
1055
|
};
|
|
923
|
-
|
|
1056
|
+
var deserializeAws_json1_1ScalableTarget = function (output, context) {
|
|
924
1057
|
return {
|
|
925
1058
|
CreationTime: output.CreationTime != null
|
|
926
1059
|
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreationTime)))
|
|
@@ -934,16 +1067,16 @@ const deserializeAws_json1_1ScalableTarget = (output, context) => {
|
|
|
934
1067
|
SuspendedState: output.SuspendedState != null ? deserializeAws_json1_1SuspendedState(output.SuspendedState, context) : undefined,
|
|
935
1068
|
};
|
|
936
1069
|
};
|
|
937
|
-
|
|
1070
|
+
var deserializeAws_json1_1ScalableTargetAction = function (output, context) {
|
|
938
1071
|
return {
|
|
939
1072
|
MaxCapacity: __expectInt32(output.MaxCapacity),
|
|
940
1073
|
MinCapacity: __expectInt32(output.MinCapacity),
|
|
941
1074
|
};
|
|
942
1075
|
};
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
.filter((e)
|
|
946
|
-
.map((entry)
|
|
1076
|
+
var deserializeAws_json1_1ScalableTargets = function (output, context) {
|
|
1077
|
+
var retVal = (output || [])
|
|
1078
|
+
.filter(function (e) { return e != null; })
|
|
1079
|
+
.map(function (entry) {
|
|
947
1080
|
if (entry === null) {
|
|
948
1081
|
return null;
|
|
949
1082
|
}
|
|
@@ -951,10 +1084,10 @@ const deserializeAws_json1_1ScalableTargets = (output, context) => {
|
|
|
951
1084
|
});
|
|
952
1085
|
return retVal;
|
|
953
1086
|
};
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
.filter((e)
|
|
957
|
-
.map((entry)
|
|
1087
|
+
var deserializeAws_json1_1ScalingActivities = function (output, context) {
|
|
1088
|
+
var retVal = (output || [])
|
|
1089
|
+
.filter(function (e) { return e != null; })
|
|
1090
|
+
.map(function (entry) {
|
|
958
1091
|
if (entry === null) {
|
|
959
1092
|
return null;
|
|
960
1093
|
}
|
|
@@ -962,7 +1095,7 @@ const deserializeAws_json1_1ScalingActivities = (output, context) => {
|
|
|
962
1095
|
});
|
|
963
1096
|
return retVal;
|
|
964
1097
|
};
|
|
965
|
-
|
|
1098
|
+
var deserializeAws_json1_1ScalingActivity = function (output, context) {
|
|
966
1099
|
return {
|
|
967
1100
|
ActivityId: __expectString(output.ActivityId),
|
|
968
1101
|
Cause: __expectString(output.Cause),
|
|
@@ -977,10 +1110,10 @@ const deserializeAws_json1_1ScalingActivity = (output, context) => {
|
|
|
977
1110
|
StatusMessage: __expectString(output.StatusMessage),
|
|
978
1111
|
};
|
|
979
1112
|
};
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
.filter((e)
|
|
983
|
-
.map((entry)
|
|
1113
|
+
var deserializeAws_json1_1ScalingPolicies = function (output, context) {
|
|
1114
|
+
var retVal = (output || [])
|
|
1115
|
+
.filter(function (e) { return e != null; })
|
|
1116
|
+
.map(function (entry) {
|
|
984
1117
|
if (entry === null) {
|
|
985
1118
|
return null;
|
|
986
1119
|
}
|
|
@@ -988,7 +1121,7 @@ const deserializeAws_json1_1ScalingPolicies = (output, context) => {
|
|
|
988
1121
|
});
|
|
989
1122
|
return retVal;
|
|
990
1123
|
};
|
|
991
|
-
|
|
1124
|
+
var deserializeAws_json1_1ScalingPolicy = function (output, context) {
|
|
992
1125
|
return {
|
|
993
1126
|
Alarms: output.Alarms != null ? deserializeAws_json1_1Alarms(output.Alarms, context) : undefined,
|
|
994
1127
|
CreationTime: output.CreationTime != null
|
|
@@ -1008,7 +1141,7 @@ const deserializeAws_json1_1ScalingPolicy = (output, context) => {
|
|
|
1008
1141
|
: undefined,
|
|
1009
1142
|
};
|
|
1010
1143
|
};
|
|
1011
|
-
|
|
1144
|
+
var deserializeAws_json1_1ScheduledAction = function (output, context) {
|
|
1012
1145
|
return {
|
|
1013
1146
|
CreationTime: output.CreationTime != null
|
|
1014
1147
|
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreationTime)))
|
|
@@ -1027,10 +1160,10 @@ const deserializeAws_json1_1ScheduledAction = (output, context) => {
|
|
|
1027
1160
|
Timezone: __expectString(output.Timezone),
|
|
1028
1161
|
};
|
|
1029
1162
|
};
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
.filter((e)
|
|
1033
|
-
.map((entry)
|
|
1163
|
+
var deserializeAws_json1_1ScheduledActions = function (output, context) {
|
|
1164
|
+
var retVal = (output || [])
|
|
1165
|
+
.filter(function (e) { return e != null; })
|
|
1166
|
+
.map(function (entry) {
|
|
1034
1167
|
if (entry === null) {
|
|
1035
1168
|
return null;
|
|
1036
1169
|
}
|
|
@@ -1038,17 +1171,17 @@ const deserializeAws_json1_1ScheduledActions = (output, context) => {
|
|
|
1038
1171
|
});
|
|
1039
1172
|
return retVal;
|
|
1040
1173
|
};
|
|
1041
|
-
|
|
1174
|
+
var deserializeAws_json1_1StepAdjustment = function (output, context) {
|
|
1042
1175
|
return {
|
|
1043
1176
|
MetricIntervalLowerBound: __limitedParseDouble(output.MetricIntervalLowerBound),
|
|
1044
1177
|
MetricIntervalUpperBound: __limitedParseDouble(output.MetricIntervalUpperBound),
|
|
1045
1178
|
ScalingAdjustment: __expectInt32(output.ScalingAdjustment),
|
|
1046
1179
|
};
|
|
1047
1180
|
};
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
.filter((e)
|
|
1051
|
-
.map((entry)
|
|
1181
|
+
var deserializeAws_json1_1StepAdjustments = function (output, context) {
|
|
1182
|
+
var retVal = (output || [])
|
|
1183
|
+
.filter(function (e) { return e != null; })
|
|
1184
|
+
.map(function (entry) {
|
|
1052
1185
|
if (entry === null) {
|
|
1053
1186
|
return null;
|
|
1054
1187
|
}
|
|
@@ -1056,7 +1189,7 @@ const deserializeAws_json1_1StepAdjustments = (output, context) => {
|
|
|
1056
1189
|
});
|
|
1057
1190
|
return retVal;
|
|
1058
1191
|
};
|
|
1059
|
-
|
|
1192
|
+
var deserializeAws_json1_1StepScalingPolicyConfiguration = function (output, context) {
|
|
1060
1193
|
return {
|
|
1061
1194
|
AdjustmentType: __expectString(output.AdjustmentType),
|
|
1062
1195
|
Cooldown: __expectInt32(output.Cooldown),
|
|
@@ -1067,14 +1200,14 @@ const deserializeAws_json1_1StepScalingPolicyConfiguration = (output, context) =
|
|
|
1067
1200
|
: undefined,
|
|
1068
1201
|
};
|
|
1069
1202
|
};
|
|
1070
|
-
|
|
1203
|
+
var deserializeAws_json1_1SuspendedState = function (output, context) {
|
|
1071
1204
|
return {
|
|
1072
1205
|
DynamicScalingInSuspended: __expectBoolean(output.DynamicScalingInSuspended),
|
|
1073
1206
|
DynamicScalingOutSuspended: __expectBoolean(output.DynamicScalingOutSuspended),
|
|
1074
1207
|
ScheduledScalingSuspended: __expectBoolean(output.ScheduledScalingSuspended),
|
|
1075
1208
|
};
|
|
1076
1209
|
};
|
|
1077
|
-
|
|
1210
|
+
var deserializeAws_json1_1TargetTrackingScalingPolicyConfiguration = function (output, context) {
|
|
1078
1211
|
return {
|
|
1079
1212
|
CustomizedMetricSpecification: output.CustomizedMetricSpecification != null
|
|
1080
1213
|
? deserializeAws_json1_1CustomizedMetricSpecification(output.CustomizedMetricSpecification, context)
|
|
@@ -1088,57 +1221,80 @@ const deserializeAws_json1_1TargetTrackingScalingPolicyConfiguration = (output,
|
|
|
1088
1221
|
TargetValue: __limitedParseDouble(output.TargetValue),
|
|
1089
1222
|
};
|
|
1090
1223
|
};
|
|
1091
|
-
|
|
1224
|
+
var deserializeAws_json1_1ValidationException = function (output, context) {
|
|
1092
1225
|
return {
|
|
1093
1226
|
Message: __expectString(output.Message),
|
|
1094
1227
|
};
|
|
1095
1228
|
};
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1229
|
+
var deserializeMetadata = function (output) {
|
|
1230
|
+
var _a, _b;
|
|
1231
|
+
return ({
|
|
1232
|
+
httpStatusCode: output.statusCode,
|
|
1233
|
+
requestId: (_b = (_a = output.headers["x-amzn-requestid"]) !== null && _a !== void 0 ? _a : output.headers["x-amzn-request-id"]) !== null && _b !== void 0 ? _b : output.headers["x-amz-request-id"],
|
|
1234
|
+
extendedRequestId: output.headers["x-amz-id-2"],
|
|
1235
|
+
cfId: output.headers["x-amz-cf-id"],
|
|
1236
|
+
});
|
|
1237
|
+
};
|
|
1238
|
+
var collectBody = function (streamBody, context) {
|
|
1239
|
+
if (streamBody === void 0) { streamBody = new Uint8Array(); }
|
|
1103
1240
|
if (streamBody instanceof Uint8Array) {
|
|
1104
1241
|
return Promise.resolve(streamBody);
|
|
1105
1242
|
}
|
|
1106
1243
|
return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
|
|
1107
1244
|
};
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1245
|
+
var collectBodyString = function (streamBody, context) {
|
|
1246
|
+
return collectBody(streamBody, context).then(function (body) { return context.utf8Encoder(body); });
|
|
1247
|
+
};
|
|
1248
|
+
var buildHttpRpcRequest = function (context, headers, path, resolvedHostname, body) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1249
|
+
var _a, hostname, _b, protocol, port, basePath, contents;
|
|
1250
|
+
return __generator(this, function (_c) {
|
|
1251
|
+
switch (_c.label) {
|
|
1252
|
+
case 0: return [4, context.endpoint()];
|
|
1253
|
+
case 1:
|
|
1254
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
1255
|
+
contents = {
|
|
1256
|
+
protocol: protocol,
|
|
1257
|
+
hostname: hostname,
|
|
1258
|
+
port: port,
|
|
1259
|
+
method: "POST",
|
|
1260
|
+
path: basePath.endsWith("/") ? basePath.slice(0, -1) + path : basePath + path,
|
|
1261
|
+
headers: headers,
|
|
1262
|
+
};
|
|
1263
|
+
if (resolvedHostname !== undefined) {
|
|
1264
|
+
contents.hostname = resolvedHostname;
|
|
1265
|
+
}
|
|
1266
|
+
if (body !== undefined) {
|
|
1267
|
+
contents.body = body;
|
|
1268
|
+
}
|
|
1269
|
+
return [2, new __HttpRequest(contents)];
|
|
1270
|
+
}
|
|
1271
|
+
});
|
|
1272
|
+
}); };
|
|
1273
|
+
var parseBody = function (streamBody, context) {
|
|
1274
|
+
return collectBodyString(streamBody, context).then(function (encoded) {
|
|
1275
|
+
if (encoded.length) {
|
|
1276
|
+
return JSON.parse(encoded);
|
|
1277
|
+
}
|
|
1278
|
+
return {};
|
|
1279
|
+
});
|
|
1137
1280
|
};
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1281
|
+
var parseErrorBody = function (errorBody, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1282
|
+
var value;
|
|
1283
|
+
var _a;
|
|
1284
|
+
return __generator(this, function (_b) {
|
|
1285
|
+
switch (_b.label) {
|
|
1286
|
+
case 0: return [4, parseBody(errorBody, context)];
|
|
1287
|
+
case 1:
|
|
1288
|
+
value = _b.sent();
|
|
1289
|
+
value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
|
|
1290
|
+
return [2, value];
|
|
1291
|
+
}
|
|
1292
|
+
});
|
|
1293
|
+
}); };
|
|
1294
|
+
var loadRestJsonErrorCode = function (output, data) {
|
|
1295
|
+
var findKey = function (object, key) { return Object.keys(object).find(function (k) { return k.toLowerCase() === key.toLowerCase(); }); };
|
|
1296
|
+
var sanitizeErrorCode = function (rawValue) {
|
|
1297
|
+
var cleanValue = rawValue;
|
|
1142
1298
|
if (typeof cleanValue === "number") {
|
|
1143
1299
|
cleanValue = cleanValue.toString();
|
|
1144
1300
|
}
|
|
@@ -1153,7 +1309,7 @@ const loadRestJsonErrorCode = (output, data) => {
|
|
|
1153
1309
|
}
|
|
1154
1310
|
return cleanValue;
|
|
1155
1311
|
};
|
|
1156
|
-
|
|
1312
|
+
var headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
1157
1313
|
if (headerKey !== undefined) {
|
|
1158
1314
|
return sanitizeErrorCode(output.headers[headerKey]);
|
|
1159
1315
|
}
|