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