@aws-sdk/client-cloudsearch-domain 3.180.0 → 3.181.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
CHANGED
|
@@ -3,6 +3,18 @@
|
|
|
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.181.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.180.0...v3.181.0) (2022-09-29)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* **clients:** make parseErrorBody async ([#3999](https://github.com/aws/aws-sdk-js-v3/issues/3999)) ([2558c93](https://github.com/aws/aws-sdk-js-v3/commit/2558c93c050357ac6dc47aa0452b15b12ebfd676))
|
|
12
|
+
* **clients:** populate message field when parsing errors ([#3995](https://github.com/aws/aws-sdk-js-v3/issues/3995)) ([02e47f1](https://github.com/aws/aws-sdk-js-v3/commit/02e47f14397ae0a5d2e2883350d038b307fdcdb4))
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
6
18
|
# [3.180.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.179.0...v3.180.0) (2022-09-27)
|
|
7
19
|
|
|
8
20
|
**Note:** Version bump only for package @aws-sdk/client-cloudsearch-domain
|
|
@@ -115,7 +115,7 @@ exports.deserializeAws_restJson1SearchCommand = deserializeAws_restJson1SearchCo
|
|
|
115
115
|
const deserializeAws_restJson1SearchCommandError = async (output, context) => {
|
|
116
116
|
const parsedOutput = {
|
|
117
117
|
...output,
|
|
118
|
-
body: await
|
|
118
|
+
body: await parseErrorBody(output.body, context),
|
|
119
119
|
};
|
|
120
120
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
121
121
|
switch (errorCode) {
|
|
@@ -152,7 +152,7 @@ exports.deserializeAws_restJson1SuggestCommand = deserializeAws_restJson1Suggest
|
|
|
152
152
|
const deserializeAws_restJson1SuggestCommandError = async (output, context) => {
|
|
153
153
|
const parsedOutput = {
|
|
154
154
|
...output,
|
|
155
|
-
body: await
|
|
155
|
+
body: await parseErrorBody(output.body, context),
|
|
156
156
|
};
|
|
157
157
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
158
158
|
switch (errorCode) {
|
|
@@ -195,7 +195,7 @@ exports.deserializeAws_restJson1UploadDocumentsCommand = deserializeAws_restJson
|
|
|
195
195
|
const deserializeAws_restJson1UploadDocumentsCommandError = async (output, context) => {
|
|
196
196
|
const parsedOutput = {
|
|
197
197
|
...output,
|
|
198
|
-
body: await
|
|
198
|
+
body: await parseErrorBody(output.body, context),
|
|
199
199
|
};
|
|
200
200
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
201
201
|
switch (errorCode) {
|
|
@@ -447,6 +447,12 @@ const parseBody = (streamBody, context) => collectBodyString(streamBody, context
|
|
|
447
447
|
}
|
|
448
448
|
return {};
|
|
449
449
|
});
|
|
450
|
+
const parseErrorBody = async (errorBody, context) => {
|
|
451
|
+
var _a;
|
|
452
|
+
const value = await parseBody(errorBody, context);
|
|
453
|
+
value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
|
|
454
|
+
return value;
|
|
455
|
+
};
|
|
450
456
|
const loadRestJsonErrorCode = (output, data) => {
|
|
451
457
|
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
452
458
|
const sanitizeErrorCode = (rawValue) => {
|
|
@@ -142,7 +142,7 @@ var deserializeAws_restJson1SearchCommandError = function (output, context) { re
|
|
|
142
142
|
case 0:
|
|
143
143
|
_a = [__assign({}, output)];
|
|
144
144
|
_c = {};
|
|
145
|
-
return [4,
|
|
145
|
+
return [4, parseErrorBody(output.body, context)];
|
|
146
146
|
case 1:
|
|
147
147
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
148
148
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -201,7 +201,7 @@ var deserializeAws_restJson1SuggestCommandError = function (output, context) { r
|
|
|
201
201
|
case 0:
|
|
202
202
|
_a = [__assign({}, output)];
|
|
203
203
|
_c = {};
|
|
204
|
-
return [4,
|
|
204
|
+
return [4, parseErrorBody(output.body, context)];
|
|
205
205
|
case 1:
|
|
206
206
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
207
207
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -266,7 +266,7 @@ var deserializeAws_restJson1UploadDocumentsCommandError = function (output, cont
|
|
|
266
266
|
case 0:
|
|
267
267
|
_a = [__assign({}, output)];
|
|
268
268
|
_c = {};
|
|
269
|
-
return [4,
|
|
269
|
+
return [4, parseErrorBody(output.body, context)];
|
|
270
270
|
case 1:
|
|
271
271
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
272
272
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -528,6 +528,19 @@ var parseBody = function (streamBody, context) {
|
|
|
528
528
|
return {};
|
|
529
529
|
});
|
|
530
530
|
};
|
|
531
|
+
var parseErrorBody = function (errorBody, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
532
|
+
var value;
|
|
533
|
+
var _a;
|
|
534
|
+
return __generator(this, function (_b) {
|
|
535
|
+
switch (_b.label) {
|
|
536
|
+
case 0: return [4, parseBody(errorBody, context)];
|
|
537
|
+
case 1:
|
|
538
|
+
value = _b.sent();
|
|
539
|
+
value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
|
|
540
|
+
return [2, value];
|
|
541
|
+
}
|
|
542
|
+
});
|
|
543
|
+
}); };
|
|
531
544
|
var loadRestJsonErrorCode = function (output, data) {
|
|
532
545
|
var findKey = function (object, key) { return Object.keys(object).find(function (k) { return k.toLowerCase() === key.toLowerCase(); }); };
|
|
533
546
|
var sanitizeErrorCode = function (rawValue) {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-cloudsearch-domain",
|
|
3
3
|
"description": "AWS SDK for JavaScript Cloudsearch Domain Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.181.0",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "tsc -p tsconfig.cjs.json",
|
|
@@ -19,9 +19,9 @@
|
|
|
19
19
|
"dependencies": {
|
|
20
20
|
"@aws-crypto/sha256-browser": "2.0.0",
|
|
21
21
|
"@aws-crypto/sha256-js": "2.0.0",
|
|
22
|
-
"@aws-sdk/client-sts": "3.
|
|
22
|
+
"@aws-sdk/client-sts": "3.181.0",
|
|
23
23
|
"@aws-sdk/config-resolver": "3.178.0",
|
|
24
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
24
|
+
"@aws-sdk/credential-provider-node": "3.181.0",
|
|
25
25
|
"@aws-sdk/fetch-http-handler": "3.178.0",
|
|
26
26
|
"@aws-sdk/hash-node": "3.178.0",
|
|
27
27
|
"@aws-sdk/invalid-dependency": "3.178.0",
|