@aws-sdk/client-route53-recovery-cluster 3.489.0 → 3.495.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/dist-cjs/Route53RecoveryCluster.js +1 -19
- package/dist-cjs/Route53RecoveryClusterClient.js +1 -43
- package/dist-cjs/commands/GetRoutingControlStateCommand.js +1 -28
- package/dist-cjs/commands/ListRoutingControlsCommand.js +1 -28
- package/dist-cjs/commands/UpdateRoutingControlStateCommand.js +1 -28
- package/dist-cjs/commands/UpdateRoutingControlStatesCommand.js +1 -28
- package/dist-cjs/commands/index.js +1 -7
- package/dist-cjs/endpoint/EndpointParameters.js +1 -18
- package/dist-cjs/extensionConfiguration.js +1 -2
- package/dist-cjs/index.js +789 -11
- package/dist-cjs/models/Route53RecoveryClusterServiceException.js +1 -12
- package/dist-cjs/models/index.js +1 -4
- package/dist-cjs/models/models_0.js +1 -130
- package/dist-cjs/pagination/Interfaces.js +1 -2
- package/dist-cjs/pagination/ListRoutingControlsPaginator.js +1 -7
- package/dist-cjs/pagination/index.js +1 -5
- package/dist-cjs/protocols/Aws_json1_0.js +1 -380
- package/dist-cjs/runtimeExtensions.js +1 -22
- package/package.json +40 -40
|
@@ -1,12 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Route53RecoveryClusterServiceException = exports.__ServiceException = void 0;
|
|
4
|
-
const smithy_client_1 = require("@smithy/smithy-client");
|
|
5
|
-
Object.defineProperty(exports, "__ServiceException", { enumerable: true, get: function () { return smithy_client_1.ServiceException; } });
|
|
6
|
-
class Route53RecoveryClusterServiceException extends smithy_client_1.ServiceException {
|
|
7
|
-
constructor(options) {
|
|
8
|
-
super(options);
|
|
9
|
-
Object.setPrototypeOf(this, Route53RecoveryClusterServiceException.prototype);
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
exports.Route53RecoveryClusterServiceException = Route53RecoveryClusterServiceException;
|
|
1
|
+
module.exports = require("../index.js");
|
package/dist-cjs/models/index.js
CHANGED
|
@@ -1,130 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ServiceLimitExceededException = exports.ValidationException = exports.ValidationExceptionReason = exports.ThrottlingException = exports.ResourceNotFoundException = exports.InternalServerException = exports.RoutingControlState = 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;
|
|
46
|
-
exports.RoutingControlState = {
|
|
47
|
-
Off: "Off",
|
|
48
|
-
On: "On",
|
|
49
|
-
};
|
|
50
|
-
class InternalServerException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
51
|
-
constructor(opts) {
|
|
52
|
-
super({
|
|
53
|
-
name: "InternalServerException",
|
|
54
|
-
$fault: "server",
|
|
55
|
-
...opts,
|
|
56
|
-
});
|
|
57
|
-
this.name = "InternalServerException";
|
|
58
|
-
this.$fault = "server";
|
|
59
|
-
Object.setPrototypeOf(this, InternalServerException.prototype);
|
|
60
|
-
this.retryAfterSeconds = opts.retryAfterSeconds;
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
exports.InternalServerException = InternalServerException;
|
|
64
|
-
class ResourceNotFoundException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
65
|
-
constructor(opts) {
|
|
66
|
-
super({
|
|
67
|
-
name: "ResourceNotFoundException",
|
|
68
|
-
$fault: "client",
|
|
69
|
-
...opts,
|
|
70
|
-
});
|
|
71
|
-
this.name = "ResourceNotFoundException";
|
|
72
|
-
this.$fault = "client";
|
|
73
|
-
Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
|
|
74
|
-
this.resourceId = opts.resourceId;
|
|
75
|
-
this.resourceType = opts.resourceType;
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
exports.ResourceNotFoundException = ResourceNotFoundException;
|
|
79
|
-
class ThrottlingException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
80
|
-
constructor(opts) {
|
|
81
|
-
super({
|
|
82
|
-
name: "ThrottlingException",
|
|
83
|
-
$fault: "client",
|
|
84
|
-
...opts,
|
|
85
|
-
});
|
|
86
|
-
this.name = "ThrottlingException";
|
|
87
|
-
this.$fault = "client";
|
|
88
|
-
Object.setPrototypeOf(this, ThrottlingException.prototype);
|
|
89
|
-
this.retryAfterSeconds = opts.retryAfterSeconds;
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
exports.ThrottlingException = ThrottlingException;
|
|
93
|
-
exports.ValidationExceptionReason = {
|
|
94
|
-
CANNOT_PARSE: "cannotParse",
|
|
95
|
-
FIELD_VALIDATION_FAILED: "fieldValidationFailed",
|
|
96
|
-
OTHER: "other",
|
|
97
|
-
UNKNOWN_OPERATION: "unknownOperation",
|
|
98
|
-
};
|
|
99
|
-
class ValidationException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
100
|
-
constructor(opts) {
|
|
101
|
-
super({
|
|
102
|
-
name: "ValidationException",
|
|
103
|
-
$fault: "client",
|
|
104
|
-
...opts,
|
|
105
|
-
});
|
|
106
|
-
this.name = "ValidationException";
|
|
107
|
-
this.$fault = "client";
|
|
108
|
-
Object.setPrototypeOf(this, ValidationException.prototype);
|
|
109
|
-
this.reason = opts.reason;
|
|
110
|
-
this.fields = opts.fields;
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
exports.ValidationException = ValidationException;
|
|
114
|
-
class ServiceLimitExceededException extends Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException {
|
|
115
|
-
constructor(opts) {
|
|
116
|
-
super({
|
|
117
|
-
name: "ServiceLimitExceededException",
|
|
118
|
-
$fault: "client",
|
|
119
|
-
...opts,
|
|
120
|
-
});
|
|
121
|
-
this.name = "ServiceLimitExceededException";
|
|
122
|
-
this.$fault = "client";
|
|
123
|
-
Object.setPrototypeOf(this, ServiceLimitExceededException.prototype);
|
|
124
|
-
this.resourceId = opts.resourceId;
|
|
125
|
-
this.resourceType = opts.resourceType;
|
|
126
|
-
this.limitCode = opts.limitCode;
|
|
127
|
-
this.serviceCode = opts.serviceCode;
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
exports.ServiceLimitExceededException = ServiceLimitExceededException;
|
|
1
|
+
module.exports = require("../index.js");
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
module.exports = require("../index.js");
|
|
@@ -1,7 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.paginateListRoutingControls = void 0;
|
|
4
|
-
const core_1 = require("@smithy/core");
|
|
5
|
-
const ListRoutingControlsCommand_1 = require("../commands/ListRoutingControlsCommand");
|
|
6
|
-
const Route53RecoveryClusterClient_1 = require("../Route53RecoveryClusterClient");
|
|
7
|
-
exports.paginateListRoutingControls = (0, core_1.createPaginator)(Route53RecoveryClusterClient_1.Route53RecoveryClusterClient, ListRoutingControlsCommand_1.ListRoutingControlsCommand, "NextToken", "NextToken", "MaxResults");
|
|
1
|
+
module.exports = require("../index.js");
|
|
@@ -1,5 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const tslib_1 = require("tslib");
|
|
4
|
-
tslib_1.__exportStar(require("./Interfaces"), exports);
|
|
5
|
-
tslib_1.__exportStar(require("./ListRoutingControlsPaginator"), exports);
|
|
1
|
+
module.exports = require("../index.js");
|
|
@@ -1,380 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.de_UpdateRoutingControlStatesCommand = exports.de_UpdateRoutingControlStateCommand = exports.de_ListRoutingControlsCommand = exports.de_GetRoutingControlStateCommand = exports.se_UpdateRoutingControlStatesCommand = exports.se_UpdateRoutingControlStateCommand = exports.se_ListRoutingControlsCommand = exports.se_GetRoutingControlStateCommand = void 0;
|
|
4
|
-
const protocol_http_1 = require("@smithy/protocol-http");
|
|
5
|
-
const smithy_client_1 = require("@smithy/smithy-client");
|
|
6
|
-
const models_0_1 = require("../models/models_0");
|
|
7
|
-
const Route53RecoveryClusterServiceException_1 = require("../models/Route53RecoveryClusterServiceException");
|
|
8
|
-
const se_GetRoutingControlStateCommand = async (input, context) => {
|
|
9
|
-
const headers = sharedHeaders("GetRoutingControlState");
|
|
10
|
-
let body;
|
|
11
|
-
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
12
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
13
|
-
};
|
|
14
|
-
exports.se_GetRoutingControlStateCommand = se_GetRoutingControlStateCommand;
|
|
15
|
-
const se_ListRoutingControlsCommand = async (input, context) => {
|
|
16
|
-
const headers = sharedHeaders("ListRoutingControls");
|
|
17
|
-
let body;
|
|
18
|
-
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
19
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
20
|
-
};
|
|
21
|
-
exports.se_ListRoutingControlsCommand = se_ListRoutingControlsCommand;
|
|
22
|
-
const se_UpdateRoutingControlStateCommand = async (input, context) => {
|
|
23
|
-
const headers = sharedHeaders("UpdateRoutingControlState");
|
|
24
|
-
let body;
|
|
25
|
-
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
26
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
27
|
-
};
|
|
28
|
-
exports.se_UpdateRoutingControlStateCommand = se_UpdateRoutingControlStateCommand;
|
|
29
|
-
const se_UpdateRoutingControlStatesCommand = async (input, context) => {
|
|
30
|
-
const headers = sharedHeaders("UpdateRoutingControlStates");
|
|
31
|
-
let body;
|
|
32
|
-
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
33
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
34
|
-
};
|
|
35
|
-
exports.se_UpdateRoutingControlStatesCommand = se_UpdateRoutingControlStatesCommand;
|
|
36
|
-
const de_GetRoutingControlStateCommand = async (output, context) => {
|
|
37
|
-
if (output.statusCode >= 300) {
|
|
38
|
-
return de_GetRoutingControlStateCommandError(output, context);
|
|
39
|
-
}
|
|
40
|
-
const data = await parseBody(output.body, context);
|
|
41
|
-
let contents = {};
|
|
42
|
-
contents = (0, smithy_client_1._json)(data);
|
|
43
|
-
const response = {
|
|
44
|
-
$metadata: deserializeMetadata(output),
|
|
45
|
-
...contents,
|
|
46
|
-
};
|
|
47
|
-
return response;
|
|
48
|
-
};
|
|
49
|
-
exports.de_GetRoutingControlStateCommand = de_GetRoutingControlStateCommand;
|
|
50
|
-
const de_GetRoutingControlStateCommandError = async (output, context) => {
|
|
51
|
-
const parsedOutput = {
|
|
52
|
-
...output,
|
|
53
|
-
body: await parseErrorBody(output.body, context),
|
|
54
|
-
};
|
|
55
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
56
|
-
switch (errorCode) {
|
|
57
|
-
case "AccessDeniedException":
|
|
58
|
-
case "com.amazonaws.route53recoverycluster#AccessDeniedException":
|
|
59
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
60
|
-
case "EndpointTemporarilyUnavailableException":
|
|
61
|
-
case "com.amazonaws.route53recoverycluster#EndpointTemporarilyUnavailableException":
|
|
62
|
-
throw await de_EndpointTemporarilyUnavailableExceptionRes(parsedOutput, context);
|
|
63
|
-
case "InternalServerException":
|
|
64
|
-
case "com.amazonaws.route53recoverycluster#InternalServerException":
|
|
65
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
66
|
-
case "ResourceNotFoundException":
|
|
67
|
-
case "com.amazonaws.route53recoverycluster#ResourceNotFoundException":
|
|
68
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
69
|
-
case "ThrottlingException":
|
|
70
|
-
case "com.amazonaws.route53recoverycluster#ThrottlingException":
|
|
71
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
72
|
-
case "ValidationException":
|
|
73
|
-
case "com.amazonaws.route53recoverycluster#ValidationException":
|
|
74
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
75
|
-
default:
|
|
76
|
-
const parsedBody = parsedOutput.body;
|
|
77
|
-
return throwDefaultError({
|
|
78
|
-
output,
|
|
79
|
-
parsedBody,
|
|
80
|
-
errorCode,
|
|
81
|
-
});
|
|
82
|
-
}
|
|
83
|
-
};
|
|
84
|
-
const de_ListRoutingControlsCommand = async (output, context) => {
|
|
85
|
-
if (output.statusCode >= 300) {
|
|
86
|
-
return de_ListRoutingControlsCommandError(output, context);
|
|
87
|
-
}
|
|
88
|
-
const data = await parseBody(output.body, context);
|
|
89
|
-
let contents = {};
|
|
90
|
-
contents = (0, smithy_client_1._json)(data);
|
|
91
|
-
const response = {
|
|
92
|
-
$metadata: deserializeMetadata(output),
|
|
93
|
-
...contents,
|
|
94
|
-
};
|
|
95
|
-
return response;
|
|
96
|
-
};
|
|
97
|
-
exports.de_ListRoutingControlsCommand = de_ListRoutingControlsCommand;
|
|
98
|
-
const de_ListRoutingControlsCommandError = async (output, context) => {
|
|
99
|
-
const parsedOutput = {
|
|
100
|
-
...output,
|
|
101
|
-
body: await parseErrorBody(output.body, context),
|
|
102
|
-
};
|
|
103
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
104
|
-
switch (errorCode) {
|
|
105
|
-
case "AccessDeniedException":
|
|
106
|
-
case "com.amazonaws.route53recoverycluster#AccessDeniedException":
|
|
107
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
108
|
-
case "EndpointTemporarilyUnavailableException":
|
|
109
|
-
case "com.amazonaws.route53recoverycluster#EndpointTemporarilyUnavailableException":
|
|
110
|
-
throw await de_EndpointTemporarilyUnavailableExceptionRes(parsedOutput, context);
|
|
111
|
-
case "InternalServerException":
|
|
112
|
-
case "com.amazonaws.route53recoverycluster#InternalServerException":
|
|
113
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
114
|
-
case "ResourceNotFoundException":
|
|
115
|
-
case "com.amazonaws.route53recoverycluster#ResourceNotFoundException":
|
|
116
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
117
|
-
case "ThrottlingException":
|
|
118
|
-
case "com.amazonaws.route53recoverycluster#ThrottlingException":
|
|
119
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
120
|
-
case "ValidationException":
|
|
121
|
-
case "com.amazonaws.route53recoverycluster#ValidationException":
|
|
122
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
123
|
-
default:
|
|
124
|
-
const parsedBody = parsedOutput.body;
|
|
125
|
-
return throwDefaultError({
|
|
126
|
-
output,
|
|
127
|
-
parsedBody,
|
|
128
|
-
errorCode,
|
|
129
|
-
});
|
|
130
|
-
}
|
|
131
|
-
};
|
|
132
|
-
const de_UpdateRoutingControlStateCommand = async (output, context) => {
|
|
133
|
-
if (output.statusCode >= 300) {
|
|
134
|
-
return de_UpdateRoutingControlStateCommandError(output, context);
|
|
135
|
-
}
|
|
136
|
-
const data = await parseBody(output.body, context);
|
|
137
|
-
let contents = {};
|
|
138
|
-
contents = (0, smithy_client_1._json)(data);
|
|
139
|
-
const response = {
|
|
140
|
-
$metadata: deserializeMetadata(output),
|
|
141
|
-
...contents,
|
|
142
|
-
};
|
|
143
|
-
return response;
|
|
144
|
-
};
|
|
145
|
-
exports.de_UpdateRoutingControlStateCommand = de_UpdateRoutingControlStateCommand;
|
|
146
|
-
const de_UpdateRoutingControlStateCommandError = async (output, context) => {
|
|
147
|
-
const parsedOutput = {
|
|
148
|
-
...output,
|
|
149
|
-
body: await parseErrorBody(output.body, context),
|
|
150
|
-
};
|
|
151
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
152
|
-
switch (errorCode) {
|
|
153
|
-
case "AccessDeniedException":
|
|
154
|
-
case "com.amazonaws.route53recoverycluster#AccessDeniedException":
|
|
155
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
156
|
-
case "ConflictException":
|
|
157
|
-
case "com.amazonaws.route53recoverycluster#ConflictException":
|
|
158
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
159
|
-
case "EndpointTemporarilyUnavailableException":
|
|
160
|
-
case "com.amazonaws.route53recoverycluster#EndpointTemporarilyUnavailableException":
|
|
161
|
-
throw await de_EndpointTemporarilyUnavailableExceptionRes(parsedOutput, context);
|
|
162
|
-
case "InternalServerException":
|
|
163
|
-
case "com.amazonaws.route53recoverycluster#InternalServerException":
|
|
164
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
165
|
-
case "ResourceNotFoundException":
|
|
166
|
-
case "com.amazonaws.route53recoverycluster#ResourceNotFoundException":
|
|
167
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
168
|
-
case "ThrottlingException":
|
|
169
|
-
case "com.amazonaws.route53recoverycluster#ThrottlingException":
|
|
170
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
171
|
-
case "ValidationException":
|
|
172
|
-
case "com.amazonaws.route53recoverycluster#ValidationException":
|
|
173
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
174
|
-
default:
|
|
175
|
-
const parsedBody = parsedOutput.body;
|
|
176
|
-
return throwDefaultError({
|
|
177
|
-
output,
|
|
178
|
-
parsedBody,
|
|
179
|
-
errorCode,
|
|
180
|
-
});
|
|
181
|
-
}
|
|
182
|
-
};
|
|
183
|
-
const de_UpdateRoutingControlStatesCommand = async (output, context) => {
|
|
184
|
-
if (output.statusCode >= 300) {
|
|
185
|
-
return de_UpdateRoutingControlStatesCommandError(output, context);
|
|
186
|
-
}
|
|
187
|
-
const data = await parseBody(output.body, context);
|
|
188
|
-
let contents = {};
|
|
189
|
-
contents = (0, smithy_client_1._json)(data);
|
|
190
|
-
const response = {
|
|
191
|
-
$metadata: deserializeMetadata(output),
|
|
192
|
-
...contents,
|
|
193
|
-
};
|
|
194
|
-
return response;
|
|
195
|
-
};
|
|
196
|
-
exports.de_UpdateRoutingControlStatesCommand = de_UpdateRoutingControlStatesCommand;
|
|
197
|
-
const de_UpdateRoutingControlStatesCommandError = async (output, context) => {
|
|
198
|
-
const parsedOutput = {
|
|
199
|
-
...output,
|
|
200
|
-
body: await parseErrorBody(output.body, context),
|
|
201
|
-
};
|
|
202
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
203
|
-
switch (errorCode) {
|
|
204
|
-
case "AccessDeniedException":
|
|
205
|
-
case "com.amazonaws.route53recoverycluster#AccessDeniedException":
|
|
206
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
207
|
-
case "ConflictException":
|
|
208
|
-
case "com.amazonaws.route53recoverycluster#ConflictException":
|
|
209
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
210
|
-
case "EndpointTemporarilyUnavailableException":
|
|
211
|
-
case "com.amazonaws.route53recoverycluster#EndpointTemporarilyUnavailableException":
|
|
212
|
-
throw await de_EndpointTemporarilyUnavailableExceptionRes(parsedOutput, context);
|
|
213
|
-
case "InternalServerException":
|
|
214
|
-
case "com.amazonaws.route53recoverycluster#InternalServerException":
|
|
215
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
216
|
-
case "ResourceNotFoundException":
|
|
217
|
-
case "com.amazonaws.route53recoverycluster#ResourceNotFoundException":
|
|
218
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
219
|
-
case "ServiceLimitExceededException":
|
|
220
|
-
case "com.amazonaws.route53recoverycluster#ServiceLimitExceededException":
|
|
221
|
-
throw await de_ServiceLimitExceededExceptionRes(parsedOutput, context);
|
|
222
|
-
case "ThrottlingException":
|
|
223
|
-
case "com.amazonaws.route53recoverycluster#ThrottlingException":
|
|
224
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
225
|
-
case "ValidationException":
|
|
226
|
-
case "com.amazonaws.route53recoverycluster#ValidationException":
|
|
227
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
228
|
-
default:
|
|
229
|
-
const parsedBody = parsedOutput.body;
|
|
230
|
-
return throwDefaultError({
|
|
231
|
-
output,
|
|
232
|
-
parsedBody,
|
|
233
|
-
errorCode,
|
|
234
|
-
});
|
|
235
|
-
}
|
|
236
|
-
};
|
|
237
|
-
const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
|
|
238
|
-
const body = parsedOutput.body;
|
|
239
|
-
const deserialized = (0, smithy_client_1._json)(body);
|
|
240
|
-
const exception = new models_0_1.AccessDeniedException({
|
|
241
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
242
|
-
...deserialized,
|
|
243
|
-
});
|
|
244
|
-
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
245
|
-
};
|
|
246
|
-
const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
247
|
-
const body = parsedOutput.body;
|
|
248
|
-
const deserialized = (0, smithy_client_1._json)(body);
|
|
249
|
-
const exception = new models_0_1.ConflictException({
|
|
250
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
251
|
-
...deserialized,
|
|
252
|
-
});
|
|
253
|
-
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
254
|
-
};
|
|
255
|
-
const de_EndpointTemporarilyUnavailableExceptionRes = async (parsedOutput, context) => {
|
|
256
|
-
const body = parsedOutput.body;
|
|
257
|
-
const deserialized = (0, smithy_client_1._json)(body);
|
|
258
|
-
const exception = new models_0_1.EndpointTemporarilyUnavailableException({
|
|
259
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
260
|
-
...deserialized,
|
|
261
|
-
});
|
|
262
|
-
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
263
|
-
};
|
|
264
|
-
const de_InternalServerExceptionRes = async (parsedOutput, context) => {
|
|
265
|
-
const body = parsedOutput.body;
|
|
266
|
-
const deserialized = (0, smithy_client_1._json)(body);
|
|
267
|
-
const exception = new models_0_1.InternalServerException({
|
|
268
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
269
|
-
...deserialized,
|
|
270
|
-
});
|
|
271
|
-
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
272
|
-
};
|
|
273
|
-
const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
274
|
-
const body = parsedOutput.body;
|
|
275
|
-
const deserialized = (0, smithy_client_1._json)(body);
|
|
276
|
-
const exception = new models_0_1.ResourceNotFoundException({
|
|
277
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
278
|
-
...deserialized,
|
|
279
|
-
});
|
|
280
|
-
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
281
|
-
};
|
|
282
|
-
const de_ServiceLimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
283
|
-
const body = parsedOutput.body;
|
|
284
|
-
const deserialized = (0, smithy_client_1._json)(body);
|
|
285
|
-
const exception = new models_0_1.ServiceLimitExceededException({
|
|
286
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
287
|
-
...deserialized,
|
|
288
|
-
});
|
|
289
|
-
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
290
|
-
};
|
|
291
|
-
const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
|
|
292
|
-
const body = parsedOutput.body;
|
|
293
|
-
const deserialized = (0, smithy_client_1._json)(body);
|
|
294
|
-
const exception = new models_0_1.ThrottlingException({
|
|
295
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
296
|
-
...deserialized,
|
|
297
|
-
});
|
|
298
|
-
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
299
|
-
};
|
|
300
|
-
const de_ValidationExceptionRes = async (parsedOutput, context) => {
|
|
301
|
-
const body = parsedOutput.body;
|
|
302
|
-
const deserialized = (0, smithy_client_1._json)(body);
|
|
303
|
-
const exception = new models_0_1.ValidationException({
|
|
304
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
305
|
-
...deserialized,
|
|
306
|
-
});
|
|
307
|
-
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
308
|
-
};
|
|
309
|
-
const deserializeMetadata = (output) => ({
|
|
310
|
-
httpStatusCode: output.statusCode,
|
|
311
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
312
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
313
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
314
|
-
});
|
|
315
|
-
const collectBodyString = (streamBody, context) => (0, smithy_client_1.collectBody)(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
316
|
-
const throwDefaultError = (0, smithy_client_1.withBaseException)(Route53RecoveryClusterServiceException_1.Route53RecoveryClusterServiceException);
|
|
317
|
-
const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
|
|
318
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
319
|
-
const contents = {
|
|
320
|
-
protocol,
|
|
321
|
-
hostname,
|
|
322
|
-
port,
|
|
323
|
-
method: "POST",
|
|
324
|
-
path: basePath.endsWith("/") ? basePath.slice(0, -1) + path : basePath + path,
|
|
325
|
-
headers,
|
|
326
|
-
};
|
|
327
|
-
if (resolvedHostname !== undefined) {
|
|
328
|
-
contents.hostname = resolvedHostname;
|
|
329
|
-
}
|
|
330
|
-
if (body !== undefined) {
|
|
331
|
-
contents.body = body;
|
|
332
|
-
}
|
|
333
|
-
return new protocol_http_1.HttpRequest(contents);
|
|
334
|
-
};
|
|
335
|
-
function sharedHeaders(operation) {
|
|
336
|
-
return {
|
|
337
|
-
"content-type": "application/x-amz-json-1.0",
|
|
338
|
-
"x-amz-target": `ToggleCustomerAPI.${operation}`,
|
|
339
|
-
};
|
|
340
|
-
}
|
|
341
|
-
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
342
|
-
if (encoded.length) {
|
|
343
|
-
return JSON.parse(encoded);
|
|
344
|
-
}
|
|
345
|
-
return {};
|
|
346
|
-
});
|
|
347
|
-
const parseErrorBody = async (errorBody, context) => {
|
|
348
|
-
const value = await parseBody(errorBody, context);
|
|
349
|
-
value.message = value.message ?? value.Message;
|
|
350
|
-
return value;
|
|
351
|
-
};
|
|
352
|
-
const loadRestJsonErrorCode = (output, data) => {
|
|
353
|
-
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
354
|
-
const sanitizeErrorCode = (rawValue) => {
|
|
355
|
-
let cleanValue = rawValue;
|
|
356
|
-
if (typeof cleanValue === "number") {
|
|
357
|
-
cleanValue = cleanValue.toString();
|
|
358
|
-
}
|
|
359
|
-
if (cleanValue.indexOf(",") >= 0) {
|
|
360
|
-
cleanValue = cleanValue.split(",")[0];
|
|
361
|
-
}
|
|
362
|
-
if (cleanValue.indexOf(":") >= 0) {
|
|
363
|
-
cleanValue = cleanValue.split(":")[0];
|
|
364
|
-
}
|
|
365
|
-
if (cleanValue.indexOf("#") >= 0) {
|
|
366
|
-
cleanValue = cleanValue.split("#")[1];
|
|
367
|
-
}
|
|
368
|
-
return cleanValue;
|
|
369
|
-
};
|
|
370
|
-
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
371
|
-
if (headerKey !== undefined) {
|
|
372
|
-
return sanitizeErrorCode(output.headers[headerKey]);
|
|
373
|
-
}
|
|
374
|
-
if (data.code !== undefined) {
|
|
375
|
-
return sanitizeErrorCode(data.code);
|
|
376
|
-
}
|
|
377
|
-
if (data["__type"] !== undefined) {
|
|
378
|
-
return sanitizeErrorCode(data["__type"]);
|
|
379
|
-
}
|
|
380
|
-
};
|
|
1
|
+
module.exports = require("../index.js");
|
|
@@ -1,22 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.resolveRuntimeExtensions = void 0;
|
|
4
|
-
const region_config_resolver_1 = require("@aws-sdk/region-config-resolver");
|
|
5
|
-
const protocol_http_1 = require("@smithy/protocol-http");
|
|
6
|
-
const smithy_client_1 = require("@smithy/smithy-client");
|
|
7
|
-
const asPartial = (t) => t;
|
|
8
|
-
const resolveRuntimeExtensions = (runtimeConfig, extensions) => {
|
|
9
|
-
const extensionConfiguration = {
|
|
10
|
-
...asPartial((0, region_config_resolver_1.getAwsRegionExtensionConfiguration)(runtimeConfig)),
|
|
11
|
-
...asPartial((0, smithy_client_1.getDefaultExtensionConfiguration)(runtimeConfig)),
|
|
12
|
-
...asPartial((0, protocol_http_1.getHttpHandlerExtensionConfiguration)(runtimeConfig)),
|
|
13
|
-
};
|
|
14
|
-
extensions.forEach((extension) => extension.configure(extensionConfiguration));
|
|
15
|
-
return {
|
|
16
|
-
...runtimeConfig,
|
|
17
|
-
...(0, region_config_resolver_1.resolveAwsRegionExtensionConfiguration)(extensionConfiguration),
|
|
18
|
-
...(0, smithy_client_1.resolveDefaultRuntimeConfig)(extensionConfiguration),
|
|
19
|
-
...(0, protocol_http_1.resolveHttpHandlerRuntimeConfig)(extensionConfiguration),
|
|
20
|
-
};
|
|
21
|
-
};
|
|
22
|
-
exports.resolveRuntimeExtensions = resolveRuntimeExtensions;
|
|
1
|
+
module.exports = require("./index.js");
|