@mavogel/awscdk-rootmail 0.1.35 → 0.1.37
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/.jsii +8 -8
- package/lib/rootmail.js +1 -1
- package/lib/ses-receive.js +1 -1
- package/node_modules/@aws-sdk/checksums/package.json +3 -3
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-cjs/index.js +51 -14
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-es/models/enums.js +1 -0
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-es/schemas/schemas_0.js +46 -13
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/commands/DeleteAccountPolicyCommand.d.ts +22 -5
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/commands/DescribeAccountPoliciesCommand.d.ts +2 -2
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/commands/DescribeLogGroupsCommand.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/commands/PutAccountPolicyCommand.d.ts +18 -2
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/commands/TagLogGroupCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/commands/TagResourceCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/commands/TestMetricFilterCommand.d.ts +1 -2
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/models/enums.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/models/models_0.d.ts +124 -58
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/models/models_1.d.ts +58 -0
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/schemas/schemas_0.d.ts +3 -0
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/commands/DeleteAccountPolicyCommand.d.ts +4 -3
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/commands/TagLogGroupCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/commands/TagResourceCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/commands/TestMetricFilterCommand.d.ts +1 -2
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/models/enums.d.ts +1 -0
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/models/models_0.d.ts +21 -12
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/models/models_1.d.ts +12 -0
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/schemas/schemas_0.d.ts +3 -0
- package/node_modules/@aws-sdk/client-cloudwatch-logs/package.json +5 -5
- package/node_modules/@aws-sdk/client-route-53/dist-cjs/index.js +1 -1
- package/node_modules/@aws-sdk/client-route-53/package.json +5 -5
- package/node_modules/@aws-sdk/client-s3/dist-cjs/index.js +1 -1
- package/node_modules/@aws-sdk/client-s3/package.json +9 -9
- package/node_modules/@aws-sdk/client-ses/dist-cjs/index.js +1 -1
- package/node_modules/@aws-sdk/client-ses/package.json +5 -5
- package/node_modules/@aws-sdk/client-ssm/dist-cjs/index.js +1 -1
- package/node_modules/@aws-sdk/client-ssm/package.json +5 -5
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/httpAuthSchemes/index.js +1 -4
- package/node_modules/@aws-sdk/core/dist-es/submodules/httpAuthSchemes/utils/getUpdatedSystemClockOffset.js +1 -4
- package/node_modules/@aws-sdk/core/dist-types/submodules/httpAuthSchemes/utils/getUpdatedSystemClockOffset.d.ts +3 -7
- package/node_modules/@aws-sdk/core/package.json +3 -3
- package/node_modules/@aws-sdk/credential-provider-env/package.json +3 -3
- package/node_modules/@aws-sdk/credential-provider-http/package.json +4 -4
- package/node_modules/@aws-sdk/credential-provider-ini/package.json +10 -10
- package/node_modules/@aws-sdk/credential-provider-login/package.json +4 -4
- package/node_modules/@aws-sdk/credential-provider-node/package.json +8 -8
- package/node_modules/@aws-sdk/credential-provider-process/package.json +3 -3
- package/node_modules/@aws-sdk/credential-provider-sso/package.json +5 -5
- package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +4 -4
- package/node_modules/@aws-sdk/middleware-sdk-s3/package.json +4 -4
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/cognito-identity/index.js +1 -1
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/signin/index.js +8 -1
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso/index.js +1 -1
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso-oidc/index.js +1 -1
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sts/index.js +1 -1
- package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/signin/models/enums.js +7 -0
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/Signin.d.ts +1 -2
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/SigninClient.d.ts +1 -2
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/commands/CreateOAuth2TokenCommand.d.ts +5 -59
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/commands/CreateOAuth2TokenWithIAMCommand.d.ts +5 -33
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/index.d.ts +1 -2
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/models/enums.d.ts +16 -9
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/models/errors.d.ts +8 -39
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/models/models_0.d.ts +36 -48
- package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/models/enums.d.ts +7 -0
- package/node_modules/@aws-sdk/nested-clients/package.json +5 -5
- package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +2 -2
- package/node_modules/@aws-sdk/token-providers/package.json +4 -4
- package/node_modules/@smithy/core/dist-cjs/index.js +4 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/cbor/index.js +32 -16
- package/node_modules/@smithy/core/dist-cjs/submodules/client/index.js +36 -17
- package/node_modules/@smithy/core/dist-cjs/submodules/config/index.browser.js +8 -4
- package/node_modules/@smithy/core/dist-cjs/submodules/config/index.js +16 -8
- package/node_modules/@smithy/core/dist-cjs/submodules/config/index.native.js +8 -4
- package/node_modules/@smithy/core/dist-cjs/submodules/endpoints/index.browser.js +2 -1
- package/node_modules/@smithy/core/dist-cjs/submodules/endpoints/index.js +10 -5
- package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.browser.js +18 -9
- package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.js +18 -9
- package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +42 -24
- package/node_modules/@smithy/core/dist-cjs/submodules/retry/index.browser.js +20 -10
- package/node_modules/@smithy/core/dist-cjs/submodules/retry/index.js +24 -12
- package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.browser.js +13 -4
- package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.js +7 -1
- package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.native.js +13 -4
- package/node_modules/@smithy/core/dist-cjs/submodules/transport/index.js +6 -3
- package/node_modules/@smithy/core/dist-es/legacy-root-exports/util-identity-and-auth/DefaultIdentityProviderConfig.js +2 -1
- package/node_modules/@smithy/core/dist-es/normalizeProvider.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/cbor/codec-v1/CborShapeDeserializer.js +8 -4
- package/node_modules/@smithy/core/dist-es/submodules/cbor/codec-v1/CborShapeSerializer.js +6 -3
- package/node_modules/@smithy/core/dist-es/submodules/cbor/codec-v2/CborShapeDeserializer2.js +12 -6
- package/node_modules/@smithy/core/dist-es/submodules/cbor/codec-v2/CborShapeSerializer2.js +4 -2
- package/node_modules/@smithy/core/dist-es/submodules/cbor/parseCborBody.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/client/middleware-stack/MiddlewareStack.js +10 -5
- package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/create-aggregated-client.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/exceptions.js +4 -2
- package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/extensions/checksum.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/get-value-from-text-node.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/object-mapping.js +4 -2
- package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/schemaLogFilter.js +10 -4
- package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/serde-json.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/config/shared-ini-file-loader/getHomeDir.js +8 -4
- package/node_modules/@smithy/core/dist-es/submodules/config/util-config-provider/booleanSelector.js +6 -3
- package/node_modules/@smithy/core/dist-es/submodules/config/util-config-provider/numberSelector.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/middleware-endpoint/adaptors/getEndpointUrlConfig.js +8 -4
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/util-endpoints/resolveEndpoint.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/EventStreamSerde.js +6 -3
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-codec/HeaderMarshaller.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-codec/Int64.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-codec/SmithyMessageDecoderStream.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-serde/utils.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-serde-universal/getUnmarshalledStream.js +4 -2
- package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpBindingProtocol.js +8 -4
- package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpProtocol.js +4 -2
- package/node_modules/@smithy/core/dist-es/submodules/protocols/RpcProtocol.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/protocols/json/codec-v1/JsonShapeDeserializer.js +7 -5
- package/node_modules/@smithy/core/dist-es/submodules/protocols/json/codec-v1/JsonShapeSerializer.js +7 -5
- package/node_modules/@smithy/core/dist-es/submodules/protocols/json/codec-v2/JsonShapeDeserializer2.js +7 -5
- package/node_modules/@smithy/core/dist-es/submodules/protocols/json/codec-v2/JsonShapeSerializer2.js +6 -3
- package/node_modules/@smithy/core/dist-es/submodules/protocols/protocol-http/extensions/httpExtensionConfiguration.js +3 -0
- package/node_modules/@smithy/core/dist-es/submodules/retry/middleware-retry/configurations.js +4 -2
- package/node_modules/@smithy/core/dist-es/submodules/retry/middleware-retry/parseRetryAfterHeader.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/retry/middleware-retry/retry-pre-sra-deprecated/StandardRetryStrategy.js +6 -3
- package/node_modules/@smithy/core/dist-es/submodules/retry/middleware-retry/retryMiddleware.js +6 -3
- package/node_modules/@smithy/core/dist-es/submodules/retry/middleware-retry/util.js +6 -3
- package/node_modules/@smithy/core/dist-es/submodules/serde/index.browser.js +1 -0
- package/node_modules/@smithy/core/dist-es/submodules/serde/index.js +1 -0
- package/node_modules/@smithy/core/dist-es/submodules/serde/index.native.js +1 -0
- package/node_modules/@smithy/core/dist-es/submodules/serde/parse-utils.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/serde/util-body-length/calculateBodyLength.browser.js +6 -3
- package/node_modules/@smithy/core/dist-es/submodules/transport/httpResponse.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/transport/normalizeProvider.js +2 -1
- package/node_modules/@smithy/core/dist-es/submodules/transport/toEndpointV1.js +2 -1
- package/node_modules/@smithy/core/dist-types/submodules/protocols/protocol-http/extensions/httpExtensionConfiguration.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/submodules/serde/index.browser.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/submodules/serde/index.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/submodules/serde/index.native.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/protocol-http/extensions/httpExtensionConfiguration.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/serde/index.browser.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/serde/index.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/serde/index.native.d.ts +1 -0
- package/node_modules/@smithy/core/package.json +1 -1
- package/node_modules/@smithy/node-http-handler/dist-cjs/index.js +22 -9
- package/node_modules/@smithy/node-http-handler/dist-es/get-transformed-headers.js +2 -1
- package/node_modules/@smithy/node-http-handler/dist-es/node-http-handler.js +14 -8
- package/node_modules/@smithy/node-http-handler/dist-es/node-http2-handler.js +6 -0
- package/node_modules/@smithy/node-http-handler/package.json +2 -2
- package/node_modules/@smithy/signature-v4/dist-cjs/index.js +23 -11
- package/node_modules/@smithy/signature-v4/dist-es/HeaderFormatter.js +4 -2
- package/node_modules/@smithy/signature-v4/dist-es/SignatureV4Base.js +4 -2
- package/node_modules/@smithy/signature-v4/dist-es/getCanonicalHeaders.js +5 -1
- package/node_modules/@smithy/signature-v4/dist-es/getCanonicalQuery.js +2 -1
- package/node_modules/@smithy/signature-v4/dist-es/getPayloadHash.js +2 -1
- package/node_modules/@smithy/signature-v4/dist-es/headerUtil.js +6 -3
- package/node_modules/@smithy/signature-v4/dist-es/moveHeadersToQuery.js +2 -1
- package/node_modules/@smithy/signature-v4/dist-es/prepareRequest.js +2 -1
- package/node_modules/@smithy/signature-v4/package.json +2 -2
- package/package.json +7 -7
- /package/node_modules/@smithy/core/dist-es/submodules/{protocols → serde}/writeKey.js +0 -0
- /package/node_modules/@smithy/core/dist-types/submodules/{protocols → serde}/writeKey.d.ts +0 -0
- /package/node_modules/@smithy/core/dist-types/ts3.4/submodules/{protocols → serde}/writeKey.d.ts +0 -0
|
@@ -157,8 +157,9 @@ const constructStack = () => {
|
|
|
157
157
|
const aliases = getAllAliases(name, _aliases);
|
|
158
158
|
if (aliases.length > 0) {
|
|
159
159
|
if (aliases.some((alias) => entriesNameSet.has(alias))) {
|
|
160
|
-
if (!override)
|
|
160
|
+
if (!override) {
|
|
161
161
|
throw new Error(`Duplicate middleware name '${getMiddlewareNameWithAliases(name, _aliases)}'`);
|
|
162
|
+
}
|
|
162
163
|
for (const alias of aliases) {
|
|
163
164
|
const toOverrideIndex = absoluteEntries.findIndex((entry) => entry.name === alias || entry.aliases?.some((a) => a === alias));
|
|
164
165
|
if (toOverrideIndex === -1) {
|
|
@@ -189,8 +190,9 @@ const constructStack = () => {
|
|
|
189
190
|
const aliases = getAllAliases(name, _aliases);
|
|
190
191
|
if (aliases.length > 0) {
|
|
191
192
|
if (aliases.some((alias) => entriesNameSet.has(alias))) {
|
|
192
|
-
if (!override)
|
|
193
|
+
if (!override) {
|
|
193
194
|
throw new Error(`Duplicate middleware name '${getMiddlewareNameWithAliases(name, _aliases)}'`);
|
|
195
|
+
}
|
|
194
196
|
for (const alias of aliases) {
|
|
195
197
|
const toOverrideIndex = relativeEntries.findIndex((entry) => entry.name === alias || entry.aliases?.some((a) => a === alias));
|
|
196
198
|
if (toOverrideIndex === -1) {
|
|
@@ -217,10 +219,12 @@ const constructStack = () => {
|
|
|
217
219
|
plugin.applyToStack(stack);
|
|
218
220
|
},
|
|
219
221
|
remove: (toRemove) => {
|
|
220
|
-
if (typeof toRemove === "string")
|
|
222
|
+
if (typeof toRemove === "string") {
|
|
221
223
|
return removeByName(toRemove);
|
|
222
|
-
|
|
224
|
+
}
|
|
225
|
+
else {
|
|
223
226
|
return removeByReference(toRemove);
|
|
227
|
+
}
|
|
224
228
|
},
|
|
225
229
|
removeByTag: (toRemove) => {
|
|
226
230
|
let isRemoved = false;
|
|
@@ -257,8 +261,9 @@ const constructStack = () => {
|
|
|
257
261
|
});
|
|
258
262
|
},
|
|
259
263
|
identifyOnResolve(toggle) {
|
|
260
|
-
if (typeof toggle === "boolean")
|
|
264
|
+
if (typeof toggle === "boolean") {
|
|
261
265
|
identifyOnResolve = toggle;
|
|
266
|
+
}
|
|
262
267
|
return identifyOnResolve;
|
|
263
268
|
},
|
|
264
269
|
resolve: (handler, context) => {
|
|
@@ -554,16 +559,22 @@ function schemaLogFilter(schema, data) {
|
|
|
554
559
|
return SENSITIVE_STRING$1;
|
|
555
560
|
}
|
|
556
561
|
if (ns.isListSchema()) {
|
|
557
|
-
const
|
|
558
|
-
if (
|
|
562
|
+
const valueSchema = ns.getValueSchema();
|
|
563
|
+
if (valueSchema.getMergedTraits().sensitive) {
|
|
559
564
|
return SENSITIVE_STRING$1;
|
|
560
565
|
}
|
|
566
|
+
if (Array.isArray(data)) {
|
|
567
|
+
return data.map((value) => schemaLogFilter(valueSchema, value));
|
|
568
|
+
}
|
|
561
569
|
}
|
|
562
570
|
else if (ns.isMapSchema()) {
|
|
563
|
-
const
|
|
564
|
-
if (
|
|
571
|
+
const valueSchema = ns.getValueSchema();
|
|
572
|
+
if (ns.getKeySchema().getMergedTraits().sensitive || valueSchema.getMergedTraits().sensitive) {
|
|
565
573
|
return SENSITIVE_STRING$1;
|
|
566
574
|
}
|
|
575
|
+
if (typeof data === "object") {
|
|
576
|
+
return Object.fromEntries(Object.entries(data).map(([key, value]) => [key, schemaLogFilter(valueSchema, value)]));
|
|
577
|
+
}
|
|
567
578
|
}
|
|
568
579
|
else if (ns.isStructSchema() && typeof data === "object") {
|
|
569
580
|
const object = data;
|
|
@@ -737,8 +748,9 @@ const createAggregatedClient = (commands, Client, options) => {
|
|
|
737
748
|
this.send(command, optionsOrCb);
|
|
738
749
|
}
|
|
739
750
|
else if (typeof cb === "function") {
|
|
740
|
-
if (typeof optionsOrCb !== "object")
|
|
751
|
+
if (typeof optionsOrCb !== "object") {
|
|
741
752
|
throw new Error(`Expected http options but got ${typeof optionsOrCb}`);
|
|
753
|
+
}
|
|
742
754
|
this.send(command, optionsOrCb || {}, cb);
|
|
743
755
|
}
|
|
744
756
|
else {
|
|
@@ -791,8 +803,9 @@ class ServiceException extends Error {
|
|
|
791
803
|
this.$metadata = options.$metadata;
|
|
792
804
|
}
|
|
793
805
|
static isInstance(value) {
|
|
794
|
-
if (!value)
|
|
806
|
+
if (!value) {
|
|
795
807
|
return false;
|
|
808
|
+
}
|
|
796
809
|
const candidate = value;
|
|
797
810
|
return (ServiceException.prototype.isPrototypeOf(candidate) ||
|
|
798
811
|
(Boolean(candidate.$fault) &&
|
|
@@ -800,8 +813,9 @@ class ServiceException extends Error {
|
|
|
800
813
|
(candidate.$fault === "client" || candidate.$fault === "server")));
|
|
801
814
|
}
|
|
802
815
|
static [Symbol.hasInstance](instance) {
|
|
803
|
-
if (!instance)
|
|
816
|
+
if (!instance) {
|
|
804
817
|
return false;
|
|
818
|
+
}
|
|
805
819
|
const candidate = instance;
|
|
806
820
|
if (this === ServiceException) {
|
|
807
821
|
return ServiceException.isInstance(instance);
|
|
@@ -925,8 +939,9 @@ const knownAlgorithms = Object.values(AlgorithmId);
|
|
|
925
939
|
const getChecksumConfiguration = (runtimeConfig) => {
|
|
926
940
|
const checksumAlgorithms = [];
|
|
927
941
|
for (const id in AlgorithmId) {
|
|
928
|
-
if (!hasOwn(AlgorithmId, id))
|
|
942
|
+
if (!hasOwn(AlgorithmId, id)) {
|
|
929
943
|
continue;
|
|
944
|
+
}
|
|
930
945
|
const algorithmId = AlgorithmId[id];
|
|
931
946
|
if (runtimeConfig[algorithmId] === undefined) {
|
|
932
947
|
continue;
|
|
@@ -1000,8 +1015,9 @@ const getArrayIfSingleItem = (mayBeArray) => Array.isArray(mayBeArray) ? mayBeAr
|
|
|
1000
1015
|
const getValueFromTextNode = (obj) => {
|
|
1001
1016
|
const textNodeName = "#text";
|
|
1002
1017
|
for (const key in obj) {
|
|
1003
|
-
if (!hasOwn(obj, key))
|
|
1018
|
+
if (!hasOwn(obj, key)) {
|
|
1004
1019
|
continue;
|
|
1020
|
+
}
|
|
1005
1021
|
if (obj[key][textNodeName] !== undefined) {
|
|
1006
1022
|
obj[key] = obj[key][textNodeName];
|
|
1007
1023
|
}
|
|
@@ -1044,8 +1060,9 @@ function map(arg0, arg1, arg2) {
|
|
|
1044
1060
|
}
|
|
1045
1061
|
}
|
|
1046
1062
|
for (const key in instructions) {
|
|
1047
|
-
if (!hasOwn(instructions, key))
|
|
1063
|
+
if (!hasOwn(instructions, key)) {
|
|
1048
1064
|
continue;
|
|
1065
|
+
}
|
|
1049
1066
|
if (!Array.isArray(instructions[key])) {
|
|
1050
1067
|
target[key] = instructions[key];
|
|
1051
1068
|
continue;
|
|
@@ -1064,8 +1081,9 @@ const convertMap = (target) => {
|
|
|
1064
1081
|
const take = (source, instructions) => {
|
|
1065
1082
|
const out = {};
|
|
1066
1083
|
for (const key in instructions) {
|
|
1067
|
-
if (!hasOwn(instructions, key))
|
|
1084
|
+
if (!hasOwn(instructions, key)) {
|
|
1068
1085
|
continue;
|
|
1086
|
+
}
|
|
1069
1087
|
applyInstruction(out, source, instructions, key);
|
|
1070
1088
|
}
|
|
1071
1089
|
return out;
|
|
@@ -1146,8 +1164,9 @@ const _json = (obj) => {
|
|
|
1146
1164
|
if (typeof obj === "object") {
|
|
1147
1165
|
const target = {};
|
|
1148
1166
|
for (const key in obj) {
|
|
1149
|
-
if (!hasOwn(obj, key))
|
|
1167
|
+
if (!hasOwn(obj, key)) {
|
|
1150
1168
|
continue;
|
|
1169
|
+
}
|
|
1151
1170
|
if (obj[key] == null) {
|
|
1152
1171
|
continue;
|
|
1153
1172
|
}
|
|
@@ -111,18 +111,22 @@ const memoize = (provider, isExpired, requiresRefresh) => {
|
|
|
111
111
|
};
|
|
112
112
|
|
|
113
113
|
const booleanSelector = (obj, key, type) => {
|
|
114
|
-
if (!(key in obj))
|
|
114
|
+
if (!(key in obj)) {
|
|
115
115
|
return undefined;
|
|
116
|
-
|
|
116
|
+
}
|
|
117
|
+
if (obj[key] === "true") {
|
|
117
118
|
return true;
|
|
118
|
-
|
|
119
|
+
}
|
|
120
|
+
if (obj[key] === "false") {
|
|
119
121
|
return false;
|
|
122
|
+
}
|
|
120
123
|
throw new Error(`Cannot load ${type} "${key}". Expected "true" or "false", got ${obj[key]}.`);
|
|
121
124
|
};
|
|
122
125
|
|
|
123
126
|
const numberSelector = (obj, key, type) => {
|
|
124
|
-
if (!(key in obj))
|
|
127
|
+
if (!(key in obj)) {
|
|
125
128
|
return undefined;
|
|
129
|
+
}
|
|
126
130
|
const numberValue = parseInt(obj[key], 10);
|
|
127
131
|
if (Number.isNaN(numberValue)) {
|
|
128
132
|
throw new TypeError(`Cannot load ${type} '${key}'. Expected number, got '${obj[key]}'.`);
|
|
@@ -116,18 +116,22 @@ const memoize = (provider, isExpired, requiresRefresh) => {
|
|
|
116
116
|
};
|
|
117
117
|
|
|
118
118
|
const booleanSelector = (obj, key, type) => {
|
|
119
|
-
if (!(key in obj))
|
|
119
|
+
if (!(key in obj)) {
|
|
120
120
|
return undefined;
|
|
121
|
-
|
|
121
|
+
}
|
|
122
|
+
if (obj[key] === "true") {
|
|
122
123
|
return true;
|
|
123
|
-
|
|
124
|
+
}
|
|
125
|
+
if (obj[key] === "false") {
|
|
124
126
|
return false;
|
|
127
|
+
}
|
|
125
128
|
throw new Error(`Cannot load ${type} "${key}". Expected "true" or "false", got ${obj[key]}.`);
|
|
126
129
|
};
|
|
127
130
|
|
|
128
131
|
const numberSelector = (obj, key, type) => {
|
|
129
|
-
if (!(key in obj))
|
|
132
|
+
if (!(key in obj)) {
|
|
130
133
|
return undefined;
|
|
134
|
+
}
|
|
131
135
|
const numberValue = parseInt(obj[key], 10);
|
|
132
136
|
if (Number.isNaN(numberValue)) {
|
|
133
137
|
throw new TypeError(`Cannot load ${type} '${key}'. Expected number, got '${obj[key]}'.`);
|
|
@@ -150,15 +154,19 @@ const getHomeDirCacheKey = () => {
|
|
|
150
154
|
};
|
|
151
155
|
const getHomeDir = () => {
|
|
152
156
|
const { HOME, USERPROFILE, HOMEPATH, HOMEDRIVE = `C:${sep}` } = process.env;
|
|
153
|
-
if (HOME)
|
|
157
|
+
if (HOME) {
|
|
154
158
|
return HOME;
|
|
155
|
-
|
|
159
|
+
}
|
|
160
|
+
if (USERPROFILE) {
|
|
156
161
|
return USERPROFILE;
|
|
157
|
-
|
|
162
|
+
}
|
|
163
|
+
if (HOMEPATH) {
|
|
158
164
|
return `${HOMEDRIVE}${HOMEPATH}`;
|
|
165
|
+
}
|
|
159
166
|
const homeDirCacheKey = getHomeDirCacheKey();
|
|
160
|
-
if (!homeDirCache[homeDirCacheKey])
|
|
167
|
+
if (!homeDirCache[homeDirCacheKey]) {
|
|
161
168
|
homeDirCache[homeDirCacheKey] = homedir();
|
|
169
|
+
}
|
|
162
170
|
return homeDirCache[homeDirCacheKey];
|
|
163
171
|
};
|
|
164
172
|
|
|
@@ -111,18 +111,22 @@ const memoize = (provider, isExpired, requiresRefresh) => {
|
|
|
111
111
|
};
|
|
112
112
|
|
|
113
113
|
const booleanSelector = (obj, key, type) => {
|
|
114
|
-
if (!(key in obj))
|
|
114
|
+
if (!(key in obj)) {
|
|
115
115
|
return undefined;
|
|
116
|
-
|
|
116
|
+
}
|
|
117
|
+
if (obj[key] === "true") {
|
|
117
118
|
return true;
|
|
118
|
-
|
|
119
|
+
}
|
|
120
|
+
if (obj[key] === "false") {
|
|
119
121
|
return false;
|
|
122
|
+
}
|
|
120
123
|
throw new Error(`Cannot load ${type} "${key}". Expected "true" or "false", got ${obj[key]}.`);
|
|
121
124
|
};
|
|
122
125
|
|
|
123
126
|
const numberSelector = (obj, key, type) => {
|
|
124
|
-
if (!(key in obj))
|
|
127
|
+
if (!(key in obj)) {
|
|
125
128
|
return undefined;
|
|
129
|
+
}
|
|
126
130
|
const numberValue = parseInt(obj[key], 10);
|
|
127
131
|
if (Number.isNaN(numberValue)) {
|
|
128
132
|
throw new TypeError(`Cannot load ${type} '${key}'. Expected number, got '${obj[key]}'.`);
|
|
@@ -783,8 +783,9 @@ const resolveEndpoint = (ruleSetObject, options) => {
|
|
|
783
783
|
const { parameters, rules } = ruleSetObject;
|
|
784
784
|
options.logger?.debug?.(`${debugId} Initial EndpointParams: ${toDebugString(endpointParams)}`);
|
|
785
785
|
for (const paramKey in parameters) {
|
|
786
|
-
if (!hasOwn(parameters, paramKey))
|
|
786
|
+
if (!hasOwn(parameters, paramKey)) {
|
|
787
787
|
continue;
|
|
788
|
+
}
|
|
788
789
|
const parameter = parameters[paramKey];
|
|
789
790
|
const endpointParam = endpointParams[paramKey];
|
|
790
791
|
if (endpointParam == null && parameter.default != null) {
|
|
@@ -11,11 +11,13 @@ const getEndpointUrlConfig = (serviceId) => ({
|
|
|
11
11
|
environmentVariableSelector: (env) => {
|
|
12
12
|
const serviceSuffixParts = serviceId.split(" ").map((w) => w.toUpperCase());
|
|
13
13
|
const serviceEndpointUrl = env[[ENV_ENDPOINT_URL, ...serviceSuffixParts].join("_")];
|
|
14
|
-
if (serviceEndpointUrl)
|
|
14
|
+
if (serviceEndpointUrl) {
|
|
15
15
|
return serviceEndpointUrl;
|
|
16
|
+
}
|
|
16
17
|
const endpointUrl = env[ENV_ENDPOINT_URL];
|
|
17
|
-
if (endpointUrl)
|
|
18
|
+
if (endpointUrl) {
|
|
18
19
|
return endpointUrl;
|
|
20
|
+
}
|
|
19
21
|
return undefined;
|
|
20
22
|
},
|
|
21
23
|
configFileSelector: (profile, config) => {
|
|
@@ -27,12 +29,14 @@ const getEndpointUrlConfig = (serviceId) => ({
|
|
|
27
29
|
const servicesSection = config[servicesSectionKey];
|
|
28
30
|
const servicePrefixParts = serviceId.split(" ").map((w) => w.toLowerCase());
|
|
29
31
|
const endpointUrl = servicesSection[[servicePrefixParts.join("_"), CONFIG_ENDPOINT_URL].join(CONFIG_PREFIX_SEPARATOR)];
|
|
30
|
-
if (endpointUrl)
|
|
32
|
+
if (endpointUrl) {
|
|
31
33
|
return endpointUrl;
|
|
34
|
+
}
|
|
32
35
|
}
|
|
33
36
|
const endpointUrl = profile[CONFIG_ENDPOINT_URL];
|
|
34
|
-
if (endpointUrl)
|
|
37
|
+
if (endpointUrl) {
|
|
35
38
|
return endpointUrl;
|
|
39
|
+
}
|
|
36
40
|
return undefined;
|
|
37
41
|
},
|
|
38
42
|
default: undefined,
|
|
@@ -831,8 +835,9 @@ const resolveEndpoint = (ruleSetObject, options) => {
|
|
|
831
835
|
const { parameters, rules } = ruleSetObject;
|
|
832
836
|
options.logger?.debug?.(`${debugId} Initial EndpointParams: ${toDebugString(endpointParams)}`);
|
|
833
837
|
for (const paramKey in parameters) {
|
|
834
|
-
if (!hasOwn(parameters, paramKey))
|
|
838
|
+
if (!hasOwn(parameters, paramKey)) {
|
|
835
839
|
continue;
|
|
840
|
+
}
|
|
836
841
|
const parameter = parameters[paramKey];
|
|
837
842
|
const endpointParam = endpointParams[paramKey];
|
|
838
843
|
if (endpointParam == null && parameter.default != null) {
|
|
@@ -42,8 +42,9 @@ function negate(bytes) {
|
|
|
42
42
|
}
|
|
43
43
|
for (let i = 7; i > -1; i--) {
|
|
44
44
|
bytes[i]++;
|
|
45
|
-
if (bytes[i] !== 0)
|
|
45
|
+
if (bytes[i] !== 0) {
|
|
46
46
|
break;
|
|
47
|
+
}
|
|
47
48
|
}
|
|
48
49
|
}
|
|
49
50
|
|
|
@@ -57,8 +58,9 @@ class HeaderMarshaller {
|
|
|
57
58
|
format(headers) {
|
|
58
59
|
const chunks = [];
|
|
59
60
|
for (const headerName in headers) {
|
|
60
|
-
if (!hasOwn(headers, headerName))
|
|
61
|
+
if (!hasOwn(headers, headerName)) {
|
|
61
62
|
continue;
|
|
63
|
+
}
|
|
62
64
|
const bytes = this.fromUtf8(headerName);
|
|
63
65
|
if (bytes.byteLength > 255) {
|
|
64
66
|
throw new Error(`@smithy/core/event-streams - header name exceeds 255 bytes: ${bytes.byteLength}`);
|
|
@@ -384,8 +386,9 @@ class SmithyMessageDecoderStream {
|
|
|
384
386
|
async *asyncIterator() {
|
|
385
387
|
for await (const message of this.options.messageStream) {
|
|
386
388
|
const deserialized = await this.options.deserializer(message);
|
|
387
|
-
if (deserialized === undefined)
|
|
389
|
+
if (deserialized === undefined) {
|
|
388
390
|
continue;
|
|
391
|
+
}
|
|
389
392
|
yield deserialized;
|
|
390
393
|
}
|
|
391
394
|
}
|
|
@@ -481,8 +484,9 @@ function getUnmarshalledStream(source, options) {
|
|
|
481
484
|
for await (const chunk of source) {
|
|
482
485
|
const message = options.eventStreamCodec.decode(chunk);
|
|
483
486
|
const type = await messageUnmarshaller(message);
|
|
484
|
-
if (type === undefined)
|
|
487
|
+
if (type === undefined) {
|
|
485
488
|
continue;
|
|
489
|
+
}
|
|
486
490
|
yield type;
|
|
487
491
|
}
|
|
488
492
|
},
|
|
@@ -512,8 +516,9 @@ function getMessageUnmarshaller(deserializer, toUtf8) {
|
|
|
512
516
|
[message.headers[":event-type"].value]: message,
|
|
513
517
|
};
|
|
514
518
|
const deserialized = await deserializer(event);
|
|
515
|
-
if (deserialized.$unknown)
|
|
519
|
+
if (deserialized.$unknown) {
|
|
516
520
|
return;
|
|
521
|
+
}
|
|
517
522
|
return deserialized;
|
|
518
523
|
}
|
|
519
524
|
else {
|
|
@@ -552,8 +557,9 @@ const readableStreamToIterable = (readableStream) => ({
|
|
|
552
557
|
try {
|
|
553
558
|
while (true) {
|
|
554
559
|
const { done, value } = await reader.read();
|
|
555
|
-
if (done)
|
|
560
|
+
if (done) {
|
|
556
561
|
return;
|
|
562
|
+
}
|
|
557
563
|
yield value;
|
|
558
564
|
}
|
|
559
565
|
}
|
|
@@ -651,8 +657,9 @@ class EventStreamSerde {
|
|
|
651
657
|
}
|
|
652
658
|
let unionMember = "";
|
|
653
659
|
for (const key in event) {
|
|
654
|
-
if (!hasOwn(event, key))
|
|
660
|
+
if (!hasOwn(event, key)) {
|
|
655
661
|
continue;
|
|
662
|
+
}
|
|
656
663
|
if (key !== "__type") {
|
|
657
664
|
unionMember = key;
|
|
658
665
|
break;
|
|
@@ -680,8 +687,9 @@ class EventStreamSerde {
|
|
|
680
687
|
const asyncIterable = marshaller.deserialize(response.body, async (event) => {
|
|
681
688
|
let unionMember = "";
|
|
682
689
|
for (const key in event) {
|
|
683
|
-
if (!hasOwn(event, key))
|
|
690
|
+
if (!hasOwn(event, key)) {
|
|
684
691
|
continue;
|
|
692
|
+
}
|
|
685
693
|
if (key !== "__type") {
|
|
686
694
|
unionMember = key;
|
|
687
695
|
break;
|
|
@@ -756,8 +764,9 @@ class EventStreamSerde {
|
|
|
756
764
|
throw new Error("@smithy::core/protocols - initial-response event encountered in event stream but no response schema given.");
|
|
757
765
|
}
|
|
758
766
|
for (const key in firstEvent.value) {
|
|
759
|
-
if (!hasOwn(firstEvent.value, key))
|
|
767
|
+
if (!hasOwn(firstEvent.value, key)) {
|
|
760
768
|
continue;
|
|
769
|
+
}
|
|
761
770
|
initialResponseContainer[key] = firstEvent.value[key];
|
|
762
771
|
}
|
|
763
772
|
}
|
|
@@ -43,8 +43,9 @@ function negate(bytes) {
|
|
|
43
43
|
}
|
|
44
44
|
for (let i = 7; i > -1; i--) {
|
|
45
45
|
bytes[i]++;
|
|
46
|
-
if (bytes[i] !== 0)
|
|
46
|
+
if (bytes[i] !== 0) {
|
|
47
47
|
break;
|
|
48
|
+
}
|
|
48
49
|
}
|
|
49
50
|
}
|
|
50
51
|
|
|
@@ -58,8 +59,9 @@ class HeaderMarshaller {
|
|
|
58
59
|
format(headers) {
|
|
59
60
|
const chunks = [];
|
|
60
61
|
for (const headerName in headers) {
|
|
61
|
-
if (!hasOwn(headers, headerName))
|
|
62
|
+
if (!hasOwn(headers, headerName)) {
|
|
62
63
|
continue;
|
|
64
|
+
}
|
|
63
65
|
const bytes = this.fromUtf8(headerName);
|
|
64
66
|
if (bytes.byteLength > 255) {
|
|
65
67
|
throw new Error(`@smithy/core/event-streams - header name exceeds 255 bytes: ${bytes.byteLength}`);
|
|
@@ -385,8 +387,9 @@ class SmithyMessageDecoderStream {
|
|
|
385
387
|
async *asyncIterator() {
|
|
386
388
|
for await (const message of this.options.messageStream) {
|
|
387
389
|
const deserialized = await this.options.deserializer(message);
|
|
388
|
-
if (deserialized === undefined)
|
|
390
|
+
if (deserialized === undefined) {
|
|
389
391
|
continue;
|
|
392
|
+
}
|
|
390
393
|
yield deserialized;
|
|
391
394
|
}
|
|
392
395
|
}
|
|
@@ -482,8 +485,9 @@ function getUnmarshalledStream(source, options) {
|
|
|
482
485
|
for await (const chunk of source) {
|
|
483
486
|
const message = options.eventStreamCodec.decode(chunk);
|
|
484
487
|
const type = await messageUnmarshaller(message);
|
|
485
|
-
if (type === undefined)
|
|
488
|
+
if (type === undefined) {
|
|
486
489
|
continue;
|
|
490
|
+
}
|
|
487
491
|
yield type;
|
|
488
492
|
}
|
|
489
493
|
},
|
|
@@ -513,8 +517,9 @@ function getMessageUnmarshaller(deserializer, toUtf8) {
|
|
|
513
517
|
[message.headers[":event-type"].value]: message,
|
|
514
518
|
};
|
|
515
519
|
const deserialized = await deserializer(event);
|
|
516
|
-
if (deserialized.$unknown)
|
|
520
|
+
if (deserialized.$unknown) {
|
|
517
521
|
return;
|
|
522
|
+
}
|
|
518
523
|
return deserialized;
|
|
519
524
|
}
|
|
520
525
|
else {
|
|
@@ -597,8 +602,9 @@ const readableStreamToIterable = (readableStream) => ({
|
|
|
597
602
|
try {
|
|
598
603
|
while (true) {
|
|
599
604
|
const { done, value } = await reader.read();
|
|
600
|
-
if (done)
|
|
605
|
+
if (done) {
|
|
601
606
|
return;
|
|
607
|
+
}
|
|
602
608
|
yield value;
|
|
603
609
|
}
|
|
604
610
|
}
|
|
@@ -676,8 +682,9 @@ class EventStreamSerde {
|
|
|
676
682
|
}
|
|
677
683
|
let unionMember = "";
|
|
678
684
|
for (const key in event) {
|
|
679
|
-
if (!hasOwn(event, key))
|
|
685
|
+
if (!hasOwn(event, key)) {
|
|
680
686
|
continue;
|
|
687
|
+
}
|
|
681
688
|
if (key !== "__type") {
|
|
682
689
|
unionMember = key;
|
|
683
690
|
break;
|
|
@@ -705,8 +712,9 @@ class EventStreamSerde {
|
|
|
705
712
|
const asyncIterable = marshaller.deserialize(response.body, async (event) => {
|
|
706
713
|
let unionMember = "";
|
|
707
714
|
for (const key in event) {
|
|
708
|
-
if (!hasOwn(event, key))
|
|
715
|
+
if (!hasOwn(event, key)) {
|
|
709
716
|
continue;
|
|
717
|
+
}
|
|
710
718
|
if (key !== "__type") {
|
|
711
719
|
unionMember = key;
|
|
712
720
|
break;
|
|
@@ -781,8 +789,9 @@ class EventStreamSerde {
|
|
|
781
789
|
throw new Error("@smithy::core/protocols - initial-response event encountered in event stream but no response schema given.");
|
|
782
790
|
}
|
|
783
791
|
for (const key in firstEvent.value) {
|
|
784
|
-
if (!hasOwn(firstEvent.value, key))
|
|
792
|
+
if (!hasOwn(firstEvent.value, key)) {
|
|
785
793
|
continue;
|
|
794
|
+
}
|
|
786
795
|
initialResponseContainer[key] = firstEvent.value[key];
|
|
787
796
|
}
|
|
788
797
|
}
|