@aws-sdk/client-route53-recovery-cluster 3.50.0 → 3.53.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 +27 -0
- package/dist-cjs/index.js +3 -0
- package/dist-cjs/models/Route53RecoveryClusterServiceException.js +11 -0
- package/dist-cjs/models/models_0.js +101 -1
- package/dist-cjs/protocols/Aws_json1_0.js +57 -186
- package/dist-es/index.js +1 -0
- package/dist-es/models/Route53RecoveryClusterServiceException.js +12 -0
- package/dist-es/models/models_0.js +94 -1
- package/dist-es/protocols/Aws_json1_0.js +102 -185
- package/dist-types/index.d.ts +1 -0
- package/dist-types/models/Route53RecoveryClusterServiceException.d.ts +10 -0
- package/dist-types/models/models_0.d.ts +51 -32
- package/dist-types/ts3.4/Route53RecoveryCluster.d.ts +20 -0
- package/dist-types/ts3.4/Route53RecoveryClusterClient.d.ts +76 -0
- package/dist-types/ts3.4/commands/GetRoutingControlStateCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UpdateRoutingControlStateCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UpdateRoutingControlStatesCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/index.d.ts +3 -0
- package/dist-types/ts3.4/endpoints.d.ts +2 -0
- package/dist-types/ts3.4/index.d.ts +5 -0
- package/dist-types/ts3.4/models/Route53RecoveryClusterServiceException.d.ts +6 -0
- package/dist-types/ts3.4/models/index.d.ts +1 -0
- package/dist-types/ts3.4/models/models_0.d.ts +147 -0
- package/dist-types/ts3.4/protocols/Aws_json1_0.d.ts +11 -0
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +38 -0
- package/dist-types/ts3.4/runtimeConfig.d.ts +38 -0
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +37 -0
- package/dist-types/ts3.4/runtimeConfig.shared.d.ts +11 -0
- package/package.json +33 -33
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,33 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [3.53.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.52.0...v3.53.0) (2022-02-24)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* **clients:** generate service exceptions as classes ([#3267](https://github.com/aws/aws-sdk-js-v3/issues/3267)) ([ca64fee](https://github.com/aws/aws-sdk-js-v3/commit/ca64feed3351c394c07dc26b782a5760a396a074))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
# [3.52.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.51.0...v3.52.0) (2022-02-18)
|
|
18
|
+
|
|
19
|
+
**Note:** Version bump only for package @aws-sdk/client-route53-recovery-cluster
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
# [3.51.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.50.0...v3.51.0) (2022-02-12)
|
|
26
|
+
|
|
27
|
+
**Note:** Version bump only for package @aws-sdk/client-route53-recovery-cluster
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
6
33
|
# [3.50.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.49.0...v3.50.0) (2022-02-08)
|
|
7
34
|
|
|
8
35
|
**Note:** Version bump only for package @aws-sdk/client-route53-recovery-cluster
|
package/dist-cjs/index.js
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Route53RecoveryClusterServiceException = void 0;
|
|
3
4
|
const tslib_1 = require("tslib");
|
|
4
5
|
tslib_1.__exportStar(require("./Route53RecoveryCluster"), exports);
|
|
5
6
|
tslib_1.__exportStar(require("./Route53RecoveryClusterClient"), exports);
|
|
6
7
|
tslib_1.__exportStar(require("./commands"), exports);
|
|
7
8
|
tslib_1.__exportStar(require("./models"), exports);
|
|
9
|
+
var Route53RecoveryClusterServiceException_1 = require("./models/Route53RecoveryClusterServiceException");
|
|
10
|
+
Object.defineProperty(exports, "Route53RecoveryClusterServiceException", { enumerable: true, get: function () { return Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException; } });
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Route53RecoveryClusterServiceException = void 0;
|
|
4
|
+
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
5
|
+
class Route53RecoveryClusterServiceException extends smithy_client_1.ServiceException {
|
|
6
|
+
constructor(options) {
|
|
7
|
+
super(options);
|
|
8
|
+
Object.setPrototypeOf(this, Route53RecoveryClusterServiceException.prototype);
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
exports.Route53RecoveryClusterServiceException = Route53RecoveryClusterServiceException;
|
|
@@ -1,6 +1,48 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UpdateRoutingControlStatesResponse = exports.UpdateRoutingControlStatesRequest = exports.UpdateRoutingControlStateEntry = exports.UpdateRoutingControlStateResponse = exports.UpdateRoutingControlStateRequest = exports.ValidationExceptionReason = exports.ValidationExceptionField = exports.GetRoutingControlStateResponse = exports.RoutingControlState = exports.GetRoutingControlStateRequest = void 0;
|
|
3
|
+
exports.UpdateRoutingControlStatesResponse = exports.UpdateRoutingControlStatesRequest = exports.UpdateRoutingControlStateEntry = exports.UpdateRoutingControlStateResponse = exports.UpdateRoutingControlStateRequest = exports.ValidationException = exports.ValidationExceptionReason = exports.ValidationExceptionField = exports.ThrottlingException = exports.ResourceNotFoundException = exports.InternalServerException = exports.GetRoutingControlStateResponse = exports.RoutingControlState = exports.GetRoutingControlStateRequest = exports.EndpointTemporarilyUnavailableException = exports.ConflictException = exports.AccessDeniedException = void 0;
|
|
4
|
+
const Route53RecoveryClusterServiceException_1 = require("./Route53RecoveryClusterServiceException");
|
|
5
|
+
class AccessDeniedException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
6
|
+
constructor(opts) {
|
|
7
|
+
super({
|
|
8
|
+
name: "AccessDeniedException",
|
|
9
|
+
$fault: "client",
|
|
10
|
+
...opts,
|
|
11
|
+
});
|
|
12
|
+
this.name = "AccessDeniedException";
|
|
13
|
+
this.$fault = "client";
|
|
14
|
+
Object.setPrototypeOf(this, AccessDeniedException.prototype);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
exports.AccessDeniedException = AccessDeniedException;
|
|
18
|
+
class ConflictException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
19
|
+
constructor(opts) {
|
|
20
|
+
super({
|
|
21
|
+
name: "ConflictException",
|
|
22
|
+
$fault: "client",
|
|
23
|
+
...opts,
|
|
24
|
+
});
|
|
25
|
+
this.name = "ConflictException";
|
|
26
|
+
this.$fault = "client";
|
|
27
|
+
Object.setPrototypeOf(this, ConflictException.prototype);
|
|
28
|
+
this.resourceId = opts.resourceId;
|
|
29
|
+
this.resourceType = opts.resourceType;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
exports.ConflictException = ConflictException;
|
|
33
|
+
class EndpointTemporarilyUnavailableException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
34
|
+
constructor(opts) {
|
|
35
|
+
super({
|
|
36
|
+
name: "EndpointTemporarilyUnavailableException",
|
|
37
|
+
$fault: "server",
|
|
38
|
+
...opts,
|
|
39
|
+
});
|
|
40
|
+
this.name = "EndpointTemporarilyUnavailableException";
|
|
41
|
+
this.$fault = "server";
|
|
42
|
+
Object.setPrototypeOf(this, EndpointTemporarilyUnavailableException.prototype);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
exports.EndpointTemporarilyUnavailableException = EndpointTemporarilyUnavailableException;
|
|
4
46
|
var GetRoutingControlStateRequest;
|
|
5
47
|
(function (GetRoutingControlStateRequest) {
|
|
6
48
|
GetRoutingControlStateRequest.filterSensitiveLog = (obj) => ({
|
|
@@ -18,6 +60,49 @@ var GetRoutingControlStateResponse;
|
|
|
18
60
|
...obj,
|
|
19
61
|
});
|
|
20
62
|
})(GetRoutingControlStateResponse = exports.GetRoutingControlStateResponse || (exports.GetRoutingControlStateResponse = {}));
|
|
63
|
+
class InternalServerException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
64
|
+
constructor(opts) {
|
|
65
|
+
super({
|
|
66
|
+
name: "InternalServerException",
|
|
67
|
+
$fault: "server",
|
|
68
|
+
...opts,
|
|
69
|
+
});
|
|
70
|
+
this.name = "InternalServerException";
|
|
71
|
+
this.$fault = "server";
|
|
72
|
+
Object.setPrototypeOf(this, InternalServerException.prototype);
|
|
73
|
+
this.retryAfterSeconds = opts.retryAfterSeconds;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
exports.InternalServerException = InternalServerException;
|
|
77
|
+
class ResourceNotFoundException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
78
|
+
constructor(opts) {
|
|
79
|
+
super({
|
|
80
|
+
name: "ResourceNotFoundException",
|
|
81
|
+
$fault: "client",
|
|
82
|
+
...opts,
|
|
83
|
+
});
|
|
84
|
+
this.name = "ResourceNotFoundException";
|
|
85
|
+
this.$fault = "client";
|
|
86
|
+
Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
|
|
87
|
+
this.resourceId = opts.resourceId;
|
|
88
|
+
this.resourceType = opts.resourceType;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
exports.ResourceNotFoundException = ResourceNotFoundException;
|
|
92
|
+
class ThrottlingException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
93
|
+
constructor(opts) {
|
|
94
|
+
super({
|
|
95
|
+
name: "ThrottlingException",
|
|
96
|
+
$fault: "client",
|
|
97
|
+
...opts,
|
|
98
|
+
});
|
|
99
|
+
this.name = "ThrottlingException";
|
|
100
|
+
this.$fault = "client";
|
|
101
|
+
Object.setPrototypeOf(this, ThrottlingException.prototype);
|
|
102
|
+
this.retryAfterSeconds = opts.retryAfterSeconds;
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
exports.ThrottlingException = ThrottlingException;
|
|
21
106
|
var ValidationExceptionField;
|
|
22
107
|
(function (ValidationExceptionField) {
|
|
23
108
|
ValidationExceptionField.filterSensitiveLog = (obj) => ({
|
|
@@ -31,6 +116,21 @@ var ValidationExceptionReason;
|
|
|
31
116
|
ValidationExceptionReason["OTHER"] = "other";
|
|
32
117
|
ValidationExceptionReason["UNKNOWN_OPERATION"] = "unknownOperation";
|
|
33
118
|
})(ValidationExceptionReason = exports.ValidationExceptionReason || (exports.ValidationExceptionReason = {}));
|
|
119
|
+
class ValidationException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
120
|
+
constructor(opts) {
|
|
121
|
+
super({
|
|
122
|
+
name: "ValidationException",
|
|
123
|
+
$fault: "client",
|
|
124
|
+
...opts,
|
|
125
|
+
});
|
|
126
|
+
this.name = "ValidationException";
|
|
127
|
+
this.$fault = "client";
|
|
128
|
+
Object.setPrototypeOf(this, ValidationException.prototype);
|
|
129
|
+
this.reason = opts.reason;
|
|
130
|
+
this.fields = opts.fields;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
exports.ValidationException = ValidationException;
|
|
34
134
|
var UpdateRoutingControlStateRequest;
|
|
35
135
|
(function (UpdateRoutingControlStateRequest) {
|
|
36
136
|
UpdateRoutingControlStateRequest.filterSensitiveLog = (obj) => ({
|
|
@@ -3,6 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.deserializeAws_json1_0UpdateRoutingControlStatesCommand = exports.deserializeAws_json1_0UpdateRoutingControlStateCommand = exports.deserializeAws_json1_0GetRoutingControlStateCommand = exports.serializeAws_json1_0UpdateRoutingControlStatesCommand = exports.serializeAws_json1_0UpdateRoutingControlStateCommand = exports.serializeAws_json1_0GetRoutingControlStateCommand = void 0;
|
|
4
4
|
const protocol_http_1 = require("@aws-sdk/protocol-http");
|
|
5
5
|
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
6
|
+
const models_0_1 = require("../models/models_0");
|
|
7
|
+
const Route53RecoveryClusterServiceException_1 = require("../models/Route53RecoveryClusterServiceException");
|
|
6
8
|
const serializeAws_json1_0GetRoutingControlStateCommand = async (input, context) => {
|
|
7
9
|
const headers = {
|
|
8
10
|
"content-type": "application/x-amz-json-1.0",
|
|
@@ -58,67 +60,31 @@ const deserializeAws_json1_0GetRoutingControlStateCommandError = async (output,
|
|
|
58
60
|
switch (errorCode) {
|
|
59
61
|
case "AccessDeniedException":
|
|
60
62
|
case "com.amazonaws.route53recoverycluster#AccessDeniedException":
|
|
61
|
-
|
|
62
|
-
...(await deserializeAws_json1_0AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
63
|
-
name: errorCode,
|
|
64
|
-
$metadata: deserializeMetadata(output),
|
|
65
|
-
};
|
|
66
|
-
break;
|
|
63
|
+
throw await deserializeAws_json1_0AccessDeniedExceptionResponse(parsedOutput, context);
|
|
67
64
|
case "EndpointTemporarilyUnavailableException":
|
|
68
65
|
case "com.amazonaws.route53recoverycluster#EndpointTemporarilyUnavailableException":
|
|
69
|
-
|
|
70
|
-
...(await deserializeAws_json1_0EndpointTemporarilyUnavailableExceptionResponse(parsedOutput, context)),
|
|
71
|
-
name: errorCode,
|
|
72
|
-
$metadata: deserializeMetadata(output),
|
|
73
|
-
};
|
|
74
|
-
break;
|
|
66
|
+
throw await deserializeAws_json1_0EndpointTemporarilyUnavailableExceptionResponse(parsedOutput, context);
|
|
75
67
|
case "InternalServerException":
|
|
76
68
|
case "com.amazonaws.route53recoverycluster#InternalServerException":
|
|
77
|
-
|
|
78
|
-
...(await deserializeAws_json1_0InternalServerExceptionResponse(parsedOutput, context)),
|
|
79
|
-
name: errorCode,
|
|
80
|
-
$metadata: deserializeMetadata(output),
|
|
81
|
-
};
|
|
82
|
-
break;
|
|
69
|
+
throw await deserializeAws_json1_0InternalServerExceptionResponse(parsedOutput, context);
|
|
83
70
|
case "ResourceNotFoundException":
|
|
84
71
|
case "com.amazonaws.route53recoverycluster#ResourceNotFoundException":
|
|
85
|
-
|
|
86
|
-
...(await deserializeAws_json1_0ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
87
|
-
name: errorCode,
|
|
88
|
-
$metadata: deserializeMetadata(output),
|
|
89
|
-
};
|
|
90
|
-
break;
|
|
72
|
+
throw await deserializeAws_json1_0ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
91
73
|
case "ThrottlingException":
|
|
92
74
|
case "com.amazonaws.route53recoverycluster#ThrottlingException":
|
|
93
|
-
|
|
94
|
-
...(await deserializeAws_json1_0ThrottlingExceptionResponse(parsedOutput, context)),
|
|
95
|
-
name: errorCode,
|
|
96
|
-
$metadata: deserializeMetadata(output),
|
|
97
|
-
};
|
|
98
|
-
break;
|
|
75
|
+
throw await deserializeAws_json1_0ThrottlingExceptionResponse(parsedOutput, context);
|
|
99
76
|
case "ValidationException":
|
|
100
77
|
case "com.amazonaws.route53recoverycluster#ValidationException":
|
|
101
|
-
|
|
102
|
-
...(await deserializeAws_json1_0ValidationExceptionResponse(parsedOutput, context)),
|
|
103
|
-
name: errorCode,
|
|
104
|
-
$metadata: deserializeMetadata(output),
|
|
105
|
-
};
|
|
106
|
-
break;
|
|
78
|
+
throw await deserializeAws_json1_0ValidationExceptionResponse(parsedOutput, context);
|
|
107
79
|
default:
|
|
108
80
|
const parsedBody = parsedOutput.body;
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
...parsedBody,
|
|
112
|
-
name: `${errorCode}`,
|
|
113
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
81
|
+
response = new Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException({
|
|
82
|
+
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
114
83
|
$fault: "client",
|
|
115
84
|
$metadata: deserializeMetadata(output),
|
|
116
|
-
};
|
|
85
|
+
});
|
|
86
|
+
throw smithy_client_1.decorateServiceException(response, parsedBody);
|
|
117
87
|
}
|
|
118
|
-
const message = response.message || response.Message || errorCode;
|
|
119
|
-
response.message = message;
|
|
120
|
-
delete response.Message;
|
|
121
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
122
88
|
};
|
|
123
89
|
const deserializeAws_json1_0UpdateRoutingControlStateCommand = async (output, context) => {
|
|
124
90
|
if (output.statusCode >= 300) {
|
|
@@ -145,75 +111,34 @@ const deserializeAws_json1_0UpdateRoutingControlStateCommandError = async (outpu
|
|
|
145
111
|
switch (errorCode) {
|
|
146
112
|
case "AccessDeniedException":
|
|
147
113
|
case "com.amazonaws.route53recoverycluster#AccessDeniedException":
|
|
148
|
-
|
|
149
|
-
...(await deserializeAws_json1_0AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
150
|
-
name: errorCode,
|
|
151
|
-
$metadata: deserializeMetadata(output),
|
|
152
|
-
};
|
|
153
|
-
break;
|
|
114
|
+
throw await deserializeAws_json1_0AccessDeniedExceptionResponse(parsedOutput, context);
|
|
154
115
|
case "ConflictException":
|
|
155
116
|
case "com.amazonaws.route53recoverycluster#ConflictException":
|
|
156
|
-
|
|
157
|
-
...(await deserializeAws_json1_0ConflictExceptionResponse(parsedOutput, context)),
|
|
158
|
-
name: errorCode,
|
|
159
|
-
$metadata: deserializeMetadata(output),
|
|
160
|
-
};
|
|
161
|
-
break;
|
|
117
|
+
throw await deserializeAws_json1_0ConflictExceptionResponse(parsedOutput, context);
|
|
162
118
|
case "EndpointTemporarilyUnavailableException":
|
|
163
119
|
case "com.amazonaws.route53recoverycluster#EndpointTemporarilyUnavailableException":
|
|
164
|
-
|
|
165
|
-
...(await deserializeAws_json1_0EndpointTemporarilyUnavailableExceptionResponse(parsedOutput, context)),
|
|
166
|
-
name: errorCode,
|
|
167
|
-
$metadata: deserializeMetadata(output),
|
|
168
|
-
};
|
|
169
|
-
break;
|
|
120
|
+
throw await deserializeAws_json1_0EndpointTemporarilyUnavailableExceptionResponse(parsedOutput, context);
|
|
170
121
|
case "InternalServerException":
|
|
171
122
|
case "com.amazonaws.route53recoverycluster#InternalServerException":
|
|
172
|
-
|
|
173
|
-
...(await deserializeAws_json1_0InternalServerExceptionResponse(parsedOutput, context)),
|
|
174
|
-
name: errorCode,
|
|
175
|
-
$metadata: deserializeMetadata(output),
|
|
176
|
-
};
|
|
177
|
-
break;
|
|
123
|
+
throw await deserializeAws_json1_0InternalServerExceptionResponse(parsedOutput, context);
|
|
178
124
|
case "ResourceNotFoundException":
|
|
179
125
|
case "com.amazonaws.route53recoverycluster#ResourceNotFoundException":
|
|
180
|
-
|
|
181
|
-
...(await deserializeAws_json1_0ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
182
|
-
name: errorCode,
|
|
183
|
-
$metadata: deserializeMetadata(output),
|
|
184
|
-
};
|
|
185
|
-
break;
|
|
126
|
+
throw await deserializeAws_json1_0ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
186
127
|
case "ThrottlingException":
|
|
187
128
|
case "com.amazonaws.route53recoverycluster#ThrottlingException":
|
|
188
|
-
|
|
189
|
-
...(await deserializeAws_json1_0ThrottlingExceptionResponse(parsedOutput, context)),
|
|
190
|
-
name: errorCode,
|
|
191
|
-
$metadata: deserializeMetadata(output),
|
|
192
|
-
};
|
|
193
|
-
break;
|
|
129
|
+
throw await deserializeAws_json1_0ThrottlingExceptionResponse(parsedOutput, context);
|
|
194
130
|
case "ValidationException":
|
|
195
131
|
case "com.amazonaws.route53recoverycluster#ValidationException":
|
|
196
|
-
|
|
197
|
-
...(await deserializeAws_json1_0ValidationExceptionResponse(parsedOutput, context)),
|
|
198
|
-
name: errorCode,
|
|
199
|
-
$metadata: deserializeMetadata(output),
|
|
200
|
-
};
|
|
201
|
-
break;
|
|
132
|
+
throw await deserializeAws_json1_0ValidationExceptionResponse(parsedOutput, context);
|
|
202
133
|
default:
|
|
203
134
|
const parsedBody = parsedOutput.body;
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
...parsedBody,
|
|
207
|
-
name: `${errorCode}`,
|
|
208
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
135
|
+
response = new Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException({
|
|
136
|
+
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
209
137
|
$fault: "client",
|
|
210
138
|
$metadata: deserializeMetadata(output),
|
|
211
|
-
};
|
|
139
|
+
});
|
|
140
|
+
throw smithy_client_1.decorateServiceException(response, parsedBody);
|
|
212
141
|
}
|
|
213
|
-
const message = response.message || response.Message || errorCode;
|
|
214
|
-
response.message = message;
|
|
215
|
-
delete response.Message;
|
|
216
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
217
142
|
};
|
|
218
143
|
const deserializeAws_json1_0UpdateRoutingControlStatesCommand = async (output, context) => {
|
|
219
144
|
if (output.statusCode >= 300) {
|
|
@@ -240,152 +165,97 @@ const deserializeAws_json1_0UpdateRoutingControlStatesCommandError = async (outp
|
|
|
240
165
|
switch (errorCode) {
|
|
241
166
|
case "AccessDeniedException":
|
|
242
167
|
case "com.amazonaws.route53recoverycluster#AccessDeniedException":
|
|
243
|
-
|
|
244
|
-
...(await deserializeAws_json1_0AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
245
|
-
name: errorCode,
|
|
246
|
-
$metadata: deserializeMetadata(output),
|
|
247
|
-
};
|
|
248
|
-
break;
|
|
168
|
+
throw await deserializeAws_json1_0AccessDeniedExceptionResponse(parsedOutput, context);
|
|
249
169
|
case "ConflictException":
|
|
250
170
|
case "com.amazonaws.route53recoverycluster#ConflictException":
|
|
251
|
-
|
|
252
|
-
...(await deserializeAws_json1_0ConflictExceptionResponse(parsedOutput, context)),
|
|
253
|
-
name: errorCode,
|
|
254
|
-
$metadata: deserializeMetadata(output),
|
|
255
|
-
};
|
|
256
|
-
break;
|
|
171
|
+
throw await deserializeAws_json1_0ConflictExceptionResponse(parsedOutput, context);
|
|
257
172
|
case "EndpointTemporarilyUnavailableException":
|
|
258
173
|
case "com.amazonaws.route53recoverycluster#EndpointTemporarilyUnavailableException":
|
|
259
|
-
|
|
260
|
-
...(await deserializeAws_json1_0EndpointTemporarilyUnavailableExceptionResponse(parsedOutput, context)),
|
|
261
|
-
name: errorCode,
|
|
262
|
-
$metadata: deserializeMetadata(output),
|
|
263
|
-
};
|
|
264
|
-
break;
|
|
174
|
+
throw await deserializeAws_json1_0EndpointTemporarilyUnavailableExceptionResponse(parsedOutput, context);
|
|
265
175
|
case "InternalServerException":
|
|
266
176
|
case "com.amazonaws.route53recoverycluster#InternalServerException":
|
|
267
|
-
|
|
268
|
-
...(await deserializeAws_json1_0InternalServerExceptionResponse(parsedOutput, context)),
|
|
269
|
-
name: errorCode,
|
|
270
|
-
$metadata: deserializeMetadata(output),
|
|
271
|
-
};
|
|
272
|
-
break;
|
|
177
|
+
throw await deserializeAws_json1_0InternalServerExceptionResponse(parsedOutput, context);
|
|
273
178
|
case "ResourceNotFoundException":
|
|
274
179
|
case "com.amazonaws.route53recoverycluster#ResourceNotFoundException":
|
|
275
|
-
|
|
276
|
-
...(await deserializeAws_json1_0ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
277
|
-
name: errorCode,
|
|
278
|
-
$metadata: deserializeMetadata(output),
|
|
279
|
-
};
|
|
280
|
-
break;
|
|
180
|
+
throw await deserializeAws_json1_0ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
281
181
|
case "ThrottlingException":
|
|
282
182
|
case "com.amazonaws.route53recoverycluster#ThrottlingException":
|
|
283
|
-
|
|
284
|
-
...(await deserializeAws_json1_0ThrottlingExceptionResponse(parsedOutput, context)),
|
|
285
|
-
name: errorCode,
|
|
286
|
-
$metadata: deserializeMetadata(output),
|
|
287
|
-
};
|
|
288
|
-
break;
|
|
183
|
+
throw await deserializeAws_json1_0ThrottlingExceptionResponse(parsedOutput, context);
|
|
289
184
|
case "ValidationException":
|
|
290
185
|
case "com.amazonaws.route53recoverycluster#ValidationException":
|
|
291
|
-
|
|
292
|
-
...(await deserializeAws_json1_0ValidationExceptionResponse(parsedOutput, context)),
|
|
293
|
-
name: errorCode,
|
|
294
|
-
$metadata: deserializeMetadata(output),
|
|
295
|
-
};
|
|
296
|
-
break;
|
|
186
|
+
throw await deserializeAws_json1_0ValidationExceptionResponse(parsedOutput, context);
|
|
297
187
|
default:
|
|
298
188
|
const parsedBody = parsedOutput.body;
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
...parsedBody,
|
|
302
|
-
name: `${errorCode}`,
|
|
303
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
189
|
+
response = new Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException({
|
|
190
|
+
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
304
191
|
$fault: "client",
|
|
305
192
|
$metadata: deserializeMetadata(output),
|
|
306
|
-
};
|
|
193
|
+
});
|
|
194
|
+
throw smithy_client_1.decorateServiceException(response, parsedBody);
|
|
307
195
|
}
|
|
308
|
-
const message = response.message || response.Message || errorCode;
|
|
309
|
-
response.message = message;
|
|
310
|
-
delete response.Message;
|
|
311
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
312
196
|
};
|
|
313
197
|
const deserializeAws_json1_0AccessDeniedExceptionResponse = async (parsedOutput, context) => {
|
|
314
198
|
const body = parsedOutput.body;
|
|
315
199
|
const deserialized = deserializeAws_json1_0AccessDeniedException(body, context);
|
|
316
|
-
const
|
|
317
|
-
name: "AccessDeniedException",
|
|
318
|
-
$fault: "client",
|
|
200
|
+
const exception = new models_0_1.AccessDeniedException({
|
|
319
201
|
$metadata: deserializeMetadata(parsedOutput),
|
|
320
202
|
...deserialized,
|
|
321
|
-
};
|
|
322
|
-
return
|
|
203
|
+
});
|
|
204
|
+
return smithy_client_1.decorateServiceException(exception, body);
|
|
323
205
|
};
|
|
324
206
|
const deserializeAws_json1_0ConflictExceptionResponse = async (parsedOutput, context) => {
|
|
325
207
|
const body = parsedOutput.body;
|
|
326
208
|
const deserialized = deserializeAws_json1_0ConflictException(body, context);
|
|
327
|
-
const
|
|
328
|
-
name: "ConflictException",
|
|
329
|
-
$fault: "client",
|
|
209
|
+
const exception = new models_0_1.ConflictException({
|
|
330
210
|
$metadata: deserializeMetadata(parsedOutput),
|
|
331
211
|
...deserialized,
|
|
332
|
-
};
|
|
333
|
-
return
|
|
212
|
+
});
|
|
213
|
+
return smithy_client_1.decorateServiceException(exception, body);
|
|
334
214
|
};
|
|
335
215
|
const deserializeAws_json1_0EndpointTemporarilyUnavailableExceptionResponse = async (parsedOutput, context) => {
|
|
336
216
|
const body = parsedOutput.body;
|
|
337
217
|
const deserialized = deserializeAws_json1_0EndpointTemporarilyUnavailableException(body, context);
|
|
338
|
-
const
|
|
339
|
-
name: "EndpointTemporarilyUnavailableException",
|
|
340
|
-
$fault: "server",
|
|
218
|
+
const exception = new models_0_1.EndpointTemporarilyUnavailableException({
|
|
341
219
|
$metadata: deserializeMetadata(parsedOutput),
|
|
342
220
|
...deserialized,
|
|
343
|
-
};
|
|
344
|
-
return
|
|
221
|
+
});
|
|
222
|
+
return smithy_client_1.decorateServiceException(exception, body);
|
|
345
223
|
};
|
|
346
224
|
const deserializeAws_json1_0InternalServerExceptionResponse = async (parsedOutput, context) => {
|
|
347
225
|
const body = parsedOutput.body;
|
|
348
226
|
const deserialized = deserializeAws_json1_0InternalServerException(body, context);
|
|
349
|
-
const
|
|
350
|
-
name: "InternalServerException",
|
|
351
|
-
$fault: "server",
|
|
227
|
+
const exception = new models_0_1.InternalServerException({
|
|
352
228
|
$metadata: deserializeMetadata(parsedOutput),
|
|
353
229
|
...deserialized,
|
|
354
|
-
};
|
|
355
|
-
return
|
|
230
|
+
});
|
|
231
|
+
return smithy_client_1.decorateServiceException(exception, body);
|
|
356
232
|
};
|
|
357
233
|
const deserializeAws_json1_0ResourceNotFoundExceptionResponse = async (parsedOutput, context) => {
|
|
358
234
|
const body = parsedOutput.body;
|
|
359
235
|
const deserialized = deserializeAws_json1_0ResourceNotFoundException(body, context);
|
|
360
|
-
const
|
|
361
|
-
name: "ResourceNotFoundException",
|
|
362
|
-
$fault: "client",
|
|
236
|
+
const exception = new models_0_1.ResourceNotFoundException({
|
|
363
237
|
$metadata: deserializeMetadata(parsedOutput),
|
|
364
238
|
...deserialized,
|
|
365
|
-
};
|
|
366
|
-
return
|
|
239
|
+
});
|
|
240
|
+
return smithy_client_1.decorateServiceException(exception, body);
|
|
367
241
|
};
|
|
368
242
|
const deserializeAws_json1_0ThrottlingExceptionResponse = async (parsedOutput, context) => {
|
|
369
243
|
const body = parsedOutput.body;
|
|
370
244
|
const deserialized = deserializeAws_json1_0ThrottlingException(body, context);
|
|
371
|
-
const
|
|
372
|
-
name: "ThrottlingException",
|
|
373
|
-
$fault: "client",
|
|
245
|
+
const exception = new models_0_1.ThrottlingException({
|
|
374
246
|
$metadata: deserializeMetadata(parsedOutput),
|
|
375
247
|
...deserialized,
|
|
376
|
-
};
|
|
377
|
-
return
|
|
248
|
+
});
|
|
249
|
+
return smithy_client_1.decorateServiceException(exception, body);
|
|
378
250
|
};
|
|
379
251
|
const deserializeAws_json1_0ValidationExceptionResponse = async (parsedOutput, context) => {
|
|
380
252
|
const body = parsedOutput.body;
|
|
381
253
|
const deserialized = deserializeAws_json1_0ValidationException(body, context);
|
|
382
|
-
const
|
|
383
|
-
name: "ValidationException",
|
|
384
|
-
$fault: "client",
|
|
254
|
+
const exception = new models_0_1.ValidationException({
|
|
385
255
|
$metadata: deserializeMetadata(parsedOutput),
|
|
386
256
|
...deserialized,
|
|
387
|
-
};
|
|
388
|
-
return
|
|
257
|
+
});
|
|
258
|
+
return smithy_client_1.decorateServiceException(exception, body);
|
|
389
259
|
};
|
|
390
260
|
const serializeAws_json1_0GetRoutingControlStateRequest = (input, context) => {
|
|
391
261
|
return {
|
|
@@ -491,7 +361,7 @@ const deserializeAws_json1_0ValidationExceptionField = (output, context) => {
|
|
|
491
361
|
};
|
|
492
362
|
};
|
|
493
363
|
const deserializeAws_json1_0ValidationExceptionFieldList = (output, context) => {
|
|
494
|
-
|
|
364
|
+
const retVal = (output || [])
|
|
495
365
|
.filter((e) => e != null)
|
|
496
366
|
.map((entry) => {
|
|
497
367
|
if (entry === null) {
|
|
@@ -499,6 +369,7 @@ const deserializeAws_json1_0ValidationExceptionFieldList = (output, context) =>
|
|
|
499
369
|
}
|
|
500
370
|
return deserializeAws_json1_0ValidationExceptionField(entry, context);
|
|
501
371
|
});
|
|
372
|
+
return retVal;
|
|
502
373
|
};
|
|
503
374
|
const deserializeMetadata = (output) => {
|
|
504
375
|
var _a;
|
package/dist-es/index.js
CHANGED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { __extends } from "tslib";
|
|
2
|
+
import { ServiceException as __ServiceException, } from "@aws-sdk/smithy-client";
|
|
3
|
+
var Route53RecoveryClusterServiceException = (function (_super) {
|
|
4
|
+
__extends(Route53RecoveryClusterServiceException, _super);
|
|
5
|
+
function Route53RecoveryClusterServiceException(options) {
|
|
6
|
+
var _this = _super.call(this, options) || this;
|
|
7
|
+
Object.setPrototypeOf(_this, Route53RecoveryClusterServiceException.prototype);
|
|
8
|
+
return _this;
|
|
9
|
+
}
|
|
10
|
+
return Route53RecoveryClusterServiceException;
|
|
11
|
+
}(__ServiceException));
|
|
12
|
+
export { Route53RecoveryClusterServiceException };
|