cdk-preflight 1.12.0 → 1.12.1
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 +3 -3
- package/lib/index.js +1 -1
- package/node_modules/@aws-sdk/client-cloudformation/dist-cjs/index.js +1 -1
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/CloudFormationClient.d.ts +2 -1
- package/node_modules/@aws-sdk/client-cloudformation/package.json +6 -6
- package/node_modules/@aws-sdk/client-ec2/README.md +28 -0
- package/node_modules/@aws-sdk/client-ec2/dist-cjs/index.js +499 -113
- package/node_modules/@aws-sdk/client-ec2/dist-es/EC2.js +10 -0
- package/node_modules/@aws-sdk/client-ec2/dist-es/commands/GetCapacityManagerSupportabilityScoresCommand.js +4 -0
- package/node_modules/@aws-sdk/client-ec2/dist-es/commands/GetImageFindingsCommand.js +4 -0
- package/node_modules/@aws-sdk/client-ec2/dist-es/commands/GetTransitGatewayAttachmentNatConfigurationCommand.js +4 -0
- package/node_modules/@aws-sdk/client-ec2/dist-es/commands/ModifyTransitGatewayAttachmentNatConfigurationCommand.js +4 -0
- package/node_modules/@aws-sdk/client-ec2/dist-es/commands/index.js +4 -0
- package/node_modules/@aws-sdk/client-ec2/dist-es/models/enums.js +80 -29
- package/node_modules/@aws-sdk/client-ec2/dist-es/pagination/GetImageFindingsPaginator.js +4 -0
- package/node_modules/@aws-sdk/client-ec2/dist-es/pagination/index.js +1 -0
- package/node_modules/@aws-sdk/client-ec2/dist-es/schemas/schemas_0.js +365 -83
- package/node_modules/@aws-sdk/client-ec2/dist-types/EC2.d.ts +35 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/EC2Client.d.ts +8 -3
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/CreateCapacityReservationFleetCommand.d.ts +82 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/CreateCarrierGatewayCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/CreateTransitGatewayRouteCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DeleteLaunchTemplateCommand.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DeleteTransitGatewayRouteCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DeleteTransitGatewayRouteTableCommand.d.ts +5 -2
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeCapacityReservationFleetsCommand.d.ts +81 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeFleetHistoryCommand.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeImagesCommand.d.ts +9 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeInstanceStatusCommand.d.ts +5 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeNetworkInsightsAnalysesCommand.d.ts +48 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeReservedInstancesModificationsCommand.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeReservedInstancesOfferingsCommand.d.ts +1 -2
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeTransitGatewayAttachmentsCommand.d.ts +1 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DisassociateTransitGatewayPolicyTableCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DisassociateTransitGatewayRouteTableCommand.d.ts +1 -2
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetAllowedImagesSettingsCommand.d.ts +9 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetCapacityManagerMetricDataCommand.d.ts +2 -2
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetCapacityManagerMetricDimensionsCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetCapacityManagerSupportabilityScoresCommand.d.ts +183 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetImageFindingsCommand.d.ts +90 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetNetworkInsightsAccessScopeAnalysisFindingsCommand.d.ts +19 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetTransitGatewayAttachmentNatConfigurationCommand.d.ts +82 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetVerifiedAccessEndpointTargetsCommand.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetVerifiedAccessGroupPolicyCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetVpcResourcesBlockingEncryptionEnforcementCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetVpnConnectionDeviceSampleConfigurationCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetVpnConnectionDeviceTypesCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetVpnTunnelReplacementStatusCommand.d.ts +1 -2
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ModifyTransitGatewayAttachmentNatConfigurationCommand.d.ts +107 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/RejectTransitGatewayPeeringAttachmentCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/RejectTransitGatewayVpcAttachmentCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/RejectVpcEndpointConnectionsCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/RejectVpcPeeringConnectionCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ReleaseAddressCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ReleaseHostsCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ReleaseIpamPoolAllocationCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ReplaceIamInstanceProfileAssociationCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ReplaceImageCriteriaInAllowedImagesSettingsCommand.d.ts +9 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ReplaceTransitGatewayRouteCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/SearchTransitGatewayRoutesCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/StartNetworkInsightsAnalysisCommand.d.ts +48 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/commands/index.d.ts +4 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/enums.d.ts +192 -77
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_0.d.ts +165 -291
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_1.d.ts +1839 -1665
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_2.d.ts +25 -12
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_3.d.ts +27 -38
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_4.d.ts +241 -242
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_5.d.ts +247 -57
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_6.d.ts +537 -341
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_7.d.ts +389 -246
- package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_8.d.ts +360 -3
- package/node_modules/@aws-sdk/client-ec2/dist-types/pagination/GetImageFindingsPaginator.d.ts +7 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/pagination/index.d.ts +1 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/schemas/schemas_0.d.ts +21 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/EC2.d.ts +75 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/EC2Client.d.ts +24 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/CreateCapacityReservationFleetCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/CreateCarrierGatewayCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/DeleteLaunchTemplateCommand.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/DescribeFleetHistoryCommand.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/DescribeReservedInstancesModificationsCommand.d.ts +2 -4
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/DescribeReservedInstancesOfferingsCommand.d.ts +4 -2
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/DisassociateTransitGatewayPolicyTableCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/DisassociateTransitGatewayRouteTableCommand.d.ts +4 -2
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetCapacityManagerSupportabilityScoresCommand.d.ts +42 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetImageFindingsCommand.d.ts +38 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetTransitGatewayAttachmentNatConfigurationCommand.d.ts +42 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetVerifiedAccessEndpointTargetsCommand.d.ts +2 -4
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetVerifiedAccessGroupPolicyCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetVpcResourcesBlockingEncryptionEnforcementCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetVpnConnectionDeviceSampleConfigurationCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetVpnConnectionDeviceTypesCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetVpnTunnelReplacementStatusCommand.d.ts +4 -2
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/ModifyTransitGatewayAttachmentNatConfigurationCommand.d.ts +42 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/RejectTransitGatewayPeeringAttachmentCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/RejectTransitGatewayVpcAttachmentCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/RejectVpcEndpointConnectionsCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/RejectVpcPeeringConnectionCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/ReleaseAddressCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/ReleaseHostsCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/ReleaseIpamPoolAllocationCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/ReplaceIamInstanceProfileAssociationCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/index.d.ts +4 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/enums.d.ts +99 -35
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_0.d.ts +27 -60
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_1.d.ts +118 -69
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_2.d.ts +6 -6
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_3.d.ts +10 -9
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_4.d.ts +31 -34
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_5.d.ts +37 -14
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_6.d.ts +89 -68
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_7.d.ts +86 -64
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_8.d.ts +76 -1
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/pagination/GetImageFindingsPaginator.d.ts +11 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/pagination/index.d.ts +1 -0
- package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/schemas/schemas_0.d.ts +21 -0
- package/node_modules/@aws-sdk/client-ec2/package.json +8 -8
- package/node_modules/@aws-sdk/client-lambda/README.md +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-cjs/index.js +9 -3
- package/node_modules/@aws-sdk/client-lambda/dist-es/models/enums.js +4 -0
- package/node_modules/@aws-sdk/client-lambda/dist-es/schemas/schemas_0.js +3 -2
- package/node_modules/@aws-sdk/client-lambda/dist-types/Lambda.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/LambdaClient.d.ts +3 -2
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/CreateEventSourceMappingCommand.d.ts +2 -0
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/DeleteEventSourceMappingCommand.d.ts +1 -0
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/DeleteFunctionConcurrencyCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/GetEventSourceMappingCommand.d.ts +1 -0
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/GetFunctionCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/ListEventSourceMappingsCommand.d.ts +1 -0
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/ListFunctionEventInvokeConfigsCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/ListVersionsByFunctionCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/PublishVersionCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/PutFunctionConcurrencyCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/PutFunctionRecursionConfigCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/UpdateEventSourceMappingCommand.d.ts +2 -0
- package/node_modules/@aws-sdk/client-lambda/dist-types/commands/UpdateFunctionUrlConfigCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/index.d.ts +1 -1
- package/node_modules/@aws-sdk/client-lambda/dist-types/models/enums.d.ts +12 -0
- package/node_modules/@aws-sdk/client-lambda/dist-types/models/models_0.d.ts +21 -16
- package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/models/enums.d.ts +6 -0
- package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/models/models_0.d.ts +2 -0
- package/node_modules/@aws-sdk/client-lambda/package.json +7 -7
- package/node_modules/@aws-sdk/client-service-quotas/dist-cjs/index.js +1 -1
- package/node_modules/@aws-sdk/client-service-quotas/dist-types/ServiceQuotasClient.d.ts +2 -1
- package/node_modules/@aws-sdk/client-service-quotas/package.json +6 -6
- package/node_modules/@aws-sdk/client-sts/dist-cjs/index.js +1 -1
- package/node_modules/@aws-sdk/client-sts/dist-types/STSClient.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sts/package.json +8 -8
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/client/index.js +38 -13
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/httpAuthSchemes/index.js +7 -7
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/protocols/index.js +104 -1549
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/util/index.js +2 -1
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/getDefaultSocketTimeout.js +10 -0
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/index.browser.js +1 -0
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/index.js +1 -0
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/index.native.js +1 -0
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/middleware-host-header/hostHeaderMiddleware.js +4 -2
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/util-endpoints/lib/aws/parseArn.js +4 -2
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/util-user-agent-browser/defaultUserAgent.js +18 -9
- package/node_modules/@aws-sdk/core/dist-es/submodules/httpAuthSchemes/aws_sdk/NODE_AUTH_SCHEME_PREFERENCE_OPTIONS.js +6 -3
- package/node_modules/@aws-sdk/core/dist-es/submodules/httpAuthSchemes/utils/getUpdatedSystemClockOffset.js +1 -4
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/index.js +2 -7
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsJsonRpcProtocol.js +1 -3
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsRestJsonProtocol.js +1 -3
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsSmithyRpcV2JsonProtocol.js +51 -0
- package/node_modules/@aws-sdk/core/dist-es/submodules/util/util-arn-parser/arn.js +2 -1
- package/node_modules/@aws-sdk/core/dist-types/submodules/client/getDefaultSocketTimeout.d.ts +11 -0
- package/node_modules/@aws-sdk/core/dist-types/submodules/client/index.browser.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/submodules/client/index.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/submodules/client/index.native.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/submodules/httpAuthSchemes/utils/getUpdatedSystemClockOffset.d.ts +3 -7
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/index.d.ts +3 -8
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/AwsJson1_0Protocol.d.ts +1 -2
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/AwsJson1_1Protocol.d.ts +1 -2
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/AwsJsonRpcProtocol.d.ts +2 -3
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/AwsRestJsonProtocol.d.ts +2 -3
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/AwsSmithyRpcV2JsonProtocol.d.ts +25 -0
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/client/getDefaultSocketTimeout.d.ts +4 -0
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/client/index.browser.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/client/index.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/client/index.native.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/index.d.ts +11 -10
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/AwsJson1_0Protocol.d.ts +1 -2
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/AwsJson1_1Protocol.d.ts +1 -2
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/AwsJsonRpcProtocol.d.ts +2 -3
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/AwsRestJsonProtocol.d.ts +2 -3
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/AwsSmithyRpcV2JsonProtocol.d.ts +36 -0
- package/node_modules/@aws-sdk/core/package.json +5 -5
- package/node_modules/@aws-sdk/credential-provider-env/package.json +4 -4
- package/node_modules/@aws-sdk/credential-provider-http/package.json +5 -5
- package/node_modules/@aws-sdk/credential-provider-ini/package.json +11 -11
- package/node_modules/@aws-sdk/credential-provider-login/package.json +5 -5
- package/node_modules/@aws-sdk/credential-provider-node/package.json +9 -9
- package/node_modules/@aws-sdk/credential-provider-process/package.json +4 -4
- package/node_modules/@aws-sdk/credential-provider-sso/package.json +6 -6
- package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +5 -5
- package/node_modules/@aws-sdk/middleware-sdk-ec2/package.json +5 -5
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/cognito-identity/index.js +3 -2
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/signin/index.js +10 -2
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso/index.js +3 -2
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso-oidc/index.js +3 -2
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sts/index.js +3 -2
- package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/cognito-identity/runtimeConfig.js +2 -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-es/submodules/signin/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso-oidc/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/CognitoIdentityClient.d.ts +2 -1
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/runtimeConfig.d.ts +1 -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 +3 -3
- 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/submodules/signin/runtimeConfig.d.ts +1 -0
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/SSOClient.d.ts +2 -1
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/runtimeConfig.d.ts +1 -0
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/SSOOIDCClient.d.ts +2 -1
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/runtimeConfig.d.ts +1 -0
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/STSClient.d.ts +2 -1
- package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/runtimeConfig.d.ts +1 -0
- package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/runtimeConfig.d.ts +1 -0
- 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/dist-types/ts3.4/submodules/signin/runtimeConfig.d.ts +1 -0
- package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/runtimeConfig.d.ts +1 -0
- package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/runtimeConfig.d.ts +1 -0
- package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/runtimeConfig.d.ts +1 -0
- package/node_modules/@aws-sdk/nested-clients/package.json +6 -6
- package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +3 -3
- package/node_modules/@aws-sdk/token-providers/dist-cjs/index.js +37 -19
- package/node_modules/@aws-sdk/token-providers/dist-es/fromSso.js +37 -19
- package/node_modules/@aws-sdk/token-providers/package.json +5 -5
- package/node_modules/@aws-sdk/types/dist-types/feature-ids.d.ts +3 -0
- package/node_modules/@aws-sdk/types/dist-types/ts3.4/feature-ids.d.ts +3 -0
- package/node_modules/@aws-sdk/types/package.json +1 -1
- package/node_modules/@aws-sdk/xml-builder/package.json +1 -1
- package/node_modules/@smithy/core/dist-cjs/index.js +4 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/cbor/index.js +45 -53
- package/node_modules/@smithy/core/dist-cjs/submodules/client/index.js +52 -19
- 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 +28 -9
- package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.js +28 -9
- package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +91 -58
- package/node_modules/@smithy/core/dist-cjs/submodules/retry/index.browser.js +53 -15
- package/node_modules/@smithy/core/dist-cjs/submodules/retry/index.js +57 -17
- 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/SmithyRpcV2CborProtocol.js +12 -37
- 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/command.js +17 -2
- 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 +12 -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/AbstractRpcV2Protocol.js +35 -0
- 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 +6 -2
- package/node_modules/@smithy/core/dist-es/submodules/protocols/index.js +1 -0
- package/node_modules/@smithy/core/dist-es/submodules/protocols/json/SmithyRpcV2JsonProtocol.js +8 -31
- 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 +11 -8
- 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 +17 -8
- package/node_modules/@smithy/core/dist-es/submodules/retry/middleware-retry/util.js +6 -3
- package/node_modules/@smithy/core/dist-es/submodules/retry/util-retry/race.js +22 -0
- 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/cbor/SmithyRpcV2CborProtocol.d.ts +5 -14
- package/node_modules/@smithy/core/dist-types/submodules/protocols/AbstractRpcV2Protocol.d.ts +45 -0
- package/node_modules/@smithy/core/dist-types/submodules/protocols/RpcProtocol.d.ts +12 -0
- package/node_modules/@smithy/core/dist-types/submodules/protocols/index.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/submodules/protocols/json/SmithyRpcV2JsonProtocol.d.ts +5 -14
- 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/retry/util-retry/race.d.ts +3 -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/cbor/SmithyRpcV2CborProtocol.d.ts +5 -14
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/AbstractRpcV2Protocol.d.ts +45 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/RpcProtocol.d.ts +12 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/index.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/json/SmithyRpcV2JsonProtocol.d.ts +5 -14
- 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/retry/util-retry/race.d.ts +3 -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 +2 -2
- package/node_modules/@smithy/node-http-handler/dist-cjs/index.js +84 -29
- 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 +23 -11
- package/node_modules/@smithy/node-http-handler/dist-es/node-http2-handler.js +26 -2
- package/node_modules/@smithy/node-http-handler/dist-es/resolve-default-socket-timeout.js +4 -0
- package/node_modules/@smithy/node-http-handler/dist-es/set-socket-timeout.js +30 -15
- package/node_modules/@smithy/node-http-handler/dist-types/resolve-default-socket-timeout.d.ts +4 -0
- package/node_modules/@smithy/node-http-handler/dist-types/set-socket-timeout.d.ts +10 -1
- package/node_modules/@smithy/node-http-handler/dist-types/ts3.4/resolve-default-socket-timeout.d.ts +4 -0
- package/node_modules/@smithy/node-http-handler/dist-types/ts3.4/set-socket-timeout.d.ts +10 -1
- package/node_modules/@smithy/node-http-handler/package.json +3 -3
- 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/node_modules/@smithy/types/dist-types/middleware.d.ts +6 -0
- package/node_modules/@smithy/types/dist-types/ts3.4/middleware.d.ts +6 -0
- package/node_modules/@smithy/types/package.json +1 -1
- package/package.json +1 -1
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/JsonSettings.js +0 -1
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/codec-v1/JsonCodec.js +0 -20
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/codec-v1/JsonSettings.js +0 -1
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/codec-v1/JsonShapeDeserializer.js +0 -160
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/codec-v1/JsonShapeSerializer.js +0 -193
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/codec-v2/JsonBytesStringAdapter.js +0 -103
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/codec-v2/JsonCodec2.js +0 -20
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/codec-v2/JsonShapeDeserializer2.js +0 -200
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/codec-v2/JsonShapeSerializer2.js +0 -519
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/detectBufferParsing.js +0 -18
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/jsonReplacer.js +0 -46
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/jsonReviver.js +0 -121
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/needsReviver.js +0 -41
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/parseJsonBody.js +0 -89
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/JsonSettings.d.ts +0 -7
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/codec-v1/JsonCodec.d.ts +0 -15
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/codec-v1/JsonSettings.d.ts +0 -7
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/codec-v1/JsonShapeDeserializer.d.ts +0 -14
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/codec-v1/JsonShapeSerializer.d.ts +0 -29
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/codec-v2/JsonBytesStringAdapter.d.ts +0 -51
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/codec-v2/JsonCodec2.d.ts +0 -13
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/codec-v2/JsonShapeDeserializer2.d.ts +0 -30
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/codec-v2/JsonShapeSerializer2.d.ts +0 -60
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/detectBufferParsing.d.ts +0 -1
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/jsonReplacer.d.ts +0 -21
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/jsonReviver.d.ts +0 -15
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/needsReviver.d.ts +0 -11
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/parseJsonBody.d.ts +0 -22
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/JsonSettings.d.ts +0 -4
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/codec-v1/JsonCodec.d.ts +0 -11
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/codec-v1/JsonSettings.d.ts +0 -4
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/codec-v1/JsonShapeDeserializer.d.ts +0 -13
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/codec-v1/JsonShapeSerializer.d.ts +0 -18
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/codec-v2/JsonBytesStringAdapter.d.ts +0 -27
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/codec-v2/JsonCodec2.d.ts +0 -9
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/codec-v2/JsonShapeDeserializer2.d.ts +0 -15
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/codec-v2/JsonShapeSerializer2.d.ts +0 -39
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/detectBufferParsing.d.ts +0 -1
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/jsonReplacer.d.ts +0 -7
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/jsonReviver.d.ts +0 -7
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/needsReviver.d.ts +0 -2
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/parseJsonBody.d.ts +0 -14
- /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;
|
|
@@ -578,6 +589,7 @@ function schemaLogFilter(schema, data) {
|
|
|
578
589
|
return data;
|
|
579
590
|
}
|
|
580
591
|
|
|
592
|
+
const operationEventStreamMarker = Symbol.for("@smithy/op-event-stream");
|
|
581
593
|
class Command {
|
|
582
594
|
middlewareStack = constructStack();
|
|
583
595
|
schema;
|
|
@@ -603,6 +615,7 @@ class Command {
|
|
|
603
615
|
commandInstance: this,
|
|
604
616
|
...smithyContext,
|
|
605
617
|
...(options?.metricsRecorder === undefined ? {} : { metricsRecorder: options.metricsRecorder }),
|
|
618
|
+
...(options?.abortSignal === undefined ? {} : { abortSignal: options.abortSignal }),
|
|
606
619
|
},
|
|
607
620
|
};
|
|
608
621
|
const { requestHandler } = configuration;
|
|
@@ -611,9 +624,21 @@ class Command {
|
|
|
611
624
|
requestOptions = { ...requestOptions };
|
|
612
625
|
delete requestOptions.metricsRecorder;
|
|
613
626
|
}
|
|
614
|
-
|
|
627
|
+
let isEventStream;
|
|
628
|
+
const schema = this.schema;
|
|
629
|
+
const marker = schema?.[operationEventStreamMarker];
|
|
630
|
+
if (marker !== undefined) {
|
|
631
|
+
isEventStream = marker;
|
|
632
|
+
}
|
|
633
|
+
else if (schema) {
|
|
634
|
+
if (Array.isArray(schema) && schema[0] === 9) {
|
|
635
|
+
const [, , , , input$, output$] = schema;
|
|
636
|
+
isEventStream = schema[operationEventStreamMarker] = Boolean(NormalizedSchema.of(input$).getEventStreamMember() || NormalizedSchema.of(output$).getEventStreamMember());
|
|
637
|
+
}
|
|
638
|
+
}
|
|
639
|
+
if (isEventStream) {
|
|
615
640
|
requestOptions = {
|
|
616
|
-
isEventStream
|
|
641
|
+
isEventStream,
|
|
617
642
|
...requestOptions,
|
|
618
643
|
};
|
|
619
644
|
}
|
|
@@ -724,8 +749,9 @@ const createAggregatedClient = (commands, Client, options) => {
|
|
|
724
749
|
this.send(command, optionsOrCb);
|
|
725
750
|
}
|
|
726
751
|
else if (typeof cb === "function") {
|
|
727
|
-
if (typeof optionsOrCb !== "object")
|
|
752
|
+
if (typeof optionsOrCb !== "object") {
|
|
728
753
|
throw new Error(`Expected http options but got ${typeof optionsOrCb}`);
|
|
754
|
+
}
|
|
729
755
|
this.send(command, optionsOrCb || {}, cb);
|
|
730
756
|
}
|
|
731
757
|
else {
|
|
@@ -778,8 +804,9 @@ class ServiceException extends Error {
|
|
|
778
804
|
this.$metadata = options.$metadata;
|
|
779
805
|
}
|
|
780
806
|
static isInstance(value) {
|
|
781
|
-
if (!value)
|
|
807
|
+
if (!value) {
|
|
782
808
|
return false;
|
|
809
|
+
}
|
|
783
810
|
const candidate = value;
|
|
784
811
|
return (ServiceException.prototype.isPrototypeOf(candidate) ||
|
|
785
812
|
(Boolean(candidate.$fault) &&
|
|
@@ -787,8 +814,9 @@ class ServiceException extends Error {
|
|
|
787
814
|
(candidate.$fault === "client" || candidate.$fault === "server")));
|
|
788
815
|
}
|
|
789
816
|
static [Symbol.hasInstance](instance) {
|
|
790
|
-
if (!instance)
|
|
817
|
+
if (!instance) {
|
|
791
818
|
return false;
|
|
819
|
+
}
|
|
792
820
|
const candidate = instance;
|
|
793
821
|
if (this === ServiceException) {
|
|
794
822
|
return ServiceException.isInstance(instance);
|
|
@@ -912,8 +940,9 @@ const knownAlgorithms = Object.values(AlgorithmId);
|
|
|
912
940
|
const getChecksumConfiguration = (runtimeConfig) => {
|
|
913
941
|
const checksumAlgorithms = [];
|
|
914
942
|
for (const id in AlgorithmId) {
|
|
915
|
-
if (!hasOwn(AlgorithmId, id))
|
|
943
|
+
if (!hasOwn(AlgorithmId, id)) {
|
|
916
944
|
continue;
|
|
945
|
+
}
|
|
917
946
|
const algorithmId = AlgorithmId[id];
|
|
918
947
|
if (runtimeConfig[algorithmId] === undefined) {
|
|
919
948
|
continue;
|
|
@@ -987,8 +1016,9 @@ const getArrayIfSingleItem = (mayBeArray) => Array.isArray(mayBeArray) ? mayBeAr
|
|
|
987
1016
|
const getValueFromTextNode = (obj) => {
|
|
988
1017
|
const textNodeName = "#text";
|
|
989
1018
|
for (const key in obj) {
|
|
990
|
-
if (!hasOwn(obj, key))
|
|
1019
|
+
if (!hasOwn(obj, key)) {
|
|
991
1020
|
continue;
|
|
1021
|
+
}
|
|
992
1022
|
if (obj[key][textNodeName] !== undefined) {
|
|
993
1023
|
obj[key] = obj[key][textNodeName];
|
|
994
1024
|
}
|
|
@@ -1031,8 +1061,9 @@ function map(arg0, arg1, arg2) {
|
|
|
1031
1061
|
}
|
|
1032
1062
|
}
|
|
1033
1063
|
for (const key in instructions) {
|
|
1034
|
-
if (!hasOwn(instructions, key))
|
|
1064
|
+
if (!hasOwn(instructions, key)) {
|
|
1035
1065
|
continue;
|
|
1066
|
+
}
|
|
1036
1067
|
if (!Array.isArray(instructions[key])) {
|
|
1037
1068
|
target[key] = instructions[key];
|
|
1038
1069
|
continue;
|
|
@@ -1051,8 +1082,9 @@ const convertMap = (target) => {
|
|
|
1051
1082
|
const take = (source, instructions) => {
|
|
1052
1083
|
const out = {};
|
|
1053
1084
|
for (const key in instructions) {
|
|
1054
|
-
if (!hasOwn(instructions, key))
|
|
1085
|
+
if (!hasOwn(instructions, key)) {
|
|
1055
1086
|
continue;
|
|
1087
|
+
}
|
|
1056
1088
|
applyInstruction(out, source, instructions, key);
|
|
1057
1089
|
}
|
|
1058
1090
|
return out;
|
|
@@ -1133,8 +1165,9 @@ const _json = (obj) => {
|
|
|
1133
1165
|
if (typeof obj === "object") {
|
|
1134
1166
|
const target = {};
|
|
1135
1167
|
for (const key in obj) {
|
|
1136
|
-
if (!hasOwn(obj, key))
|
|
1168
|
+
if (!hasOwn(obj, key)) {
|
|
1137
1169
|
continue;
|
|
1170
|
+
}
|
|
1138
1171
|
if (obj[key] == null) {
|
|
1139
1172
|
continue;
|
|
1140
1173
|
}
|
|
@@ -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,9 +58,13 @@ 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);
|
|
65
|
+
if (bytes.byteLength > 255) {
|
|
66
|
+
throw new Error(`@smithy/core/event-streams - header name exceeds 255 bytes: ${bytes.byteLength}`);
|
|
67
|
+
}
|
|
63
68
|
chunks.push(Uint8Array.from([bytes.byteLength]), bytes, this.formatHeaderValue(headers[headerName]));
|
|
64
69
|
}
|
|
65
70
|
const out = new Uint8Array(chunks.reduce((carry, bytes) => carry + bytes.byteLength, 0));
|
|
@@ -92,6 +97,9 @@ class HeaderMarshaller {
|
|
|
92
97
|
longBytes.set(header.value.bytes, 1);
|
|
93
98
|
return longBytes;
|
|
94
99
|
case "binary":
|
|
100
|
+
if (header.value.byteLength > MAX_HEADER_VALUE_BYTES) {
|
|
101
|
+
throw new Error(`@smithy/core/event-streams - header value (binary) exceeds ${MAX_HEADER_VALUE_BYTES} bytes: ${header.value.byteLength}`);
|
|
102
|
+
}
|
|
95
103
|
const binView = new DataView(new ArrayBuffer(3 + header.value.byteLength));
|
|
96
104
|
binView.setUint8(0, 6);
|
|
97
105
|
binView.setUint16(1, header.value.byteLength, false);
|
|
@@ -100,6 +108,9 @@ class HeaderMarshaller {
|
|
|
100
108
|
return binBytes;
|
|
101
109
|
case "string":
|
|
102
110
|
const utf8Bytes = this.fromUtf8(header.value);
|
|
111
|
+
if (utf8Bytes.byteLength > MAX_HEADER_VALUE_BYTES) {
|
|
112
|
+
throw new Error(`@smithy/core/event-streams - header value (string) exceeds ${MAX_HEADER_VALUE_BYTES} bytes: ${utf8Bytes.byteLength}`);
|
|
113
|
+
}
|
|
103
114
|
const strView = new DataView(new ArrayBuffer(3 + utf8Bytes.byteLength));
|
|
104
115
|
strView.setUint8(0, 7);
|
|
105
116
|
strView.setUint16(1, utf8Bytes.byteLength, false);
|
|
@@ -231,6 +242,7 @@ const STRING_TAG = "string";
|
|
|
231
242
|
const TIMESTAMP_TAG = "timestamp";
|
|
232
243
|
const UUID_TAG = "uuid";
|
|
233
244
|
const UUID_PATTERN = /^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/;
|
|
245
|
+
const MAX_HEADER_VALUE_BYTES = 32767;
|
|
234
246
|
|
|
235
247
|
const PRELUDE_MEMBER_LENGTH = 4;
|
|
236
248
|
const PRELUDE_LENGTH = PRELUDE_MEMBER_LENGTH * 2;
|
|
@@ -374,8 +386,9 @@ class SmithyMessageDecoderStream {
|
|
|
374
386
|
async *asyncIterator() {
|
|
375
387
|
for await (const message of this.options.messageStream) {
|
|
376
388
|
const deserialized = await this.options.deserializer(message);
|
|
377
|
-
if (deserialized === undefined)
|
|
389
|
+
if (deserialized === undefined) {
|
|
378
390
|
continue;
|
|
391
|
+
}
|
|
379
392
|
yield deserialized;
|
|
380
393
|
}
|
|
381
394
|
}
|
|
@@ -471,8 +484,9 @@ function getUnmarshalledStream(source, options) {
|
|
|
471
484
|
for await (const chunk of source) {
|
|
472
485
|
const message = options.eventStreamCodec.decode(chunk);
|
|
473
486
|
const type = await messageUnmarshaller(message);
|
|
474
|
-
if (type === undefined)
|
|
487
|
+
if (type === undefined) {
|
|
475
488
|
continue;
|
|
489
|
+
}
|
|
476
490
|
yield type;
|
|
477
491
|
}
|
|
478
492
|
},
|
|
@@ -502,8 +516,9 @@ function getMessageUnmarshaller(deserializer, toUtf8) {
|
|
|
502
516
|
[message.headers[":event-type"].value]: message,
|
|
503
517
|
};
|
|
504
518
|
const deserialized = await deserializer(event);
|
|
505
|
-
if (deserialized.$unknown)
|
|
519
|
+
if (deserialized.$unknown) {
|
|
506
520
|
return;
|
|
521
|
+
}
|
|
507
522
|
return deserialized;
|
|
508
523
|
}
|
|
509
524
|
else {
|
|
@@ -542,8 +557,9 @@ const readableStreamToIterable = (readableStream) => ({
|
|
|
542
557
|
try {
|
|
543
558
|
while (true) {
|
|
544
559
|
const { done, value } = await reader.read();
|
|
545
|
-
if (done)
|
|
560
|
+
if (done) {
|
|
546
561
|
return;
|
|
562
|
+
}
|
|
547
563
|
yield value;
|
|
548
564
|
}
|
|
549
565
|
}
|
|
@@ -641,8 +657,9 @@ class EventStreamSerde {
|
|
|
641
657
|
}
|
|
642
658
|
let unionMember = "";
|
|
643
659
|
for (const key in event) {
|
|
644
|
-
if (!hasOwn(event, key))
|
|
660
|
+
if (!hasOwn(event, key)) {
|
|
645
661
|
continue;
|
|
662
|
+
}
|
|
646
663
|
if (key !== "__type") {
|
|
647
664
|
unionMember = key;
|
|
648
665
|
break;
|
|
@@ -670,8 +687,9 @@ class EventStreamSerde {
|
|
|
670
687
|
const asyncIterable = marshaller.deserialize(response.body, async (event) => {
|
|
671
688
|
let unionMember = "";
|
|
672
689
|
for (const key in event) {
|
|
673
|
-
if (!hasOwn(event, key))
|
|
690
|
+
if (!hasOwn(event, key)) {
|
|
674
691
|
continue;
|
|
692
|
+
}
|
|
675
693
|
if (key !== "__type") {
|
|
676
694
|
unionMember = key;
|
|
677
695
|
break;
|
|
@@ -746,8 +764,9 @@ class EventStreamSerde {
|
|
|
746
764
|
throw new Error("@smithy::core/protocols - initial-response event encountered in event stream but no response schema given.");
|
|
747
765
|
}
|
|
748
766
|
for (const key in firstEvent.value) {
|
|
749
|
-
if (!hasOwn(firstEvent.value, key))
|
|
767
|
+
if (!hasOwn(firstEvent.value, key)) {
|
|
750
768
|
continue;
|
|
769
|
+
}
|
|
751
770
|
initialResponseContainer[key] = firstEvent.value[key];
|
|
752
771
|
}
|
|
753
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,9 +59,13 @@ 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);
|
|
66
|
+
if (bytes.byteLength > 255) {
|
|
67
|
+
throw new Error(`@smithy/core/event-streams - header name exceeds 255 bytes: ${bytes.byteLength}`);
|
|
68
|
+
}
|
|
64
69
|
chunks.push(Uint8Array.from([bytes.byteLength]), bytes, this.formatHeaderValue(headers[headerName]));
|
|
65
70
|
}
|
|
66
71
|
const out = new Uint8Array(chunks.reduce((carry, bytes) => carry + bytes.byteLength, 0));
|
|
@@ -93,6 +98,9 @@ class HeaderMarshaller {
|
|
|
93
98
|
longBytes.set(header.value.bytes, 1);
|
|
94
99
|
return longBytes;
|
|
95
100
|
case "binary":
|
|
101
|
+
if (header.value.byteLength > MAX_HEADER_VALUE_BYTES) {
|
|
102
|
+
throw new Error(`@smithy/core/event-streams - header value (binary) exceeds ${MAX_HEADER_VALUE_BYTES} bytes: ${header.value.byteLength}`);
|
|
103
|
+
}
|
|
96
104
|
const binView = new DataView(new ArrayBuffer(3 + header.value.byteLength));
|
|
97
105
|
binView.setUint8(0, 6);
|
|
98
106
|
binView.setUint16(1, header.value.byteLength, false);
|
|
@@ -101,6 +109,9 @@ class HeaderMarshaller {
|
|
|
101
109
|
return binBytes;
|
|
102
110
|
case "string":
|
|
103
111
|
const utf8Bytes = this.fromUtf8(header.value);
|
|
112
|
+
if (utf8Bytes.byteLength > MAX_HEADER_VALUE_BYTES) {
|
|
113
|
+
throw new Error(`@smithy/core/event-streams - header value (string) exceeds ${MAX_HEADER_VALUE_BYTES} bytes: ${utf8Bytes.byteLength}`);
|
|
114
|
+
}
|
|
104
115
|
const strView = new DataView(new ArrayBuffer(3 + utf8Bytes.byteLength));
|
|
105
116
|
strView.setUint8(0, 7);
|
|
106
117
|
strView.setUint16(1, utf8Bytes.byteLength, false);
|
|
@@ -232,6 +243,7 @@ const STRING_TAG = "string";
|
|
|
232
243
|
const TIMESTAMP_TAG = "timestamp";
|
|
233
244
|
const UUID_TAG = "uuid";
|
|
234
245
|
const UUID_PATTERN = /^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/;
|
|
246
|
+
const MAX_HEADER_VALUE_BYTES = 32767;
|
|
235
247
|
|
|
236
248
|
const PRELUDE_MEMBER_LENGTH = 4;
|
|
237
249
|
const PRELUDE_LENGTH = PRELUDE_MEMBER_LENGTH * 2;
|
|
@@ -375,8 +387,9 @@ class SmithyMessageDecoderStream {
|
|
|
375
387
|
async *asyncIterator() {
|
|
376
388
|
for await (const message of this.options.messageStream) {
|
|
377
389
|
const deserialized = await this.options.deserializer(message);
|
|
378
|
-
if (deserialized === undefined)
|
|
390
|
+
if (deserialized === undefined) {
|
|
379
391
|
continue;
|
|
392
|
+
}
|
|
380
393
|
yield deserialized;
|
|
381
394
|
}
|
|
382
395
|
}
|
|
@@ -472,8 +485,9 @@ function getUnmarshalledStream(source, options) {
|
|
|
472
485
|
for await (const chunk of source) {
|
|
473
486
|
const message = options.eventStreamCodec.decode(chunk);
|
|
474
487
|
const type = await messageUnmarshaller(message);
|
|
475
|
-
if (type === undefined)
|
|
488
|
+
if (type === undefined) {
|
|
476
489
|
continue;
|
|
490
|
+
}
|
|
477
491
|
yield type;
|
|
478
492
|
}
|
|
479
493
|
},
|
|
@@ -503,8 +517,9 @@ function getMessageUnmarshaller(deserializer, toUtf8) {
|
|
|
503
517
|
[message.headers[":event-type"].value]: message,
|
|
504
518
|
};
|
|
505
519
|
const deserialized = await deserializer(event);
|
|
506
|
-
if (deserialized.$unknown)
|
|
520
|
+
if (deserialized.$unknown) {
|
|
507
521
|
return;
|
|
522
|
+
}
|
|
508
523
|
return deserialized;
|
|
509
524
|
}
|
|
510
525
|
else {
|
|
@@ -587,8 +602,9 @@ const readableStreamToIterable = (readableStream) => ({
|
|
|
587
602
|
try {
|
|
588
603
|
while (true) {
|
|
589
604
|
const { done, value } = await reader.read();
|
|
590
|
-
if (done)
|
|
605
|
+
if (done) {
|
|
591
606
|
return;
|
|
607
|
+
}
|
|
592
608
|
yield value;
|
|
593
609
|
}
|
|
594
610
|
}
|
|
@@ -666,8 +682,9 @@ class EventStreamSerde {
|
|
|
666
682
|
}
|
|
667
683
|
let unionMember = "";
|
|
668
684
|
for (const key in event) {
|
|
669
|
-
if (!hasOwn(event, key))
|
|
685
|
+
if (!hasOwn(event, key)) {
|
|
670
686
|
continue;
|
|
687
|
+
}
|
|
671
688
|
if (key !== "__type") {
|
|
672
689
|
unionMember = key;
|
|
673
690
|
break;
|
|
@@ -695,8 +712,9 @@ class EventStreamSerde {
|
|
|
695
712
|
const asyncIterable = marshaller.deserialize(response.body, async (event) => {
|
|
696
713
|
let unionMember = "";
|
|
697
714
|
for (const key in event) {
|
|
698
|
-
if (!hasOwn(event, key))
|
|
715
|
+
if (!hasOwn(event, key)) {
|
|
699
716
|
continue;
|
|
717
|
+
}
|
|
700
718
|
if (key !== "__type") {
|
|
701
719
|
unionMember = key;
|
|
702
720
|
break;
|
|
@@ -771,8 +789,9 @@ class EventStreamSerde {
|
|
|
771
789
|
throw new Error("@smithy::core/protocols - initial-response event encountered in event stream but no response schema given.");
|
|
772
790
|
}
|
|
773
791
|
for (const key in firstEvent.value) {
|
|
774
|
-
if (!hasOwn(firstEvent.value, key))
|
|
792
|
+
if (!hasOwn(firstEvent.value, key)) {
|
|
775
793
|
continue;
|
|
794
|
+
}
|
|
776
795
|
initialResponseContainer[key] = firstEvent.value[key];
|
|
777
796
|
}
|
|
778
797
|
}
|