diff --git a/.viperlightignore b/.viperlightignore index 3853c5642..b1b7fba4a 100644 --- a/.viperlightignore +++ b/.viperlightignore @@ -4,19 +4,11 @@ coverage/ node_modules/ deployment/publishing/nuget/publish.sh:43 deployment/publishing/nuget/publish.sh:44 -source/use_cases/aws-serverless-web-app/test/integ.backend-deployment.expected.json:180 -source/patterns/@aws-solutions-constructs/aws-apigateway-lambda/test/integ.apilam-deployFunction.expected.json:172 -source/patterns/@aws-solutions-constructs/aws-apigateway-lambda/test/integ.apilam-existingFunction.expected.json:172 -source/patterns/@aws-solutions-constructs/aws-cloudfront-apigateway/test/integ.cftapi-no-arguments.expected.json:172 -source/patterns/@aws-solutions-constructs/aws-apigateway-dynamodb/test/integ.apiddb-apigateway-dynamodb-existing-table.expected.json:60 CODE_OF_CONDUCT.md:4 CONTRIBUTING.md:244 SECURITY.md:2 source/patterns/@aws-solutions-constructs/core/test/step-function-helper.test.ts:107 source/patterns/@aws-solutions-constructs/aws-kinesisstreams-gluejob/test/test.kinesisstream-gluejob.test.ts:126 -source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunction.expected.json:112 -source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-existingFunction.expected.json:112 -source/patterns/@aws-solutions-constructs/aws-apigateway-sqs/test/integ.apisqs-apigateway-sqs-crud.expected.json:201 source/tools/cdk-integ-tools/package-lock.json:373 source/patterns/@aws-solutions-constructs/core/test/step-function-helper.test.js:115 source/patterns/@aws-solutions-constructs/core/test/lambda-helper.test.ts:233 @@ -35,79 +27,13 @@ source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/eventbridge-s source/patterns/@aws-solutions-constructs/aws-dynamodb-stream-lambda/test/dynamodb-stream-lambda.test.ts:103 source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-lambda/test/dynamodbstreams-lambda.test.ts:103 source/patterns/@aws-solutions-constructs/aws-apigateway-iot/README.md:39 -source/patterns/@aws-solutions-constructs/aws-apigateway-iot/test/integ.apiiot-defaultParams.expected.json:266 -source/patterns/@aws-solutions-constructs/aws-apigateway-iot/test/integ.apiiot-overrideParams.expected.json:269 source/patterns/@aws-solutions-constructs/aws-apigateway-iot/test/test.apigateway-iot.test.ts:29 -source/patterns/@aws-solutions-constructs/aws-apigateway-iot/test/integ.apiiot-override_auth_api_keys.expected.json:267 source/patterns/@aws-solutions-constructs/core/test/cloudfront-distribution-s3-helper.test.ts:487 source/patterns/@aws-solutions-constructs/aws-cloudfront-s3/test/test.cloudfront-s3.test.ts:214 source/patterns/@aws-solutions-constructs/aws-s3-sqs/test/test.s3-sqs.test.ts:251 source/use_cases/aws-custom-glue-etl/stream-producer/generate_data.py:86 source/use_cases/aws-custom-glue-etl/stream-producer/generate_data.py:87 source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/lambda-secretsmanager.test.ts:460 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:6 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:9 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:12 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:15 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:18 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:21 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:24 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:27 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:30 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:33 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:36 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:39 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:42 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:45 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:48 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:51 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:54 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:57 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:60 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:63 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-deployFunction.expected.json:66 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:500 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:503 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:506 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:509 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:512 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:515 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:518 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:521 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:524 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:527 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:530 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:533 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:536 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:539 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:542 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:545 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:548 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:551 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:554 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:557 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingFunction.expected.json:560 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:6 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:9 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:12 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:15 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:18 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:21 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:24 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:27 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:30 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:33 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:36 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:39 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:42 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:45 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:48 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:51 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:54 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:57 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:60 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:63 -source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/integ.lamsag-existingSageMakerEndpoint.expected.json:66 source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/test-helper.ts:24 source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/test-helper.ts:27 source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/test-helper.ts:30 @@ -129,43 +55,24 @@ source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/test source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/test-helper.ts:78 source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/test-helper.ts:81 source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/test/test-helper.ts:84 -source/patterns/@aws-solutions-constructs/aws-s3-lambda/test/integ.s3lam-existing-s3-bucket.expected.json:33 -source/patterns/@aws-solutions-constructs/aws-wafwebacl-apigateway/test/integ.wafapi-wafwebacl-apigateway-iot.expected.json:265 -source/patterns/@aws-solutions-constructs/aws-wafwebacl-apigateway/test/integ.wafapi-existing-waf-to-multiple-gateways.expected.json:814 # This is a test case source/patterns/@aws-solutions-constructs/aws-kinesisstreams-gluejob/test/test.kinesisstream-gluejob.test.ts:127 # aws-lambda-eventbridge. Auto generated Ids are ignored & x-ray resource permission with a `*` in test cases is ignored -source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunction.expected.json:122 -source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.expected.json:149 -source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.expected.json:163 -source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-existingEventBus.expected.json:108 -source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-existingFunction.expected.json:122 source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/aws-lambda-eventbridge.test.ts:28 source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/aws-lambda-eventbridge.test.ts:339 source/patterns/@aws-solutions-constructs/aws-alb-lambda/README.md:35 source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/alb-lambda.test.ts:27 source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/alb-lambda.test.ts:680 # These are references to the us-east-1 ELBV2 account (publicly known) -source/patterns/@aws-solutions-constructs/aws-route53-alb/test/integ.r53alb-deployPrivateApi.expected.json:229 -source/patterns/@aws-solutions-constructs/aws-route53-alb/test/integ.r53alb-deployPrivateApiExistingZone.expected.json:898 -source/patterns/@aws-solutions-constructs/aws-route53-alb/test/integ.r53alb-deployPublicApiNewAlb.expected.json:227 -source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/integ.alblam-privateApiNewResources.expected.json:232 -source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/integ.alblam-publicApiNewResources.expected.json:238 -source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/integ.alblam-twoTargets.expected.json:238 -source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/integ.alblam-privateApiExistingResources.expected.json:1126 -source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/integ.alblam-publicApiExistingResources.expected.json:1126 -source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.expected.json:1078 -source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.expected.json:1051 -source/patterns/@aws-solutions-constructs/aws-route53-alb/test/integ.r53alb-deployPublicApiNewAlb.expected.json:237 source/patterns/@aws-solutions-constructs/aws-alb-fargate/README.md:79 source/patterns/@aws-solutions-constructs/aws-alb-lambda/README.md:85 source/patterns/@aws-solutions-constructs/aws-route53-alb/README.md:60 source/patterns/@aws-solutions-constructs/aws-wafwebacl-alb/README.md:68 # ELB Log Reporting Account Incidents -source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.template.json:1022 -source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/tree.json:1335 -source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.template.json:1049 -source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/tree.json:1380 +source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.template.json:1040 +source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/tree.json:1353 +source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.template.json:1067 +source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/tree.json:1398 source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/integ.alblam-privateApiExistingResources.js.snapshot/alblam-privateApiExistingResources.template.json:1095 source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/integ.alblam-privateApiExistingResources.js.snapshot/tree.json:1400 source/patterns/@aws-solutions-constructs/aws-alb-lambda/test/integ.alblam-privateApiNewResources.js.snapshot/alblam-privateApiNewResources.template.json:221 diff --git a/CHANGELOG.md b/CHANGELOG.md index 363671e0c..3a24d0d04 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,17 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +## [2.77.0](https://github.com/awslabs/aws-solutions-constructs/compare/v2.76.0...v2.77.0) (2025-01-31) + +Build on CDK v2.177.0 + +### Bug Fixes +* **aws-lamba-kendra:** address index issues ([#1248](https://github.com/awslabs/aws-solutions-constructs/pull/1248)) + +### Features + +* **aww-eventbridge-sqs:** add a dlq for the event rule ([#1253](https://github.com/awslabs/aws-solutions-constructs/issues/1253)) ([0db79b3](https://github.com/awslabs/aws-solutions-constructs/commit/0db79b3df7634ca866f7f2939e7012cd035905da)) + ## [2.76.0](https://github.com/awslabs/aws-solutions-constructs/compare/v2.75.0...v2.76.0) (2024-12-24) Built on CDK v2.173.2 diff --git a/deployment/v2/align-version.js b/deployment/v2/align-version.js index 54ee45e08..83f1a8eed 100755 --- a/deployment/v2/align-version.js +++ b/deployment/v2/align-version.js @@ -10,7 +10,7 @@ const nullVersionMarker = process.argv[2]; const targetSolutionsConstructsVersion = process.argv[3]; // these versions need to be sourced from a config file -const awsCdkLibVersion = '2.173.2'; +const awsCdkLibVersion = '2.177.0'; for (const file of process.argv.splice(4)) { const pkg = JSON.parse(fs.readFileSync(file).toString()); diff --git a/source/lerna.json b/source/lerna.json index 38e9e4c76..9bb1985ff 100644 --- a/source/lerna.json +++ b/source/lerna.json @@ -5,5 +5,5 @@ "patterns/@aws-solutions-constructs/*" ], "rejectCycles": "true", - "version": "2.76.0" + "version": "2.77.0" } diff --git a/source/package.json b/source/package.json index ba1ce1251..0c7e3b762 100644 --- a/source/package.json +++ b/source/package.json @@ -23,9 +23,9 @@ "fs-extra": "^8.1.0", "typescript": "4.7.4", "jest": "^27.4.0", - "jsii": "~5.4.26", - "jsii-rosetta": "~5.4.25", - "jsii-pacmak": "^1.92.0", + "jsii": "~5.7.4", + "jsii-rosetta": "5.7.2", + "jsii-pacmak": "^1.106.0", "tslint": "^5.20.1", "lerna": "8.1.8", "eslint": "^6.8.0", diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/package.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/package.json index eb68f351f..c7d0fb4fb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfar-all-existing-private-http.assets.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfar-all-existing-private-http.assets.json index a302dc47f..9b4998e74 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfar-all-existing-private-http.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfar-all-existing-private-http.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "fe3c2e10f51dcf0161644b408a64a35da94b177ad7a04b79e063f8fe9612deb2": { + "ac06508104637bc961aef57c989e203b353c13d1ae92e5d85df94c4736103629": { "source": { "path": "albfar-all-existing-private-http.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "fe3c2e10f51dcf0161644b408a64a35da94b177ad7a04b79e063f8fe9612deb2.json", + "objectKey": "ac06508104637bc961aef57c989e203b353c13d1ae92e5d85df94c4736103629.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfar-all-existing-private-http.template.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfar-all-existing-private-http.template.json index abe13c50c..3f178a2e4 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfar-all-existing-private-http.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfar-all-existing-private-http.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "albfar-all-existing-private-http/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "albfar-all-existing-private-http/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "albfar-all-existing-private-http/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -709,7 +727,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfarallexistingprivatehttpIntegDefaultTestDeployAssert3019D243.assets.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfarallexistingprivatehttpIntegDefaultTestDeployAssert3019D243.assets.json index 9f40d483b..066bc2f93 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfarallexistingprivatehttpIntegDefaultTestDeployAssert3019D243.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/albfarallexistingprivatehttpIntegDefaultTestDeployAssert3019D243.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/integ.json index 4fc567954..a5d85f125 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "albfar-all-existing-private-http/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/manifest.json index 942954f2c..7f8c54628 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "albfarallexistingprivatehttpIntegDefaultTestDeployAssert3019D243.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/fe3c2e10f51dcf0161644b408a64a35da94b177ad7a04b79e063f8fe9612deb2.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/ac06508104637bc961aef57c989e203b353c13d1ae92e5d85df94c4736103629.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -268,6 +268,12 @@ "data": "VpcS3A5408339" } ], + "/albfar-all-existing-private-http/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/albfar-all-existing-private-http/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/tree.json index 618428a85..c9a20edef 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-existing-private-http.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "albfar-all-existing-private-http/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "albfar-all-existing-private-http/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "albfar-all-existing-private-http/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "albfar-all-existing-private-http/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "albfar-all-existing-private-http/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "albfar-all-existing-private-http/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "albfar-all-existing-private-http/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "albfar-all-existing-private-http/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "albfar-all-existing-private-http/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,19 +996,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1002,7 +1020,7 @@ "path": "albfar-all-existing-private-http/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1010,7 +1028,7 @@ "path": "albfar-all-existing-private-http/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1018,13 +1036,13 @@ "path": "albfar-all-existing-private-http/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "albfar-all-existing-private-http-ECR_API-security-group": { @@ -1080,13 +1098,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "albfar-all-existing-private-http-ECR_DKR-security-group": { @@ -1142,13 +1160,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1164,13 +1182,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1186,7 +1204,7 @@ "path": "albfar-all-existing-private-http/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1211,13 +1229,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1257,7 +1275,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1265,13 +1283,13 @@ "path": "albfar-all-existing-private-http/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1299,7 +1317,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "from albfarallexistingprivatehttptestalbSecurityGroupAC4D388D:8080": { @@ -1328,13 +1346,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroupIngress", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1396,13 +1414,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-alb": { @@ -1443,7 +1461,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnLoadBalancer", - "version": "2.150.0" + "version": "2.174.0" } }, "SecurityGroup": { @@ -1473,7 +1491,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "to albfarallexistingprivatehttptestsgD60B2013:8080": { @@ -1502,19 +1520,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroupEgress", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationLoadBalancer", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1548,19 +1566,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnListener", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-alb-fargate.AlbToFargate", - "version": "2.63.0" + "version": "2.76.0" } }, "test-construct-target-tg": { @@ -1591,13 +1609,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnTargetGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1613,7 +1631,7 @@ "path": "albfar-all-existing-private-http/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1625,7 +1643,7 @@ "path": "albfar-all-existing-private-http/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1633,25 +1651,25 @@ "path": "albfar-all-existing-private-http/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1659,7 +1677,7 @@ "path": "albfar-all-existing-private-http/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1667,13 +1685,13 @@ "path": "albfar-all-existing-private-http/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1681,13 +1699,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.assets.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.assets.json index e0e79ebb4..a87e371af 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } @@ -29,7 +29,7 @@ } } }, - "52e66f8f7e2932d1b3c6534b5f3c26f7f008952ad1692748ee46f1d18d960260": { + "cffffb9405636d715f40e955965c38c0a176961ae1a4ec88b2e9a76ac091090e": { "source": { "path": "albfar-all-new-public-http.template.json", "packaging": "file" @@ -37,7 +37,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "52e66f8f7e2932d1b3c6534b5f3c26f7f008952ad1692748ee46f1d18d960260.json", + "objectKey": "cffffb9405636d715f40e955965c38c0a176961ae1a4ec88b2e9a76ac091090e.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.template.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.template.json index 5656c6daf..538573cba 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfar-all-new-public-http.template.json @@ -604,6 +604,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "albfar-all-new-public-http/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -631,6 +637,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "albfar-all-new-public-http/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -666,6 +678,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "albfar-all-new-public-http/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -745,7 +763,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfarallnewpublichttpIntegDefaultTestDeployAssert3D1DD975.assets.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfarallnewpublichttpIntegDefaultTestDeployAssert3D1DD975.assets.json index 725f47c3b..3b329ec4c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfarallnewpublichttpIntegDefaultTestDeployAssert3D1DD975.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/albfarallnewpublichttpIntegDefaultTestDeployAssert3D1DD975.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/integ.json index 0dbed261e..b03891501 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "albfar-all-new-public-http/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/manifest.json index fad68fe71..abedf8b81 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "albfarallnewpublichttpIntegDefaultTestDeployAssert3D1DD975.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/52e66f8f7e2932d1b3c6534b5f3c26f7f008952ad1692748ee46f1d18d960260.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/cffffb9405636d715f40e955965c38c0a176961ae1a4ec88b2e9a76ac091090e.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -274,6 +274,12 @@ "data": "VpcS3A5408339" } ], + "/albfar-all-new-public-http/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/albfar-all-new-public-http/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -322,6 +328,12 @@ "data": "testconstructlbAutoDeleteObjectsCustomResource581A2B9F" } ], + "/albfar-all-new-public-http/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/albfar-all-new-public-http/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/tree.json index ffa682a02..22c01b1c0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-public-http.js.snapshot/tree.json @@ -39,19 +39,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnListener", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-alb-fargate.AlbToFargate", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -78,7 +78,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -122,7 +122,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -130,7 +130,7 @@ "path": "albfar-all-new-public-http/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -152,7 +152,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -171,7 +171,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -191,7 +191,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -211,7 +211,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -239,13 +239,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -289,7 +289,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -297,7 +297,7 @@ "path": "albfar-all-new-public-http/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -319,7 +319,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -338,7 +338,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -358,7 +358,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -378,7 +378,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -406,13 +406,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -456,7 +456,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -464,7 +464,7 @@ "path": "albfar-all-new-public-http/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -486,7 +486,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -505,7 +505,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -525,13 +525,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -575,7 +575,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -583,7 +583,7 @@ "path": "albfar-all-new-public-http/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -605,7 +605,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -624,7 +624,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -644,13 +644,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -669,7 +669,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -688,7 +688,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -700,13 +700,13 @@ "path": "albfar-all-new-public-http/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -722,7 +722,7 @@ "path": "albfar-all-new-public-http/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -753,7 +753,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -805,19 +805,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -841,13 +841,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -881,13 +881,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -900,6 +900,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "albfar-all-new-public-http/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -926,13 +932,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -945,6 +951,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "albfar-all-new-public-http/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -971,13 +983,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -990,6 +1002,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "albfar-all-new-public-http/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1024,19 +1042,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1048,7 +1066,7 @@ "path": "albfar-all-new-public-http/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1056,7 +1074,7 @@ "path": "albfar-all-new-public-http/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1064,13 +1082,13 @@ "path": "albfar-all-new-public-http/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-lb-alb": { @@ -1125,7 +1143,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnLoadBalancer", - "version": "2.150.0" + "version": "2.174.0" } }, "SecurityGroup": { @@ -1155,7 +1173,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "to albfarallnewpublichttptestconstructsg1860422C:8080": { @@ -1184,19 +1202,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroupEgress", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationLoadBalancer", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-lb": { @@ -1237,7 +1255,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -1403,13 +1421,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -1421,19 +1439,19 @@ "path": "albfar-all-new-public-http/test-construct-lb/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -1445,7 +1463,7 @@ "path": "albfar-all-new-public-http/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1453,7 +1471,7 @@ "path": "albfar-all-new-public-http/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1461,13 +1479,13 @@ "path": "albfar-all-new-public-http/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "albfar-all-new-public-http-ECR_API-security-group": { @@ -1523,13 +1541,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "albfar-all-new-public-http-ECR_DKR-security-group": { @@ -1585,13 +1603,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1607,13 +1625,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1629,7 +1647,7 @@ "path": "albfar-all-new-public-http/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1654,13 +1672,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1700,7 +1718,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -1708,13 +1726,13 @@ "path": "albfar-all-new-public-http/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -1742,7 +1760,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "from albfarallnewpublichttptestconstructlbalbSecurityGroupBF68816E:8080": { @@ -1771,13 +1789,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroupIngress", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -1839,13 +1857,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-target-tg": { @@ -1876,13 +1894,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnTargetGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1898,7 +1916,7 @@ "path": "albfar-all-new-public-http/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1910,7 +1928,7 @@ "path": "albfar-all-new-public-http/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1918,25 +1936,25 @@ "path": "albfar-all-new-public-http/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1944,7 +1962,7 @@ "path": "albfar-all-new-public-http/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1952,13 +1970,13 @@ "path": "albfar-all-new-public-http/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1966,13 +1984,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.assets.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.assets.json index 3b5547294..2b6e0c7c9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } @@ -29,7 +29,7 @@ } } }, - "5407fb5a37421f2831fb59a5301c55998552ca1bf8780add41b22973698d571c": { + "9663c27d097fea0abdb82dd91d35a4f81a2370025cf40941fd6d355ae57e6c75": { "source": { "path": "albfar-all-new-two-targets.template.json", "packaging": "file" @@ -37,7 +37,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "5407fb5a37421f2831fb59a5301c55998552ca1bf8780add41b22973698d571c.json", + "objectKey": "9663c27d097fea0abdb82dd91d35a4f81a2370025cf40941fd6d355ae57e6c75.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.template.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.template.json index 240de0607..ceae7c5f5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfar-all-new-two-targets.template.json @@ -631,6 +631,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "albfar-all-new-two-targets/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -658,6 +664,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "albfar-all-new-two-targets/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -693,6 +705,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "albfar-all-new-two-targets/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -772,7 +790,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfarallnewtwotargetsIntegDefaultTestDeployAssertF83A32E4.assets.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfarallnewtwotargetsIntegDefaultTestDeployAssertF83A32E4.assets.json index b4f042012..501380fec 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfarallnewtwotargetsIntegDefaultTestDeployAssertF83A32E4.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/albfarallnewtwotargetsIntegDefaultTestDeployAssertF83A32E4.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/integ.json index 6cebb4806..1e831a9fa 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "albfar-all-new-two-targets/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/manifest.json index a232ff068..9c7e1baff 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "albfarallnewtwotargetsIntegDefaultTestDeployAssertF83A32E4.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/5407fb5a37421f2831fb59a5301c55998552ca1bf8780add41b22973698d571c.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/9663c27d097fea0abdb82dd91d35a4f81a2370025cf40941fd6d355ae57e6c75.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -280,6 +280,12 @@ "data": "VpcS3A5408339" } ], + "/albfar-all-new-two-targets/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/albfar-all-new-two-targets/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -328,6 +334,12 @@ "data": "testconstructlbAutoDeleteObjectsCustomResource581A2B9F" } ], + "/albfar-all-new-two-targets/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/albfar-all-new-two-targets/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/tree.json index 9ac9dc14e..73afc8bf9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-fargate/test/integ.albfar-all-new-two-targets.js.snapshot/tree.json @@ -39,7 +39,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnListener", - "version": "2.150.0" + "version": "2.174.0" } }, "albfar-all-new-two-targets-targetsRule": { @@ -78,25 +78,25 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnListenerRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListenerRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-alb-fargate.AlbToFargate", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -123,7 +123,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -167,7 +167,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -175,7 +175,7 @@ "path": "albfar-all-new-two-targets/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -197,7 +197,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -216,7 +216,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -236,7 +236,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -256,7 +256,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -284,13 +284,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -334,7 +334,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -342,7 +342,7 @@ "path": "albfar-all-new-two-targets/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -364,7 +364,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -383,7 +383,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -403,7 +403,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -423,7 +423,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -451,13 +451,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -501,7 +501,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -509,7 +509,7 @@ "path": "albfar-all-new-two-targets/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -531,7 +531,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -550,7 +550,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -570,13 +570,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -620,7 +620,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -628,7 +628,7 @@ "path": "albfar-all-new-two-targets/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -650,7 +650,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -669,7 +669,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -689,13 +689,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -714,7 +714,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -733,7 +733,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -745,13 +745,13 @@ "path": "albfar-all-new-two-targets/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -767,7 +767,7 @@ "path": "albfar-all-new-two-targets/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -798,7 +798,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -850,19 +850,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -886,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -926,13 +926,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -945,6 +945,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "albfar-all-new-two-targets/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -971,13 +977,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -990,6 +996,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "albfar-all-new-two-targets/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1016,13 +1028,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1035,6 +1047,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "albfar-all-new-two-targets/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1069,19 +1087,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1093,7 +1111,7 @@ "path": "albfar-all-new-two-targets/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1101,7 +1119,7 @@ "path": "albfar-all-new-two-targets/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1109,13 +1127,13 @@ "path": "albfar-all-new-two-targets/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-lb-alb": { @@ -1170,7 +1188,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnLoadBalancer", - "version": "2.150.0" + "version": "2.174.0" } }, "SecurityGroup": { @@ -1200,7 +1218,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "to albfarallnewtwotargetstestconstructsg36F92324:8080": { @@ -1229,19 +1247,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroupEgress", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationLoadBalancer", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-lb": { @@ -1282,7 +1300,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -1448,13 +1466,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -1466,19 +1484,19 @@ "path": "albfar-all-new-two-targets/test-construct-lb/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -1490,7 +1508,7 @@ "path": "albfar-all-new-two-targets/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1498,7 +1516,7 @@ "path": "albfar-all-new-two-targets/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1506,13 +1524,13 @@ "path": "albfar-all-new-two-targets/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "albfar-all-new-two-targets-ECR_API-security-group": { @@ -1568,13 +1586,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "albfar-all-new-two-targets-ECR_DKR-security-group": { @@ -1630,13 +1648,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1652,13 +1670,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1674,7 +1692,7 @@ "path": "albfar-all-new-two-targets/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1699,13 +1717,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1745,7 +1763,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -1753,13 +1771,13 @@ "path": "albfar-all-new-two-targets/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -1787,7 +1805,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "from albfarallnewtwotargetstestconstructlbalbSecurityGroup07EB9DFC:8080": { @@ -1816,13 +1834,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroupIngress", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -1891,13 +1909,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-target-tg": { @@ -1928,13 +1946,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnTargetGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-two-construct": { @@ -1942,7 +1960,7 @@ "path": "albfar-all-new-two-targets/test-two-construct", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-alb-fargate.AlbToFargate", - "version": "2.63.0" + "version": "2.76.0" } }, "test-two-construct-target-tg": { @@ -1973,13 +1991,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnTargetGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1995,7 +2013,7 @@ "path": "albfar-all-new-two-targets/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -2007,7 +2025,7 @@ "path": "albfar-all-new-two-targets/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2015,25 +2033,25 @@ "path": "albfar-all-new-two-targets/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2041,7 +2059,7 @@ "path": "albfar-all-new-two-targets/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2049,13 +2067,13 @@ "path": "albfar-all-new-two-targets/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2063,13 +2081,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-alb-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-alb-lambda/package.json index 8dac4b174..5a4bfceb7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-alb-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-alb-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-apigateway-dynamodb/package.json b/source/patterns/@aws-solutions-constructs/aws-apigateway-dynamodb/package.json index 1e7bf6c7b..67ce1c044 100644 --- a/source/patterns/@aws-solutions-constructs/aws-apigateway-dynamodb/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-apigateway-dynamodb/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-apigateway-iot/README.md b/source/patterns/@aws-solutions-constructs/aws-apigateway-iot/README.md index de65e6499..6bfa128e1 100755 --- a/source/patterns/@aws-solutions-constructs/aws-apigateway-iot/README.md +++ b/source/patterns/@aws-solutions-constructs/aws-apigateway-iot/README.md @@ -99,13 +99,13 @@ Out of the box implementation of the Construct without any override will set the * Enable X-Ray Tracing * Creates a UsagePlan and associates to `prod` stage -Below is a description of the different resources and methods exposed by the API Gateway after deploying the Construct. See the [Examples](#examples) section for more information on how to easily test these endpoints using `curl`. +Below is a description of the different resources and methods exposed by the API Gateway after deploying the Construct. |Method | Resource | Query parameter(s) | Return code(s) | Description| |-------------- | --------------------- | ------------------ | ----------------- | -----------------| | **POST** | `/message/` | **qos** | `200/403/500` | By calling this endpoint, you need to pass the topics on which you would like to publish (e.g `/message/device/foo`).| -| **POST** | `/shadow/` | **None** | `200/403/500` | This route allows to update the shadow document of a thing, given its `thingName` using Unnamed (classic) shadow type. The body shall comply with the standard shadow structure comprising a `state` node and associated `desired` and `reported` nodes. See the [Updating device shadows](#updating-device-shadows) section for an example.| -| **POST** | `/shadow//` | **None** | `200/403/500` | This route allows to update the named shadow document of a thing, given its `thingName` and the `shadowName` using the Named shadow type. The body shall comply with the standard shadow structure comprising a `state` node and associated `desired` and `reported` nodes. See the [Updating named shadows](#updating-named-shadows) section for an example.| +| **POST** | `/shadow/` | **None** | `200/403/500` | This route allows to update the shadow document of a thing, given its `thingName` using Unnamed (classic) shadow type. The body shall comply with the standard shadow structure comprising a `state` node and associated `desired` and `reported` nodes.| +| **POST** | `/shadow//` | **None** | `200/403/500` | This route allows to update the named shadow document of a thing, given its `thingName` and the `shadowName` using the Named shadow type. The body shall comply with the standard shadow structure comprising a `state` node and associated `desired` and `reported` nodes.| ## Architecture diff --git a/source/patterns/@aws-solutions-constructs/aws-apigateway-iot/package.json b/source/patterns/@aws-solutions-constructs/aws-apigateway-iot/package.json index 03ddad8ec..ed08c930f 100755 --- a/source/patterns/@aws-solutions-constructs/aws-apigateway-iot/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-apigateway-iot/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-apigateway-kinesisstreams/package.json b/source/patterns/@aws-solutions-constructs/aws-apigateway-kinesisstreams/package.json index 44593918e..63263cd56 100644 --- a/source/patterns/@aws-solutions-constructs/aws-apigateway-kinesisstreams/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-apigateway-kinesisstreams/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-apigateway-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-apigateway-lambda/package.json index 34ef5e348..8a6fd14a2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-apigateway-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-apigateway-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-apigateway-sagemakerendpoint/package.json b/source/patterns/@aws-solutions-constructs/aws-apigateway-sagemakerendpoint/package.json index b08b32d92..d86dc535d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-apigateway-sagemakerendpoint/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-apigateway-sagemakerendpoint/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-apigateway-sqs/package.json b/source/patterns/@aws-solutions-constructs/aws-apigateway-sqs/package.json index 36262a5c3..d839f84c2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-apigateway-sqs/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-apigateway-sqs/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-apigatewayv2websocket-sqs/package.json b/source/patterns/@aws-solutions-constructs/aws-apigatewayv2websocket-sqs/package.json index 8d0daffc4..3bf0d74e8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-apigatewayv2websocket-sqs/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-apigatewayv2websocket-sqs/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-cloudfront-apigateway-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-cloudfront-apigateway-lambda/package.json index d956dd7d7..21cd4a57c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-cloudfront-apigateway-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-cloudfront-apigateway-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-cloudfront-apigateway/package.json b/source/patterns/@aws-solutions-constructs/aws-cloudfront-apigateway/package.json index dceec1376..40ba31483 100644 --- a/source/patterns/@aws-solutions-constructs/aws-cloudfront-apigateway/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-cloudfront-apigateway/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-cloudfront-mediastore/package.json b/source/patterns/@aws-solutions-constructs/aws-cloudfront-mediastore/package.json index a573b8035..f3432d2f1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-cloudfront-mediastore/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-cloudfront-mediastore/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-cloudfront-s3/package.json b/source/patterns/@aws-solutions-constructs/aws-cloudfront-s3/package.json index fddba573e..4717002bd 100644 --- a/source/patterns/@aws-solutions-constructs/aws-cloudfront-s3/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-cloudfront-s3/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-cognito-apigateway-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-cognito-apigateway-lambda/package.json index 56738ff07..89a530d4d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-cognito-apigateway-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-cognito-apigateway-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-constructs-factories/package.json b/source/patterns/@aws-solutions-constructs/aws-constructs-factories/package.json index 630b43861..a82f0d015 100644 --- a/source/patterns/@aws-solutions-constructs/aws-constructs-factories/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-constructs-factories/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-lambda-elasticsearch-kibana/package.json b/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-lambda-elasticsearch-kibana/package.json index dd04d71a8..1b026ec8f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-lambda-elasticsearch-kibana/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-lambda-elasticsearch-kibana/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-lambda/package.json index c23d86d52..3ee654599 100644 --- a/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-pipes-stepfunctions/package.json b/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-pipes-stepfunctions/package.json index 41472b507..970b044a5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-pipes-stepfunctions/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-dynamodbstreams-pipes-stepfunctions/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-kinesisfirehose-s3/package.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-kinesisfirehose-s3/package.json index 48c368b8e..9325beab9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-kinesisfirehose-s3/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-kinesisfirehose-s3/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-kinesisstreams/package.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-kinesisstreams/package.json index de5737b5f..6bcc5cecb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-kinesisstreams/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-kinesisstreams/package.json @@ -17,6 +17,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "repository": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-lambda/package.json index 0c83a0e84..7563f2eb4 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sns/package.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sns/package.json index d6fdae438..9b647748d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sns/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sns/package.json @@ -17,6 +17,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "repository": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/README.md b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/README.md index bc5fee60d..8b9cc21e3 100755 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/README.md +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/README.md @@ -115,6 +115,9 @@ constructStack.getEncryptionKey().addToResourcePolicy(policyStatement); |existingEventBusInterface?|[`events.IEventBus`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events.IEventBus.html)| Optional user-provided custom EventBus for construct to use. Providing both this and `eventBusProps` results an error.| |eventBusProps?|[`events.EventBusProps`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events.EventBusProps.html)|Optional user-provided properties to override the default properties when creating a custom EventBus. Setting this value to `{}` will create a custom EventBus using all default properties. If neither this nor `existingEventBusInterface` is provided the construct will use the `default` EventBus. Providing both this and `existingEventBusInterface` results an error.| |eventRuleProps|[`events.RuleProps`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events.RuleProps.html)|User provided eventRuleProps to override the defaults. | +|targetProps?|[`eventtargets.SqsQueueProps`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events_targets.SqsQueueProps.html)|Optional user provided properties to define the SQS target on the Event Rule. If you specify a deadLetterQueue for the rule here, you are responsible for adding a resource policy to the queue allowing events.amazonaws.com permission to SendMessage, GetQueueUrl and GetQueueAttributes. You cannot send a DLQ in this property and set deployEventRuleDlq to true. Default is undefined and all system defaults are used.| +|eventRuleDlqKeyProps|[kms.KeyProps](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_kms.KeyProps.html)|Optional properties to define the key created to protect the ruleDlq. Only valid if deployRuleDlq is set to true. Defaults to CloudFormation defaults.| +| deployEventRuleDlq?|boolean|Whether to deploy a DLQ for the Event Rule. If set to `true`, this DLQ will receive any messages that can't be delivered to the target SQS queue. Defaults to `false`.| |existingQueueObj?|[`sqs.Queue`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_sqs.Queue.html)|An optional, existing SQS queue to be used instead of the default queue. Providing both this and `queueProps` will cause an error.| |queueProps?|[`sqs.QueueProps`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_sqs.QueueProps.html)|User provided props to override the default props for the SQS Queue. | |enableQueuePurging?|`boolean`|Whether to grant additional permissions to the Lambda function enabling it to purge the SQS queue. Defaults to `false`.| @@ -131,6 +134,8 @@ constructStack.getEncryptionKey().addToResourcePolicy(policyStatement); |:-------------|:----------------|-----------------| |eventBus?|[`events.IEventBus`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events.IEventBus.html)|Returns the instance of events.IEventBus used by the construct| |eventsRule|[`events.Rule`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events.Rule.html)|Returns an instance of events.Rule created by the construct| +|eventRuleDlq?|`sqs.Queue`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_sqs.Queue.html)|If the client sets deployEventRuleDlq to 'true', then this value will contain the DLQ set up for the rule.| +|eventRuleDlqKey|[kms.IKey](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_kms.IKey.html)|The key created to encrypt the eventRuleDlq.| |sqsQueue|[`sqs.Queue`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_sqs.Queue.html)|Returns an instance of sqs.Queue created by the construct| |encryptionKey?|[`kms.Key`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_kms.Key.html)|Returns an instance of kms Key used for the SQS queue.| |deadLetterQueue?|[`sqs.Queue`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_sqs.Queue.html)|Returns an instance of the dead-letter SQS queue created by the pattern.| diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/lib/index.ts b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/lib/index.ts index 91cef2825..5b0fcfe81 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/lib/index.ts +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/lib/index.ts @@ -13,6 +13,7 @@ import * as sqs from 'aws-cdk-lib/aws-sqs'; import * as events from 'aws-cdk-lib/aws-events'; +import * as eventtargets from 'aws-cdk-lib/aws-events-targets'; import * as kms from 'aws-cdk-lib/aws-kms'; import * as defaults from '@aws-solutions-constructs/core'; import { ServicePrincipal } from 'aws-cdk-lib/aws-iam'; @@ -42,6 +43,20 @@ export interface EventbridgeToSqsProps { * @default - None */ readonly eventRuleProps: events.RuleProps; + /** + * Whether to deploy a DLQ for the Event Rule. If set to `true`, this DLQ will + * receive any messages that can't be delivered to the target SQS queue. + * + * @default - false + */ + readonly deployEventRuleDlq?: boolean; + /** + * Properties to define the key created to protect the ruleDlq + * Only valid if deployEventRuleDlq is set to true + * + * @default - default props are used + */ + readonly eventRuleDlqKeyProps?: kms.KeyProps; /** * Existing instance of SQS queue object, providing both this and queueProps will cause an error. * @@ -60,6 +75,16 @@ export interface EventbridgeToSqsProps { * @default - "false", disabled by default. */ readonly enableQueuePurging?: boolean; + /** + * Optional user provided properties to define the SQS target on the Event Rule + * + * If you specify a deadLetterQueue for the rule here, you are responsible for adding a resource policy + * to the queue allowing events.amazonaws.com permission to SendMessage, GetQueueUrl and GetQueueAttributes. You + * cannot send a DLQ in this property and set deployRuleDlq to true + * + * @default - undefined (all default values are used) + */ + readonly targetProps?: eventtargets.SqsQueueProps; /** * Optional user provided properties for the dead letter queue * @@ -105,6 +130,8 @@ export class EventbridgeToSqs extends Construct { public readonly eventBus?: events.IEventBus; public readonly eventsRule: events.Rule; public readonly encryptionKey?: kms.IKey; + public readonly eventRuleDlq?: sqs.Queue; + public readonly eventRuleDlqKey?: kms.IKey; /** * @summary Constructs a new instance of the EventbridgeToSqs class. @@ -118,6 +145,14 @@ export class EventbridgeToSqs extends Construct { super(scope, id); defaults.CheckSqsProps(props); defaults.CheckEventBridgeProps(props); + // SqsQueueProps does not implement any common interface, so is unique to this construct, + // so we will check it here rather than in core + if ((props.targetProps?.deadLetterQueue) && (props.deployEventRuleDlq)) { + throw new Error('Cannot specify both targetProps.deadLetterQueue and deployDeadLetterQueue == true\n'); + } + if (props.eventRuleDlqKeyProps && !props.deployEventRuleDlq) { + throw new Error('Cannot specify eventRuleDlqKeyProps without setting deployEventRuleDlq=true\n'); + } let enableEncryptionParam = props.enableEncryptionWithCustomerManagedKey; if (props.enableEncryptionWithCustomerManagedKey === undefined || @@ -140,12 +175,26 @@ export class EventbridgeToSqs extends Construct { this.encryptionKey = buildQueueResponse.key; this.deadLetterQueue = buildQueueResponse.dlq; - const sqsEventTarget: events.IRuleTarget = { - bind: () => ({ - id: this.sqsQueue.queueName, - arn: this.sqsQueue.queueArn - }) - }; + let constructEventTargetProps: eventtargets.SqsQueueProps = {}; + + if (defaults.CheckBooleanWithDefault(props.deployEventRuleDlq, false)) { + + const buildRuleDlqResponse = defaults.buildQueue(this, 'ruleDlq', { + deployDeadLetterQueue: false, + enableEncryptionWithCustomerManagedKey: enableEncryptionParam, + encryptionKeyProps: props.eventRuleDlqKeyProps + }); + + this.eventRuleDlq = buildRuleDlqResponse.queue; + const ruleDlqKey = buildRuleDlqResponse.key; + ruleDlqKey?.grantEncryptDecrypt(new ServicePrincipal('events.amazonaws.com')); + this.eventRuleDlqKey = ruleDlqKey; + + constructEventTargetProps = defaults.consolidateProps(constructEventTargetProps, { deadLetterQueue: this.eventRuleDlq }); + } + + const sqsEventTargetProps = defaults.consolidateProps({}, props.targetProps, constructEventTargetProps); + const sqsEventTarget = new eventtargets.SqsQueue(this.sqsQueue, sqsEventTargetProps); // build an event bus if existingEventBus is provided or eventBusProps are provided this.eventBus = defaults.buildEventBus(this, { @@ -163,7 +212,5 @@ export class EventbridgeToSqs extends Construct { this.sqsQueue.grantPurge(new ServicePrincipal('events.amazonaws.com')); } - // Policy for event to be able to send messages to the queue and Grant Event Bridge service access to the SQS queue encryption key - this.sqsQueue.grantSendMessages(new ServicePrincipal('events.amazonaws.com')); } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/package.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/package.json index 203565b0c..330d21b83 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/package.json @@ -17,6 +17,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "repository": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/eventbridge-sqs-queue.test.ts b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/eventbridge-sqs-queue.test.ts index 740f2c685..6582928f8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/eventbridge-sqs-queue.test.ts +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/eventbridge-sqs-queue.test.ts @@ -15,7 +15,7 @@ import * as cdk from 'aws-cdk-lib'; import { EventbridgeToSqs, EventbridgeToSqsProps } from '../lib'; import * as events from "aws-cdk-lib/aws-events"; import * as sqs from "aws-cdk-lib/aws-sqs"; -import { Template } from 'aws-cdk-lib/assertions'; +import { Match, Template } from 'aws-cdk-lib/assertions'; import * as defaults from '@aws-solutions-constructs/core'; function deployNewStack(stack: cdk.Stack) { @@ -495,7 +495,7 @@ test('Queue purging flag grants correct permissions', () => { }, { Action: [ - "sqs:PurgeQueue", + "sqs:SendMessage", "sqs:GetQueueAttributes", "sqs:GetQueueUrl" ], @@ -512,7 +512,7 @@ test('Queue purging flag grants correct permissions', () => { }, { Action: [ - "sqs:SendMessage", + "sqs:PurgeQueue", "sqs:GetQueueAttributes", "sqs:GetQueueUrl" ], @@ -559,3 +559,150 @@ test('check that CheckSqsProps is being called', () => { }; expect(app).toThrowError("Error - Either provide queueProps or existingQueueObj, but not both.\n"); }); + +test('Check that rule dlq is not created by default', () => { + const stack = new cdk.Stack(); + const props: EventbridgeToSqsProps = { + eventRuleProps: { + schedule: events.Schedule.rate(cdk.Duration.minutes(5)) + } + }; + const testConstruct = new EventbridgeToSqs(stack, 'test-eventbridge-sqs', props); + expect(testConstruct.eventRuleDlq).toBeUndefined(); + const template = Template.fromStack(stack); + template.resourceCountIs("AWS::SQS::Queue", 2); + template.hasResourceProperties("AWS::Events::Rule", { + Targets: [ + { + Id: "Target0", + DeadLetterConfig: Match.absent(), + } + ] + }); +}); + +test('Check that rule dlq is created when requested', () => { + const stack = new cdk.Stack(); + const props: EventbridgeToSqsProps = { + eventRuleProps: { + schedule: events.Schedule.rate(cdk.Duration.minutes(5)) + }, + deployEventRuleDlq: true + }; + const testConstruct = new EventbridgeToSqs(stack, 'test-eventbridge-sqs', props); + expect(testConstruct.eventRuleDlq).toBeDefined(); + const template = Template.fromStack(stack); + template.resourceCountIs("AWS::SQS::Queue", 3); + template.hasResourceProperties("AWS::Events::Rule", { + Targets: [ + { + Id: "Target0", + DeadLetterConfig: { + Arn: { + "Fn::GetAtt": [ + Match.stringLikeRegexp("testeventbridgesqsruleDlq.*"), + "Arn" + ] + } + }, + } + ] + }); +}); + +test('Check that rule dlq is created when requested', () => { + const testMaxAge = cdk.Duration.seconds(47); + const stack = new cdk.Stack(); + const props: EventbridgeToSqsProps = { + eventRuleProps: { + schedule: events.Schedule.rate(cdk.Duration.minutes(5)) + }, + targetProps: { + maxEventAge: testMaxAge + } + }; + new EventbridgeToSqs(stack, 'test-eventbridge-sqs', props); + const template = Template.fromStack(stack); + + template.hasResourceProperties("AWS::Events::Rule", { + Targets: [ + { + Id: "Target0", + RetryPolicy: { + MaximumEventAgeInSeconds: 47 + } + } + ] + }); +}); + +test('Check that client cannot submit their own Rule DLQ and ask for a DLQ to be created', () => { + // This may be enabled in the future, but first release + // is minimum viable product and takes full ownership of the Rule DLQ + const stack = new cdk.Stack(); + const props: EventbridgeToSqsProps = { + eventRuleProps: { + schedule: events.Schedule.rate(cdk.Duration.minutes(5)) + }, + deployEventRuleDlq: true, + targetProps: { + deadLetterQueue: {} as sqs.Queue + } + }; + const app = () => { + new EventbridgeToSqs(stack, 'test-eventbridge-sqs', props); + }; + expect(app).toThrowError('Cannot specify both targetProps.deadLetterQueue and deployDeadLetterQueue == true\n'); +}); + +test('Test that the construct uses provided eventRuleDlgKey properties', () => { + const stack = new cdk.Stack(); + const props: EventbridgeToSqsProps = { + eventRuleProps: { + schedule: events.Schedule.rate(cdk.Duration.minutes(5)) + }, + eventRuleDlqKeyProps: { + alias: 'test-alias' + }, + deployEventRuleDlq: true, + }; + new EventbridgeToSqs(stack, 'test-eventbridge-sqs', props); + const template = Template.fromStack(stack); + template.hasResourceProperties("AWS::KMS::Alias", { + AliasName: "alias/test-alias", + TargetKeyId: { + "Fn::GetAtt": [ + Match.stringLikeRegexp("testeventbridgesqsruleDlqKey.*"), + "Arn" + ] + } + }); +}); + +test('Thest that the eventRuleDlqKey is exposed as a property', () => { + const stack = new cdk.Stack(); + const props: EventbridgeToSqsProps = { + eventRuleProps: { + schedule: events.Schedule.rate(cdk.Duration.minutes(5)) + }, + deployEventRuleDlq: true, + }; + const testConstruct = new EventbridgeToSqs(stack, 'test-eventbridge-sqs', props); + expect(testConstruct.eventRuleDlqKey).toBeDefined(); +}); + +test('Test that an error is thrown when eventRuleDlqKeyProps are provided but deployEventRuleDlq is not true', () => { + const stack = new cdk.Stack(); + const props: EventbridgeToSqsProps = { + eventRuleProps: { + schedule: events.Schedule.rate(cdk.Duration.minutes(5)) + }, + eventRuleDlqKeyProps: { + alias: 'test-alias' + }, + }; + const app = () => { + new EventbridgeToSqs(stack, 'test-eventbridge-sqs', props); + }; + expect(app).toThrowError('Cannot specify eventRuleDlqKeyProps without setting deployEventRuleDlq=true\n'); +}); \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/cdk.out new file mode 100644 index 000000000..91e1a8b99 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/cdk.out @@ -0,0 +1 @@ +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqs-custom-target.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqs-custom-target.assets.json new file mode 100644 index 000000000..63596a690 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqs-custom-target.assets.json @@ -0,0 +1,19 @@ +{ + "version": "39.0.0", + "files": { + "8221310775997696fa75dec2375830f8d37a0d9d424ea6d55a03f453d4bec94c": { + "source": { + "path": "evtsqs-custom-target.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "8221310775997696fa75dec2375830f8d37a0d9d424ea6d55a03f453d4bec94c.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqs-custom-target.template.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqs-custom-target.template.json new file mode 100644 index 000000000..7ecc64a32 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqs-custom-target.template.json @@ -0,0 +1,312 @@ +{ + "Resources": { + "constructqueuedlq6B66D1E6": { + "Type": "AWS::SQS::Queue", + "Properties": { + "KmsMasterKeyId": "alias/aws/sqs" + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "constructqueuedlqPolicy3B6CC54E": { + "Type": "AWS::SQS::QueuePolicy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "Sid": "HttpsOnly" + } + ], + "Version": "2012-10-17" + }, + "Queues": [ + { + "Ref": "constructqueuedlq6B66D1E6" + } + ] + } + }, + "constructqueueKey0638E1FB": { + "Type": "AWS::KMS::Key", + "Properties": { + "EnableKeyRotation": true, + "KeyPolicy": { + "Statement": [ + { + "Action": "kms:*", + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": "*" + }, + { + "Action": [ + "kms:Decrypt", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": "*" + } + ], + "Version": "2012-10-17" + } + }, + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" + }, + "constructqueue481DC1EC": { + "Type": "AWS::SQS::Queue", + "Properties": { + "KmsMasterKeyId": { + "Fn::GetAtt": [ + "constructqueueKey0638E1FB", + "Arn" + ] + }, + "RedrivePolicy": { + "deadLetterTargetArn": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "maxReceiveCount": 15 + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "constructqueuePolicy5B0256B1": { + "Type": "AWS::SQS::QueuePolicy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "Sid": "HttpsOnly" + }, + { + "Action": [ + "sqs:GetQueueAttributes", + "sqs:GetQueueUrl", + "sqs:SendMessage" + ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "Queues": [ + { + "Ref": "constructqueue481DC1EC" + } + ] + } + }, + "constructEventsRule43880ADB": { + "Type": "AWS::Events::Rule", + "Properties": { + "ScheduleExpression": "rate(5 minutes)", + "State": "ENABLED", + "Targets": [ + { + "Arn": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "Id": "Target0", + "RetryPolicy": { + "MaximumEventAgeInSeconds": 3600, + "MaximumRetryAttempts": 2 + } + } + ] + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.assets.json new file mode 100644 index 000000000..c7d3ceeed --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.assets.json @@ -0,0 +1,19 @@ +{ + "version": "39.0.0", + "files": { + "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { + "source": { + "path": "evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.template.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.template.json new file mode 100644 index 000000000..ad9d0fb73 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.template.json @@ -0,0 +1,36 @@ +{ + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/integ.json new file mode 100644 index 000000000..6d45820dd --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/integ.json @@ -0,0 +1,12 @@ +{ + "version": "39.0.0", + "testCases": { + "evtsqs-custom-target/Integ/DefaultTest": { + "stacks": [ + "evtsqs-custom-target" + ], + "assertionStack": "evtsqs-custom-target/Integ/DefaultTest/DeployAssert", + "assertionStackName": "evtsqscustomtargetIntegDefaultTestDeployAssertD220243E" + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/manifest.json new file mode 100644 index 000000000..e634d1287 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/manifest.json @@ -0,0 +1,149 @@ +{ + "version": "39.0.0", + "artifacts": { + "evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "evtsqscustomtargetIntegDefaultTestDeployAssertD220243E": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.template.json", + "terminationProtection": false, + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "evtsqscustomtargetIntegDefaultTestDeployAssertD220243E.assets" + ], + "metadata": { + "/evtsqs-custom-target/Integ/DefaultTest/DeployAssert/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/evtsqs-custom-target/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "evtsqs-custom-target/Integ/DefaultTest/DeployAssert" + }, + "evtsqs-custom-target.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "evtsqs-custom-target.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "evtsqs-custom-target": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "evtsqs-custom-target.template.json", + "terminationProtection": false, + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/8221310775997696fa75dec2375830f8d37a0d9d424ea6d55a03f453d4bec94c.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "evtsqs-custom-target.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "evtsqs-custom-target.assets" + ], + "metadata": { + "/evtsqs-custom-target/construct/queue-dlq/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueuedlq6B66D1E6" + } + ], + "/evtsqs-custom-target/construct/queue-dlq/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueuedlqPolicy3B6CC54E" + } + ], + "/evtsqs-custom-target/construct/'queueKey'/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueueKey0638E1FB" + } + ], + "/evtsqs-custom-target/construct/queue": [ + { + "type": "aws:cdk:warning", + "data": "encryption: Automatically changed to QueueEncryption.KMS, was: QueueEncryption.KMS_MANAGED\nWhen encryptionMasterKey is provided, always set `encryption: QueueEncryption.KMS` [ack: @aws-cdk/aws-sqs:queueEncryptionChangedToKMS]" + } + ], + "/evtsqs-custom-target/construct/queue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueue481DC1EC" + } + ], + "/evtsqs-custom-target/construct/queue/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueuePolicy5B0256B1" + } + ], + "/evtsqs-custom-target/construct/EventsRule/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructEventsRule43880ADB" + } + ], + "/evtsqs-custom-target/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/evtsqs-custom-target/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "evtsqs-custom-target" + }, + "Tree": { + "type": "cdk:tree", + "properties": { + "file": "tree.json" + } + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/tree.json new file mode 100644 index 000000000..be20a6a31 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.js.snapshot/tree.json @@ -0,0 +1,487 @@ +{ + "version": "tree-0.1", + "tree": { + "id": "App", + "path": "", + "children": { + "evtsqs-custom-target": { + "id": "evtsqs-custom-target", + "path": "evtsqs-custom-target", + "children": { + "construct": { + "id": "construct", + "path": "evtsqs-custom-target/construct", + "children": { + "queue-dlq": { + "id": "queue-dlq", + "path": "evtsqs-custom-target/construct/queue-dlq", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-custom-target/construct/queue-dlq/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "kmsMasterKeyId": "alias/aws/sqs" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", + "version": "2.175.1" + } + }, + "Policy": { + "id": "Policy", + "path": "evtsqs-custom-target/construct/queue-dlq/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-custom-target/construct/queue-dlq/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::QueuePolicy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "Sid": "HttpsOnly" + } + ], + "Version": "2012-10-17" + }, + "queues": [ + { + "Ref": "constructqueuedlq6B66D1E6" + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.Queue", + "version": "2.175.1" + } + }, + "'queueKey'": { + "id": "'queueKey'", + "path": "evtsqs-custom-target/construct/'queueKey'", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-custom-target/construct/'queueKey'/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::KMS::Key", + "aws:cdk:cloudformation:props": { + "enableKeyRotation": true, + "keyPolicy": { + "Statement": [ + { + "Action": "kms:*", + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": "*" + }, + { + "Action": [ + "kms:Decrypt", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": "*" + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kms.CfnKey", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kms.Key", + "version": "2.175.1" + } + }, + "queue": { + "id": "queue", + "path": "evtsqs-custom-target/construct/queue", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-custom-target/construct/queue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "kmsMasterKeyId": { + "Fn::GetAtt": [ + "constructqueueKey0638E1FB", + "Arn" + ] + }, + "redrivePolicy": { + "deadLetterTargetArn": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "maxReceiveCount": 15 + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", + "version": "2.175.1" + } + }, + "Policy": { + "id": "Policy", + "path": "evtsqs-custom-target/construct/queue/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-custom-target/construct/queue/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::QueuePolicy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "Sid": "HttpsOnly" + }, + { + "Action": [ + "sqs:GetQueueAttributes", + "sqs:GetQueueUrl", + "sqs:SendMessage" + ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "queues": [ + { + "Ref": "constructqueue481DC1EC" + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.Queue", + "version": "2.175.1" + } + }, + "EventsRule": { + "id": "EventsRule", + "path": "evtsqs-custom-target/construct/EventsRule", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-custom-target/construct/EventsRule/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Events::Rule", + "aws:cdk:cloudformation:props": { + "scheduleExpression": "rate(5 minutes)", + "state": "ENABLED", + "targets": [ + { + "id": "Target0", + "arn": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "retryPolicy": { + "maximumRetryAttempts": 2, + "maximumEventAgeInSeconds": 3600 + } + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_events.CfnRule", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_events.Rule", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "@aws-solutions-constructs/aws-eventbridge-sqs.EventbridgeToSqs", + "version": "2.76.0" + } + }, + "Integ": { + "id": "Integ", + "path": "evtsqs-custom-target/Integ", + "children": { + "DefaultTest": { + "id": "DefaultTest", + "path": "evtsqs-custom-target/Integ/DefaultTest", + "children": { + "Default": { + "id": "Default", + "path": "evtsqs-custom-target/Integ/DefaultTest/Default", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.4.2" + } + }, + "DeployAssert": { + "id": "DeployAssert", + "path": "evtsqs-custom-target/Integ/DefaultTest/DeployAssert", + "children": { + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "evtsqs-custom-target/Integ/DefaultTest/DeployAssert/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "2.175.1" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "evtsqs-custom-target/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", + "version": "2.175.1-alpha.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", + "version": "2.175.1-alpha.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "evtsqs-custom-target/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "2.175.1" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "evtsqs-custom-target/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "2.175.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "2.175.1" + } + }, + "Tree": { + "id": "Tree", + "path": "Tree", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.4.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.App", + "version": "2.175.1" + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.ts b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.ts new file mode 100644 index 000000000..4cac1f2f2 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-custom-target.ts @@ -0,0 +1,37 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +import { Duration } from 'aws-cdk-lib'; +import { EventbridgeToSqsProps, EventbridgeToSqs } from '../lib'; +import * as events from 'aws-cdk-lib/aws-events'; +import { App, Stack } from 'aws-cdk-lib'; +import { generateIntegStackName } from '@aws-solutions-constructs/core'; +import { IntegTest } from '@aws-cdk/integ-tests-alpha'; + +const app = new App(); +const stack = new Stack(app, generateIntegStackName(__filename)); + +const props: EventbridgeToSqsProps = { + eventRuleProps: { + schedule: events.Schedule.rate(Duration.minutes(5)) + }, + targetProps: { + maxEventAge: Duration.hours(1), + retryAttempts: 2, + } +}; + +new EventbridgeToSqs(stack, 'construct', props); +new IntegTest(stack, 'Integ', { testCases: [ + stack +] }); diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqs-exist-bus.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqs-exist-bus.assets.json index f880b5c10..0621d16cb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqs-exist-bus.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqs-exist-bus.assets.json @@ -1,7 +1,7 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "7af5ea5f919ee11dba0f3d6b1c862aaeb33516536f0772e7558e77a6bf765846": { + "9acaa89ceee5e5b8ab6d77a48e9ba3aaa89df75c8f22ffdbeccaf7ef4ef6a3fd": { "source": { "path": "evtsqs-exist-bus.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "7af5ea5f919ee11dba0f3d6b1c862aaeb33516536f0772e7558e77a6bf765846.json", + "objectKey": "9acaa89ceee5e5b8ab6d77a48e9ba3aaa89df75c8f22ffdbeccaf7ef4ef6a3fd.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqs-exist-bus.template.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqs-exist-bus.template.json index 8ededeea2..d50b82aeb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqs-exist-bus.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqs-exist-bus.template.json @@ -36,6 +36,13 @@ "kms:GenerateDataKey*", "kms:ReEncrypt*" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -73,6 +80,13 @@ "sqs:GetQueueUrl", "sqs:SendMessage" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -120,12 +134,7 @@ "Arn" ] }, - "Id": { - "Fn::GetAtt": [ - "MyQueueE6CA6235", - "QueueName" - ] - } + "Id": "Target0" } ] } diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqsexistbusIntegDefaultTestDeployAssertD6166996.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqsexistbusIntegDefaultTestDeployAssertD6166996.assets.json index 9c468a598..ae3defb2a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqsexistbusIntegDefaultTestDeployAssertD6166996.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/evtsqsexistbusIntegDefaultTestDeployAssertD6166996.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/integ.json index 94d0fe401..4d0df763d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "evtsqs-exist-bus/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/manifest.json index e84d8803e..f117325a8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "evtsqsexistbusIntegDefaultTestDeployAssertD6166996.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/7af5ea5f919ee11dba0f3d6b1c862aaeb33516536f0772e7558e77a6bf765846.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/9acaa89ceee5e5b8ab6d77a48e9ba3aaa89df75c8f22ffdbeccaf7ef4ef6a3fd.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/tree.json index 564f0ddd7..433fab91c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-bus.js.snapshot/tree.json @@ -51,6 +51,13 @@ "kms:GenerateDataKey*", "kms:ReEncrypt*" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -64,13 +71,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kms.CfnKey", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kms.Key", - "version": "2.118.0" + "version": "2.175.1" } }, "MyQueue": { @@ -93,7 +100,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.118.0" + "version": "2.175.1" } }, "Policy": { @@ -114,6 +121,13 @@ "sqs:GetQueueUrl", "sqs:SendMessage" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -137,19 +151,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.118.0" + "version": "2.175.1" } }, "existing-event-bus": { @@ -167,13 +181,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.CfnEventBus", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.EventBus", - "version": "2.118.0" + "version": "2.175.1" } }, "construct": { @@ -201,12 +215,7 @@ "state": "ENABLED", "targets": [ { - "id": { - "Fn::GetAtt": [ - "MyQueueE6CA6235", - "QueueName" - ] - }, + "id": "Target0", "arn": { "Fn::GetAtt": [ "MyQueueE6CA6235", @@ -219,19 +228,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.CfnRule", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.Rule", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { - "fqn": "@aws-solutions-constructs/aws-eventbridge-sqs.EventbridgeToSqs", - "version": "2.50.0" + "fqn": "constructs.Construct", + "version": "10.4.2" } }, "Integ": { @@ -247,7 +256,7 @@ "path": "evtsqs-exist-bus/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.0.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -259,7 +268,7 @@ "path": "evtsqs-exist-bus/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.118.0" + "version": "2.175.1" } }, "CheckBootstrapVersion": { @@ -267,25 +276,25 @@ "path": "evtsqs-exist-bus/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.118.0-alpha.0" + "version": "2.175.1-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.118.0-alpha.0" + "version": "2.175.1-alpha.0" } }, "BootstrapVersion": { @@ -293,7 +302,7 @@ "path": "evtsqs-exist-bus/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.118.0" + "version": "2.175.1" } }, "CheckBootstrapVersion": { @@ -301,13 +310,13 @@ "path": "evtsqs-exist-bus/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.118.0" + "version": "2.175.1" } }, "Tree": { @@ -315,13 +324,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.0.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.118.0" + "version": "2.175.1" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqs-exist-queue.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqs-exist-queue.assets.json index 77e9bc21b..52574aa45 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqs-exist-queue.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqs-exist-queue.assets.json @@ -1,7 +1,7 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "2697c1685077d157ce278d357ebcc8c55dea9ffc2724999c41d2dc9e19d34488": { + "bb75e888bd5f0a0df7bf9ed3d576b15265d8f06c81dcf8f344d1a7e6f7aac889": { "source": { "path": "evtsqs-exist-queue.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "2697c1685077d157ce278d357ebcc8c55dea9ffc2724999c41d2dc9e19d34488.json", + "objectKey": "bb75e888bd5f0a0df7bf9ed3d576b15265d8f06c81dcf8f344d1a7e6f7aac889.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqs-exist-queue.template.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqs-exist-queue.template.json index c6570f5bc..e1482eb3a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqs-exist-queue.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqs-exist-queue.template.json @@ -36,6 +36,13 @@ "kms:GenerateDataKey*", "kms:ReEncrypt*" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -73,6 +80,13 @@ "sqs:GetQueueUrl", "sqs:SendMessage" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -107,12 +121,7 @@ "Arn" ] }, - "Id": { - "Fn::GetAtt": [ - "MyQueueE6CA6235", - "QueueName" - ] - } + "Id": "Target0" } ] } diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqsexistqueueIntegDefaultTestDeployAssert4E2D04AB.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqsexistqueueIntegDefaultTestDeployAssert4E2D04AB.assets.json index decd901ee..827cbb3e9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqsexistqueueIntegDefaultTestDeployAssert4E2D04AB.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/evtsqsexistqueueIntegDefaultTestDeployAssert4E2D04AB.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/integ.json index b06a3fcab..c1a5fd067 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "evtsqs-exist-queue/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/manifest.json index d9ee7dfa1..aefde9c97 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "evtsqsexistqueueIntegDefaultTestDeployAssert4E2D04AB.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/2697c1685077d157ce278d357ebcc8c55dea9ffc2724999c41d2dc9e19d34488.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/bb75e888bd5f0a0df7bf9ed3d576b15265d8f06c81dcf8f344d1a7e6f7aac889.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/tree.json index 401c25770..7239cd544 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-exist-queue.js.snapshot/tree.json @@ -51,6 +51,13 @@ "kms:GenerateDataKey*", "kms:ReEncrypt*" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -64,13 +71,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kms.CfnKey", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kms.Key", - "version": "2.118.0" + "version": "2.175.1" } }, "MyQueue": { @@ -93,7 +100,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.118.0" + "version": "2.175.1" } }, "Policy": { @@ -114,6 +121,13 @@ "sqs:GetQueueUrl", "sqs:SendMessage" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -137,19 +151,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.118.0" + "version": "2.175.1" } }, "construct": { @@ -170,12 +184,7 @@ "state": "ENABLED", "targets": [ { - "id": { - "Fn::GetAtt": [ - "MyQueueE6CA6235", - "QueueName" - ] - }, + "id": "Target0", "arn": { "Fn::GetAtt": [ "MyQueueE6CA6235", @@ -188,19 +197,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.CfnRule", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.Rule", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { - "fqn": "@aws-solutions-constructs/aws-eventbridge-sqs.EventbridgeToSqs", - "version": "2.50.0" + "fqn": "constructs.Construct", + "version": "10.4.2" } }, "Integ": { @@ -216,7 +225,7 @@ "path": "evtsqs-exist-queue/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.0.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -228,7 +237,7 @@ "path": "evtsqs-exist-queue/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.118.0" + "version": "2.175.1" } }, "CheckBootstrapVersion": { @@ -236,25 +245,25 @@ "path": "evtsqs-exist-queue/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.118.0-alpha.0" + "version": "2.175.1-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.118.0-alpha.0" + "version": "2.175.1-alpha.0" } }, "BootstrapVersion": { @@ -262,7 +271,7 @@ "path": "evtsqs-exist-queue/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.118.0" + "version": "2.175.1" } }, "CheckBootstrapVersion": { @@ -270,13 +279,13 @@ "path": "evtsqs-exist-queue/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.118.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.118.0" + "version": "2.175.1" } }, "Tree": { @@ -284,13 +293,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.0.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.118.0" + "version": "2.175.1" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqs-new-bus.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqs-new-bus.assets.json index 0825580df..d68c82c66 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqs-new-bus.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqs-new-bus.assets.json @@ -1,7 +1,7 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "a2a18c623e59a5226bac912a05f575bc9cb6154d1e56b7235749902bc64d8891": { + "27199aa6c7c08a4ce1c5f93749614c11dfbcaf1cf107c511259e8990949b1eef": { "source": { "path": "evtsqs-new-bus.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "a2a18c623e59a5226bac912a05f575bc9cb6154d1e56b7235749902bc64d8891.json", + "objectKey": "27199aa6c7c08a4ce1c5f93749614c11dfbcaf1cf107c511259e8990949b1eef.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqs-new-bus.template.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqs-new-bus.template.json index cfea356d1..88a9c9f79 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqs-new-bus.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqs-new-bus.template.json @@ -115,6 +115,13 @@ "kms:GenerateDataKey*", "kms:ReEncrypt*" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -217,6 +224,13 @@ "sqs:GetQueueUrl", "sqs:SendMessage" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -264,12 +278,7 @@ "Arn" ] }, - "Id": { - "Fn::GetAtt": [ - "constructqueue481DC1EC", - "QueueName" - ] - } + "Id": "Target0" } ] } diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqsnewbusIntegDefaultTestDeployAssertA45AD5F2.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqsnewbusIntegDefaultTestDeployAssertA45AD5F2.assets.json index cb47a70e8..5e6a34f9f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqsnewbusIntegDefaultTestDeployAssertA45AD5F2.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/evtsqsnewbusIntegDefaultTestDeployAssertA45AD5F2.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/integ.json index 9433a5711..cc17c43c1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "evtsqs-new-bus/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/manifest.json index de111df96..16c58898a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "evtsqsnewbusIntegDefaultTestDeployAssertA45AD5F2.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/a2a18c623e59a5226bac912a05f575bc9cb6154d1e56b7235749902bc64d8891.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/27199aa6c7c08a4ce1c5f93749614c11dfbcaf1cf107c511259e8990949b1eef.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -141,24 +141,6 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } - ], - "constructdeadLetterQueueD87A77D4": [ - { - "type": "aws:cdk:logicalId", - "data": "constructdeadLetterQueueD87A77D4", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] - } - ], - "constructdeadLetterQueuePolicyBA602BC6": [ - { - "type": "aws:cdk:logicalId", - "data": "constructdeadLetterQueuePolicyBA602BC6", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] - } ] }, "displayName": "evtsqs-new-bus" diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/tree.json index 0bd54b663..cb92a7c76 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-new-bus.js.snapshot/tree.json @@ -27,7 +27,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.143.0" + "version": "2.175.1" } }, "Policy": { @@ -110,19 +110,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.143.0" + "version": "2.175.1" } }, "'queueKey'": { @@ -168,6 +168,13 @@ "kms:GenerateDataKey*", "kms:ReEncrypt*" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -181,13 +188,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kms.CfnKey", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kms.Key", - "version": "2.143.0" + "version": "2.175.1" } }, "queue": { @@ -219,7 +226,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.143.0" + "version": "2.175.1" } }, "Policy": { @@ -296,6 +303,13 @@ "sqs:GetQueueUrl", "sqs:SendMessage" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -319,19 +333,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.143.0" + "version": "2.175.1" } }, "CustomEventBus": { @@ -349,13 +363,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.CfnEventBus", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.EventBus", - "version": "2.143.0" + "version": "2.175.1" } }, "EventsRule": { @@ -379,12 +393,7 @@ "state": "ENABLED", "targets": [ { - "id": { - "Fn::GetAtt": [ - "constructqueue481DC1EC", - "QueueName" - ] - }, + "id": "Target0", "arn": { "Fn::GetAtt": [ "constructqueue481DC1EC", @@ -397,19 +406,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.CfnRule", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.Rule", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { - "fqn": "@aws-solutions-constructs/aws-eventbridge-sqs.EventbridgeToSqs", - "version": "2.58.1" + "fqn": "constructs.Construct", + "version": "10.4.2" } }, "Integ": { @@ -425,7 +434,7 @@ "path": "evtsqs-new-bus/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -437,7 +446,7 @@ "path": "evtsqs-new-bus/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.143.0" + "version": "2.175.1" } }, "CheckBootstrapVersion": { @@ -445,25 +454,25 @@ "path": "evtsqs-new-bus/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.143.0-alpha.0" + "version": "2.175.1-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.143.0-alpha.0" + "version": "2.175.1-alpha.0" } }, "BootstrapVersion": { @@ -471,7 +480,7 @@ "path": "evtsqs-new-bus/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.143.0" + "version": "2.175.1" } }, "CheckBootstrapVersion": { @@ -479,13 +488,13 @@ "path": "evtsqs-new-bus/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.143.0" + "version": "2.175.1" } }, "Tree": { @@ -493,13 +502,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.143.0" + "version": "2.175.1" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqs-no-arg.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqs-no-arg.assets.json index 628574ce1..ba5722dec 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqs-no-arg.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqs-no-arg.assets.json @@ -1,7 +1,7 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "a6726326640c7e698b4f726d418cf48992aaa44d833e18e95076d704bd9a4b72": { + "1480529f284d8b8bbe89c4ff3d449121fde3bd303d6c6cba82dbb2fe4bc9667f": { "source": { "path": "evtsqs-no-arg.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "a6726326640c7e698b4f726d418cf48992aaa44d833e18e95076d704bd9a4b72.json", + "objectKey": "1480529f284d8b8bbe89c4ff3d449121fde3bd303d6c6cba82dbb2fe4bc9667f.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqs-no-arg.template.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqs-no-arg.template.json index 4eed0a180..e1812966d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqs-no-arg.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqs-no-arg.template.json @@ -115,6 +115,13 @@ "kms:GenerateDataKey*", "kms:ReEncrypt*" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -217,6 +224,13 @@ "sqs:GetQueueUrl", "sqs:SendMessage" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -251,12 +265,7 @@ "Arn" ] }, - "Id": { - "Fn::GetAtt": [ - "constructqueue481DC1EC", - "QueueName" - ] - } + "Id": "Target0" } ] } diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqsnoargIntegDefaultTestDeployAssertB5DFB718.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqsnoargIntegDefaultTestDeployAssertB5DFB718.assets.json index 246a54424..48e18caee 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqsnoargIntegDefaultTestDeployAssertB5DFB718.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/evtsqsnoargIntegDefaultTestDeployAssertB5DFB718.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/integ.json index dcecbc066..a8647ff14 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "evtsqs-no-arg/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/manifest.json index 13963d501..623a8b952 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "evtsqsnoargIntegDefaultTestDeployAssertB5DFB718.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/a6726326640c7e698b4f726d418cf48992aaa44d833e18e95076d704bd9a4b72.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/1480529f284d8b8bbe89c4ff3d449121fde3bd303d6c6cba82dbb2fe4bc9667f.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -135,24 +135,6 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } - ], - "constructdeadLetterQueueD87A77D4": [ - { - "type": "aws:cdk:logicalId", - "data": "constructdeadLetterQueueD87A77D4", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] - } - ], - "constructdeadLetterQueuePolicyBA602BC6": [ - { - "type": "aws:cdk:logicalId", - "data": "constructdeadLetterQueuePolicyBA602BC6", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] - } ] }, "displayName": "evtsqs-no-arg" diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/tree.json index 670103d90..87e275e6c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-no-arg.js.snapshot/tree.json @@ -27,7 +27,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.143.0" + "version": "2.175.1" } }, "Policy": { @@ -110,19 +110,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.143.0" + "version": "2.175.1" } }, "'queueKey'": { @@ -168,6 +168,13 @@ "kms:GenerateDataKey*", "kms:ReEncrypt*" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -181,13 +188,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kms.CfnKey", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kms.Key", - "version": "2.143.0" + "version": "2.175.1" } }, "queue": { @@ -219,7 +226,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.143.0" + "version": "2.175.1" } }, "Policy": { @@ -296,6 +303,13 @@ "sqs:GetQueueUrl", "sqs:SendMessage" ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, "Effect": "Allow", "Principal": { "Service": "events.amazonaws.com" @@ -319,19 +333,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.143.0" + "version": "2.175.1" } }, "EventsRule": { @@ -348,12 +362,7 @@ "state": "ENABLED", "targets": [ { - "id": { - "Fn::GetAtt": [ - "constructqueue481DC1EC", - "QueueName" - ] - }, + "id": "Target0", "arn": { "Fn::GetAtt": [ "constructqueue481DC1EC", @@ -366,19 +375,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.CfnRule", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.Rule", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { - "fqn": "@aws-solutions-constructs/aws-eventbridge-sqs.EventbridgeToSqs", - "version": "2.58.1" + "fqn": "constructs.Construct", + "version": "10.4.2" } }, "Integ": { @@ -394,7 +403,7 @@ "path": "evtsqs-no-arg/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -406,7 +415,7 @@ "path": "evtsqs-no-arg/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.143.0" + "version": "2.175.1" } }, "CheckBootstrapVersion": { @@ -414,25 +423,25 @@ "path": "evtsqs-no-arg/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.143.0-alpha.0" + "version": "2.175.1-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.143.0-alpha.0" + "version": "2.175.1-alpha.0" } }, "BootstrapVersion": { @@ -440,7 +449,7 @@ "path": "evtsqs-no-arg/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.143.0" + "version": "2.175.1" } }, "CheckBootstrapVersion": { @@ -448,13 +457,13 @@ "path": "evtsqs-no-arg/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.143.0" + "version": "2.175.1" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.143.0" + "version": "2.175.1" } }, "Tree": { @@ -462,13 +471,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.143.0" + "version": "2.175.1" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/cdk.out new file mode 100644 index 000000000..91e1a8b99 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/cdk.out @@ -0,0 +1 @@ +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqs-rule-dlq.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqs-rule-dlq.assets.json new file mode 100644 index 000000000..30290dc6e --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqs-rule-dlq.assets.json @@ -0,0 +1,19 @@ +{ + "version": "39.0.0", + "files": { + "1b987658e020bc5bb91c28188d302de48a98e534e39808f44580279068526530": { + "source": { + "path": "evtsqs-rule-dlq.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "1b987658e020bc5bb91c28188d302de48a98e534e39808f44580279068526530.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqs-rule-dlq.template.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqs-rule-dlq.template.json new file mode 100644 index 000000000..c5366bd3a --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqs-rule-dlq.template.json @@ -0,0 +1,485 @@ +{ + "Resources": { + "constructqueuedlq6B66D1E6": { + "Type": "AWS::SQS::Queue", + "Properties": { + "KmsMasterKeyId": "alias/aws/sqs" + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "constructqueuedlqPolicy3B6CC54E": { + "Type": "AWS::SQS::QueuePolicy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "Sid": "HttpsOnly" + } + ], + "Version": "2012-10-17" + }, + "Queues": [ + { + "Ref": "constructqueuedlq6B66D1E6" + } + ] + } + }, + "constructqueueKey0638E1FB": { + "Type": "AWS::KMS::Key", + "Properties": { + "EnableKeyRotation": true, + "KeyPolicy": { + "Statement": [ + { + "Action": "kms:*", + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": "*" + }, + { + "Action": [ + "kms:Decrypt", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": "*" + } + ], + "Version": "2012-10-17" + } + }, + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" + }, + "constructqueue481DC1EC": { + "Type": "AWS::SQS::Queue", + "Properties": { + "KmsMasterKeyId": { + "Fn::GetAtt": [ + "constructqueueKey0638E1FB", + "Arn" + ] + }, + "RedrivePolicy": { + "deadLetterTargetArn": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "maxReceiveCount": 15 + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "constructqueuePolicy5B0256B1": { + "Type": "AWS::SQS::QueuePolicy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "Sid": "HttpsOnly" + }, + { + "Action": [ + "sqs:GetQueueAttributes", + "sqs:GetQueueUrl", + "sqs:SendMessage" + ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "Queues": [ + { + "Ref": "constructqueue481DC1EC" + } + ] + } + }, + "constructruleDlqKey4F9EAB36": { + "Type": "AWS::KMS::Key", + "Properties": { + "EnableKeyRotation": true, + "KeyPolicy": { + "Statement": [ + { + "Action": "kms:*", + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": "*" + }, + { + "Action": [ + "kms:Decrypt", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": "*" + } + ], + "Version": "2012-10-17" + } + }, + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" + }, + "constructruleDlqKeyAliasF2A45A01": { + "Type": "AWS::KMS::Alias", + "Properties": { + "AliasName": "alias/test-alias", + "TargetKeyId": { + "Fn::GetAtt": [ + "constructruleDlqKey4F9EAB36", + "Arn" + ] + } + } + }, + "constructruleDlq7D359AE9": { + "Type": "AWS::SQS::Queue", + "Properties": { + "KmsMasterKeyId": { + "Fn::GetAtt": [ + "constructruleDlqKey4F9EAB36", + "Arn" + ] + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "constructruleDlqPolicyE4AB8569": { + "Type": "AWS::SQS::QueuePolicy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructruleDlq7D359AE9", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructruleDlq7D359AE9", + "Arn" + ] + }, + "Sid": "HttpsOnly" + }, + { + "Action": "sqs:SendMessage", + "Condition": { + "ArnEquals": { + "aws:SourceArn": { + "Fn::GetAtt": [ + "constructEventsRule43880ADB", + "Arn" + ] + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": { + "Fn::GetAtt": [ + "constructruleDlq7D359AE9", + "Arn" + ] + }, + "Sid": "AllowEventRuleevtsqsruledlqconstructEventsRule62503343" + } + ], + "Version": "2012-10-17" + }, + "Queues": [ + { + "Ref": "constructruleDlq7D359AE9" + } + ] + } + }, + "constructEventsRule43880ADB": { + "Type": "AWS::Events::Rule", + "Properties": { + "ScheduleExpression": "rate(1 minute)", + "State": "ENABLED", + "Targets": [ + { + "Arn": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "DeadLetterConfig": { + "Arn": { + "Fn::GetAtt": [ + "constructruleDlq7D359AE9", + "Arn" + ] + } + }, + "Id": "Target0" + } + ] + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.assets.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.assets.json new file mode 100644 index 000000000..ee51f74a8 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.assets.json @@ -0,0 +1,19 @@ +{ + "version": "39.0.0", + "files": { + "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { + "source": { + "path": "evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.template.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.template.json new file mode 100644 index 000000000..ad9d0fb73 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.template.json @@ -0,0 +1,36 @@ +{ + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/integ.json new file mode 100644 index 000000000..9c25cce83 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/integ.json @@ -0,0 +1,12 @@ +{ + "version": "39.0.0", + "testCases": { + "evtsqs-rule-dlq/Integ/DefaultTest": { + "stacks": [ + "evtsqs-rule-dlq" + ], + "assertionStack": "evtsqs-rule-dlq/Integ/DefaultTest/DeployAssert", + "assertionStackName": "evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2" + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/manifest.json new file mode 100644 index 000000000..c18db3ab9 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/manifest.json @@ -0,0 +1,179 @@ +{ + "version": "39.0.0", + "artifacts": { + "evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.template.json", + "terminationProtection": false, + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "evtsqsruledlqIntegDefaultTestDeployAssertE0D1E1C2.assets" + ], + "metadata": { + "/evtsqs-rule-dlq/Integ/DefaultTest/DeployAssert/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/evtsqs-rule-dlq/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "evtsqs-rule-dlq/Integ/DefaultTest/DeployAssert" + }, + "evtsqs-rule-dlq.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "evtsqs-rule-dlq.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "evtsqs-rule-dlq": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "evtsqs-rule-dlq.template.json", + "terminationProtection": false, + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/1b987658e020bc5bb91c28188d302de48a98e534e39808f44580279068526530.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "evtsqs-rule-dlq.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "evtsqs-rule-dlq.assets" + ], + "metadata": { + "/evtsqs-rule-dlq/construct/queue-dlq/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueuedlq6B66D1E6" + } + ], + "/evtsqs-rule-dlq/construct/queue-dlq/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueuedlqPolicy3B6CC54E" + } + ], + "/evtsqs-rule-dlq/construct/'queueKey'/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueueKey0638E1FB" + } + ], + "/evtsqs-rule-dlq/construct/queue": [ + { + "type": "aws:cdk:warning", + "data": "encryption: Automatically changed to QueueEncryption.KMS, was: QueueEncryption.KMS_MANAGED\nWhen encryptionMasterKey is provided, always set `encryption: QueueEncryption.KMS` [ack: @aws-cdk/aws-sqs:queueEncryptionChangedToKMS]" + } + ], + "/evtsqs-rule-dlq/construct/queue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueue481DC1EC" + } + ], + "/evtsqs-rule-dlq/construct/queue/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructqueuePolicy5B0256B1" + } + ], + "/evtsqs-rule-dlq/construct/'ruleDlqKey'/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructruleDlqKey4F9EAB36" + } + ], + "/evtsqs-rule-dlq/construct/'ruleDlqKey'/Alias/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructruleDlqKeyAliasF2A45A01" + } + ], + "/evtsqs-rule-dlq/construct/ruleDlq": [ + { + "type": "aws:cdk:warning", + "data": "encryption: Automatically changed to QueueEncryption.KMS, was: QueueEncryption.KMS_MANAGED\nWhen encryptionMasterKey is provided, always set `encryption: QueueEncryption.KMS` [ack: @aws-cdk/aws-sqs:queueEncryptionChangedToKMS]" + } + ], + "/evtsqs-rule-dlq/construct/ruleDlq/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructruleDlq7D359AE9" + } + ], + "/evtsqs-rule-dlq/construct/ruleDlq/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructruleDlqPolicyE4AB8569" + } + ], + "/evtsqs-rule-dlq/construct/EventsRule/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "constructEventsRule43880ADB" + } + ], + "/evtsqs-rule-dlq/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/evtsqs-rule-dlq/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "evtsqs-rule-dlq" + }, + "Tree": { + "type": "cdk:tree", + "properties": { + "file": "tree.json" + } + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/tree.json new file mode 100644 index 000000000..38c645157 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.js.snapshot/tree.json @@ -0,0 +1,728 @@ +{ + "version": "tree-0.1", + "tree": { + "id": "App", + "path": "", + "children": { + "evtsqs-rule-dlq": { + "id": "evtsqs-rule-dlq", + "path": "evtsqs-rule-dlq", + "children": { + "construct": { + "id": "construct", + "path": "evtsqs-rule-dlq/construct", + "children": { + "queue-dlq": { + "id": "queue-dlq", + "path": "evtsqs-rule-dlq/construct/queue-dlq", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/queue-dlq/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "kmsMasterKeyId": "alias/aws/sqs" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", + "version": "2.177.0" + } + }, + "Policy": { + "id": "Policy", + "path": "evtsqs-rule-dlq/construct/queue-dlq/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/queue-dlq/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::QueuePolicy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "Sid": "HttpsOnly" + } + ], + "Version": "2012-10-17" + }, + "queues": [ + { + "Ref": "constructqueuedlq6B66D1E6" + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.Queue", + "version": "2.177.0" + } + }, + "'queueKey'": { + "id": "'queueKey'", + "path": "evtsqs-rule-dlq/construct/'queueKey'", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/'queueKey'/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::KMS::Key", + "aws:cdk:cloudformation:props": { + "enableKeyRotation": true, + "keyPolicy": { + "Statement": [ + { + "Action": "kms:*", + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": "*" + }, + { + "Action": [ + "kms:Decrypt", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": "*" + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kms.CfnKey", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kms.Key", + "version": "2.177.0" + } + }, + "queue": { + "id": "queue", + "path": "evtsqs-rule-dlq/construct/queue", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/queue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "kmsMasterKeyId": { + "Fn::GetAtt": [ + "constructqueueKey0638E1FB", + "Arn" + ] + }, + "redrivePolicy": { + "deadLetterTargetArn": { + "Fn::GetAtt": [ + "constructqueuedlq6B66D1E6", + "Arn" + ] + }, + "maxReceiveCount": 15 + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", + "version": "2.177.0" + } + }, + "Policy": { + "id": "Policy", + "path": "evtsqs-rule-dlq/construct/queue/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/queue/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::QueuePolicy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "Sid": "HttpsOnly" + }, + { + "Action": [ + "sqs:GetQueueAttributes", + "sqs:GetQueueUrl", + "sqs:SendMessage" + ], + "Condition": { + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "queues": [ + { + "Ref": "constructqueue481DC1EC" + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.Queue", + "version": "2.177.0" + } + }, + "'ruleDlqKey'": { + "id": "'ruleDlqKey'", + "path": "evtsqs-rule-dlq/construct/'ruleDlqKey'", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/'ruleDlqKey'/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::KMS::Key", + "aws:cdk:cloudformation:props": { + "enableKeyRotation": true, + "keyPolicy": { + "Statement": [ + { + "Action": "kms:*", + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": "*" + }, + { + "Action": [ + "kms:Decrypt", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": "*" + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kms.CfnKey", + "version": "2.177.0" + } + }, + "Alias": { + "id": "Alias", + "path": "evtsqs-rule-dlq/construct/'ruleDlqKey'/Alias", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/'ruleDlqKey'/Alias/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::KMS::Alias", + "aws:cdk:cloudformation:props": { + "aliasName": "alias/test-alias", + "targetKeyId": { + "Fn::GetAtt": [ + "constructruleDlqKey4F9EAB36", + "Arn" + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kms.CfnAlias", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kms.Alias", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kms.Key", + "version": "2.177.0" + } + }, + "ruleDlq": { + "id": "ruleDlq", + "path": "evtsqs-rule-dlq/construct/ruleDlq", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/ruleDlq/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "kmsMasterKeyId": { + "Fn::GetAtt": [ + "constructruleDlqKey4F9EAB36", + "Arn" + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", + "version": "2.177.0" + } + }, + "Policy": { + "id": "Policy", + "path": "evtsqs-rule-dlq/construct/ruleDlq/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/ruleDlq/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::QueuePolicy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "sqs:AddPermission", + "sqs:DeleteMessage", + "sqs:GetQueueAttributes", + "sqs:ReceiveMessage", + "sqs:RemovePermission", + "sqs:SendMessage", + "sqs:SetQueueAttributes" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": { + "Fn::GetAtt": [ + "constructruleDlq7D359AE9", + "Arn" + ] + }, + "Sid": "QueueOwnerOnlyAccess" + }, + { + "Action": "SQS:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": { + "Fn::GetAtt": [ + "constructruleDlq7D359AE9", + "Arn" + ] + }, + "Sid": "HttpsOnly" + }, + { + "Action": "sqs:SendMessage", + "Condition": { + "ArnEquals": { + "aws:SourceArn": { + "Fn::GetAtt": [ + "constructEventsRule43880ADB", + "Arn" + ] + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "events.amazonaws.com" + }, + "Resource": { + "Fn::GetAtt": [ + "constructruleDlq7D359AE9", + "Arn" + ] + }, + "Sid": "AllowEventRuleevtsqsruledlqconstructEventsRule62503343" + } + ], + "Version": "2012-10-17" + }, + "queues": [ + { + "Ref": "constructruleDlq7D359AE9" + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_sqs.Queue", + "version": "2.177.0" + } + }, + "EventsRule": { + "id": "EventsRule", + "path": "evtsqs-rule-dlq/construct/EventsRule", + "children": { + "Resource": { + "id": "Resource", + "path": "evtsqs-rule-dlq/construct/EventsRule/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Events::Rule", + "aws:cdk:cloudformation:props": { + "scheduleExpression": "rate(1 minute)", + "state": "ENABLED", + "targets": [ + { + "id": "Target0", + "arn": { + "Fn::GetAtt": [ + "constructqueue481DC1EC", + "Arn" + ] + }, + "deadLetterConfig": { + "arn": { + "Fn::GetAtt": [ + "constructruleDlq7D359AE9", + "Arn" + ] + } + } + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_events.CfnRule", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_events.Rule", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-solutions-constructs/aws-eventbridge-sqs.EventbridgeToSqs", + "version": "2.76.0" + } + }, + "Integ": { + "id": "Integ", + "path": "evtsqs-rule-dlq/Integ", + "children": { + "DefaultTest": { + "id": "DefaultTest", + "path": "evtsqs-rule-dlq/Integ/DefaultTest", + "children": { + "Default": { + "id": "Default", + "path": "evtsqs-rule-dlq/Integ/DefaultTest/Default", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.4.2" + } + }, + "DeployAssert": { + "id": "DeployAssert", + "path": "evtsqs-rule-dlq/Integ/DefaultTest/DeployAssert", + "children": { + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "evtsqs-rule-dlq/Integ/DefaultTest/DeployAssert/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "2.177.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "evtsqs-rule-dlq/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", + "version": "2.177.0-alpha.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", + "version": "2.177.0-alpha.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "evtsqs-rule-dlq/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "2.177.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "evtsqs-rule-dlq/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "2.177.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "2.177.0" + } + }, + "Tree": { + "id": "Tree", + "path": "Tree", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.4.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.App", + "version": "2.177.0" + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.ts b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.ts new file mode 100644 index 000000000..daa73593b --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-sqs/test/integ.evtsqs-rule-dlq.ts @@ -0,0 +1,37 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +import { Duration } from 'aws-cdk-lib'; +import { EventbridgeToSqsProps, EventbridgeToSqs } from '../lib'; +import * as events from 'aws-cdk-lib/aws-events'; +import { App, Stack } from 'aws-cdk-lib'; +import { generateIntegStackName } from '@aws-solutions-constructs/core'; +import { IntegTest } from '@aws-cdk/integ-tests-alpha'; + +const app = new App(); +const stack = new Stack(app, generateIntegStackName(__filename)); + +const props: EventbridgeToSqsProps = { + eventRuleProps: { + schedule: events.Schedule.rate(Duration.minutes(1)) + }, + deployEventRuleDlq: true, + eventRuleDlqKeyProps: { + alias: 'test-alias' + } +}; + +new EventbridgeToSqs(stack, 'construct', props); +new IntegTest(stack, 'Integ', { testCases: [ + stack +] }); diff --git a/source/patterns/@aws-solutions-constructs/aws-eventbridge-stepfunctions/package.json b/source/patterns/@aws-solutions-constructs/aws-eventbridge-stepfunctions/package.json index f7fda141e..0c88ee598 100644 --- a/source/patterns/@aws-solutions-constructs/aws-eventbridge-stepfunctions/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-eventbridge-stepfunctions/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/package.json index dda610ec4..b0d5b6e36 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddb-existing-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddb-existing-resources.assets.json index 89b807a5b..fac23c92b 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddb-existing-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddb-existing-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "213de4059d194de7881eca242d295506cbfdda0304aa7fec1d359ce5668addee": { + "7f29d9b6267a7687abcbee23fc9c72c1d26841ee52a8651e79cc630b3f58f418": { "source": { "path": "farddb-existing-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "213de4059d194de7881eca242d295506cbfdda0304aa7fec1d359ce5668addee.json", + "objectKey": "7f29d9b6267a7687abcbee23fc9c72c1d26841ee52a8651e79cc630b3f58f418.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddb-existing-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddb-existing-resources.template.json index 7eb19b481..1422b8ec2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddb-existing-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddb-existing-resources.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farddb-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farddb-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farddb-existing-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -665,6 +683,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farddb-existing-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -744,7 +768,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddbexistingresourcesIntegDefaultTestDeployAssert321EBEB1.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddbexistingresourcesIntegDefaultTestDeployAssert321EBEB1.assets.json index 35d606bed..67d06361a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddbexistingresourcesIntegDefaultTestDeployAssert321EBEB1.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/farddbexistingresourcesIntegDefaultTestDeployAssert321EBEB1.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/integ.json index 06801032a..4fac222f0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farddb-existing-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/manifest.json index f467c9477..7d891d4de 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farddbexistingresourcesIntegDefaultTestDeployAssert321EBEB1.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/213de4059d194de7881eca242d295506cbfdda0304aa7fec1d359ce5668addee.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/7f29d9b6267a7687abcbee23fc9c72c1d26841ee52a8651e79cc630b3f58f418.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -274,6 +274,12 @@ "data": "VpcDDB49FBEC5F" } ], + "/farddb-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farddb-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/tree.json index 137b8557a..a074d3ec4 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-existing-resources.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farddb-existing-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farddb-existing-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farddb-existing-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farddb-existing-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farddb-existing-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farddb-existing-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farddb-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farddb-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farddb-existing-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,13 +996,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "DDB": { @@ -997,6 +1015,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farddb-existing-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1031,19 +1055,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1055,7 +1079,7 @@ "path": "farddb-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1063,7 +1087,7 @@ "path": "farddb-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1071,13 +1095,13 @@ "path": "farddb-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "DynamoTable": { @@ -1113,7 +1137,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.CfnTable", - "version": "2.150.0" + "version": "2.174.0" } }, "ScalingRole": { @@ -1121,13 +1145,13 @@ "path": "farddb-existing-resources/DynamoTable/ScalingRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.Table", - "version": "2.150.0" + "version": "2.174.0" } }, "farddb-existing-resources-ECR_API-security-group": { @@ -1183,13 +1207,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farddb-existing-resources-ECR_DKR-security-group": { @@ -1245,13 +1269,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1267,13 +1291,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1289,7 +1313,7 @@ "path": "farddb-existing-resources/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1314,7 +1338,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1370,19 +1394,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1439,7 +1463,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1447,13 +1471,13 @@ "path": "farddb-existing-resources/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1481,13 +1505,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1539,13 +1563,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1553,7 +1577,7 @@ "path": "farddb-existing-resources/test-construct", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-dynamodb.FargateToDynamoDB", - "version": "2.63.0" + "version": "2.76.0" } }, "Integ": { @@ -1569,7 +1593,7 @@ "path": "farddb-existing-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1581,7 +1605,7 @@ "path": "farddb-existing-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1589,25 +1613,25 @@ "path": "farddb-existing-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1615,7 +1639,7 @@ "path": "farddb-existing-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1623,13 +1647,13 @@ "path": "farddb-existing-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1637,13 +1661,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddb-new-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddb-new-resources.assets.json index 133d63477..ca3d43c33 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddb-new-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddb-new-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "01b368e297fde05d49a7e862147c0c015837cdc7116ce2554e59e938a3e2d7e5": { + "27f13701788308e949fd7ba7bdf728a10ac4b135125685666cd52bc74e0d728c": { "source": { "path": "farddb-new-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "01b368e297fde05d49a7e862147c0c015837cdc7116ce2554e59e938a3e2d7e5.json", + "objectKey": "27f13701788308e949fd7ba7bdf728a10ac4b135125685666cd52bc74e0d728c.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddb-new-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddb-new-resources.template.json index f3eebf094..2ecedc305 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddb-new-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddb-new-resources.template.json @@ -609,6 +609,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farddb-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -636,6 +642,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farddb-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -663,6 +675,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farddb-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -698,6 +716,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farddb-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -777,7 +801,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddbnewresourcesIntegDefaultTestDeployAssert0D227FA2.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddbnewresourcesIntegDefaultTestDeployAssert0D227FA2.assets.json index 4f8896b70..cc9eed4e3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddbnewresourcesIntegDefaultTestDeployAssert0D227FA2.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/farddbnewresourcesIntegDefaultTestDeployAssert0D227FA2.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/integ.json index 5700db2fe..560ad5fb6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farddb-new-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/manifest.json index a4545181b..77ccbddca 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farddbnewresourcesIntegDefaultTestDeployAssert0D227FA2.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/01b368e297fde05d49a7e862147c0c015837cdc7116ce2554e59e938a3e2d7e5.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/27f13701788308e949fd7ba7bdf728a10ac4b135125685666cd52bc74e0d728c.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -280,6 +280,12 @@ "data": "VpcS3A5408339" } ], + "/farddb-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farddb-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/tree.json index ea2bc7207..bf00b2a1a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-dynamodb/test/integ.farddb-new-resources.js.snapshot/tree.json @@ -45,7 +45,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.CfnTable", - "version": "2.150.0" + "version": "2.174.0" } }, "ScalingRole": { @@ -53,19 +53,19 @@ "path": "farddb-new-resources/test-construct/DynamoTable/ScalingRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.Table", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-dynamodb.FargateToDynamoDB", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -92,7 +92,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -136,7 +136,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -144,7 +144,7 @@ "path": "farddb-new-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -166,7 +166,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -185,7 +185,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -205,7 +205,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -225,7 +225,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -253,13 +253,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -303,7 +303,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -311,7 +311,7 @@ "path": "farddb-new-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -333,7 +333,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -352,7 +352,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -372,7 +372,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -392,7 +392,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -420,13 +420,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -470,7 +470,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -478,7 +478,7 @@ "path": "farddb-new-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -500,7 +500,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -519,7 +519,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -539,13 +539,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -589,7 +589,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -597,7 +597,7 @@ "path": "farddb-new-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -619,7 +619,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -638,7 +638,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -658,13 +658,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -683,7 +683,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -702,7 +702,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -714,13 +714,13 @@ "path": "farddb-new-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -736,7 +736,7 @@ "path": "farddb-new-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -767,7 +767,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -819,19 +819,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -855,13 +855,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -895,13 +895,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "DDB": { @@ -914,6 +914,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farddb-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -948,13 +954,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -967,6 +973,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farddb-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -993,13 +1005,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1012,6 +1024,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farddb-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1038,13 +1056,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1057,6 +1075,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farddb-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1091,19 +1115,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1115,7 +1139,7 @@ "path": "farddb-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1123,7 +1147,7 @@ "path": "farddb-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1131,13 +1155,13 @@ "path": "farddb-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farddb-new-resources-ECR_API-security-group": { @@ -1193,13 +1217,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farddb-new-resources-ECR_DKR-security-group": { @@ -1255,13 +1279,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1277,13 +1301,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1299,7 +1323,7 @@ "path": "farddb-new-resources/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1324,7 +1348,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1380,19 +1404,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1449,7 +1473,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -1457,13 +1481,13 @@ "path": "farddb-new-resources/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -1491,13 +1515,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -1549,13 +1573,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1571,7 +1595,7 @@ "path": "farddb-new-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1583,7 +1607,7 @@ "path": "farddb-new-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1591,25 +1615,25 @@ "path": "farddb-new-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1617,7 +1641,7 @@ "path": "farddb-new-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1625,13 +1649,13 @@ "path": "farddb-new-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1639,13 +1663,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/package.json index a3d42f1c2..07a15721e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevt-existing-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevt-existing-resources.assets.json index 26b2b8f9f..4658fc5fd 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevt-existing-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevt-existing-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "3c57c8c25a1ce848d5cd50cca89aaa4f4c908105d781d56fbd17a1d137d0833a": { + "513308024e03ac37d31445e7025b59d2d58f23a50571d5635267b6e272100f9a": { "source": { "path": "farevt-existing-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "3c57c8c25a1ce848d5cd50cca89aaa4f4c908105d781d56fbd17a1d137d0833a.json", + "objectKey": "513308024e03ac37d31445e7025b59d2d58f23a50571d5635267b6e272100f9a.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevt-existing-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevt-existing-resources.template.json index 20cb368af..88dfe3cf8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevt-existing-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevt-existing-resources.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farevt-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farevt-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farevt-existing-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -657,6 +675,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farevt-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -736,7 +760,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevtexistingresourcesIntegDefaultTestDeployAssertBA26C619.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevtexistingresourcesIntegDefaultTestDeployAssertBA26C619.assets.json index 6355dbacd..8d63a13e8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevtexistingresourcesIntegDefaultTestDeployAssertBA26C619.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/farevtexistingresourcesIntegDefaultTestDeployAssertBA26C619.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/integ.json index d08a874ce..ebddcb965 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farevt-existing-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/manifest.json index 721347355..752f95e2f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farevtexistingresourcesIntegDefaultTestDeployAssertBA26C619.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/3c57c8c25a1ce848d5cd50cca89aaa4f4c908105d781d56fbd17a1d137d0833a.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/513308024e03ac37d31445e7025b59d2d58f23a50571d5635267b6e272100f9a.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -274,6 +274,12 @@ "data": "VpcCLOUDWATCHEVENTS1A0DAFBF" } ], + "/farevt-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farevt-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/tree.json index 0a2a8905c..839ad4d81 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-existing-resources.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farevt-existing-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farevt-existing-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farevt-existing-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farevt-existing-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farevt-existing-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farevt-existing-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farevt-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farevt-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farevt-existing-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,13 +996,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "CLOUDWATCH_EVENTS": { @@ -997,6 +1015,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farevt-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1023,19 +1047,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1047,7 +1071,7 @@ "path": "farevt-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1055,7 +1079,7 @@ "path": "farevt-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1063,13 +1087,13 @@ "path": "farevt-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farevt-existing-resources-ECR_API-security-group": { @@ -1125,13 +1149,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farevt-existing-resources-ECR_DKR-security-group": { @@ -1187,13 +1211,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1209,13 +1233,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1231,7 +1255,7 @@ "path": "farevt-existing-resources/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1256,7 +1280,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1294,19 +1318,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1354,7 +1378,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1362,13 +1386,13 @@ "path": "farevt-existing-resources/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1396,13 +1420,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1454,13 +1478,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "existing-event-bus": { @@ -1478,13 +1502,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.CfnEventBus", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.EventBus", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1492,7 +1516,7 @@ "path": "farevt-existing-resources/test-construct", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-eventbridge.FargateToEventbridge", - "version": "2.63.0" + "version": "2.76.0" } }, "farevt-existing-resources-CLOUDWATCH_EVENTS-security-group": { @@ -1548,13 +1572,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1570,7 +1594,7 @@ "path": "farevt-existing-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1582,7 +1606,7 @@ "path": "farevt-existing-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1590,25 +1614,25 @@ "path": "farevt-existing-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1616,7 +1640,7 @@ "path": "farevt-existing-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1624,13 +1648,13 @@ "path": "farevt-existing-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1638,13 +1662,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevt-new-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevt-new-resources.assets.json index b60bf4382..bae76676b 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevt-new-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevt-new-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "a14c1fe327cfe5c21efc5a2e4cd9185edf380f25bb93380c9b6d7eb838829bb7": { + "c4afba6455a7fdcfffcd976532e0ebce0a229caab13726a9310256a3d8952da2": { "source": { "path": "farevt-new-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "a14c1fe327cfe5c21efc5a2e4cd9185edf380f25bb93380c9b6d7eb838829bb7.json", + "objectKey": "c4afba6455a7fdcfffcd976532e0ebce0a229caab13726a9310256a3d8952da2.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevt-new-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevt-new-resources.template.json index 58721e27a..36afb7e39 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevt-new-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevt-new-resources.template.json @@ -574,6 +574,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farevt-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -601,6 +607,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farevt-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -628,6 +640,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farevt-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -663,6 +681,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farevt-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -742,7 +766,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevtnewresourcesIntegDefaultTestDeployAssert7B8E017C.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevtnewresourcesIntegDefaultTestDeployAssert7B8E017C.assets.json index 2d60f09e2..2bf3abd07 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevtnewresourcesIntegDefaultTestDeployAssert7B8E017C.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/farevtnewresourcesIntegDefaultTestDeployAssert7B8E017C.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/integ.json index c71b283a0..9a1134a37 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farevt-new-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/manifest.json index 1e8c8e4f6..8de64969c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farevtnewresourcesIntegDefaultTestDeployAssert7B8E017C.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/a14c1fe327cfe5c21efc5a2e4cd9185edf380f25bb93380c9b6d7eb838829bb7.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/c4afba6455a7fdcfffcd976532e0ebce0a229caab13726a9310256a3d8952da2.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -280,6 +280,12 @@ "data": "VpcS3A5408339" } ], + "/farevt-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farevt-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/tree.json index e42854943..c579b5acf 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-eventbridge/test/integ.farevt-new-resources.js.snapshot/tree.json @@ -27,19 +27,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.CfnEventBus", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.EventBus", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-eventbridge.FargateToEventbridge", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -66,7 +66,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -110,7 +110,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -118,7 +118,7 @@ "path": "farevt-new-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -140,7 +140,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -159,7 +159,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -179,7 +179,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -199,7 +199,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -227,13 +227,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -277,7 +277,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -285,7 +285,7 @@ "path": "farevt-new-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -307,7 +307,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -326,7 +326,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -346,7 +346,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -366,7 +366,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -394,13 +394,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -444,7 +444,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -452,7 +452,7 @@ "path": "farevt-new-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -474,7 +474,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -493,7 +493,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -513,13 +513,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -563,7 +563,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -571,7 +571,7 @@ "path": "farevt-new-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -593,7 +593,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -612,7 +612,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -632,13 +632,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -657,7 +657,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -676,7 +676,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -688,13 +688,13 @@ "path": "farevt-new-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -710,7 +710,7 @@ "path": "farevt-new-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -741,7 +741,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -793,19 +793,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -829,13 +829,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -869,13 +869,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "CLOUDWATCH_EVENTS": { @@ -888,6 +888,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farevt-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -914,13 +920,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -933,6 +939,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farevt-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -959,13 +971,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -978,6 +990,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farevt-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1004,13 +1022,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1023,6 +1041,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farevt-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1057,19 +1081,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1081,7 +1105,7 @@ "path": "farevt-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1089,7 +1113,7 @@ "path": "farevt-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1097,13 +1121,13 @@ "path": "farevt-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farevt-new-resources-CLOUDWATCH_EVENTS-security-group": { @@ -1159,13 +1183,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farevt-new-resources-ECR_API-security-group": { @@ -1221,13 +1245,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farevt-new-resources-ECR_DKR-security-group": { @@ -1283,13 +1307,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1305,13 +1329,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1327,7 +1351,7 @@ "path": "farevt-new-resources/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1352,7 +1376,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1390,19 +1414,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1450,7 +1474,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -1458,13 +1482,13 @@ "path": "farevt-new-resources/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -1492,13 +1516,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -1550,13 +1574,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1572,7 +1596,7 @@ "path": "farevt-new-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1584,7 +1608,7 @@ "path": "farevt-new-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1592,25 +1616,25 @@ "path": "farevt-new-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1618,7 +1642,7 @@ "path": "farevt-new-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1626,13 +1650,13 @@ "path": "farevt-new-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1640,13 +1664,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/package.json index 82cd5dd7e..de382555d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhs-existingFargateService.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhs-existingFargateService.assets.json index c967e9983..7e76e8b1f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhs-existingFargateService.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhs-existingFargateService.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "a9ee9af9e3d434b6116e2a30d8a949a49302ca84211d870cc77122140c52ba94": { + "5c20f249fcb421612b923b9d66c4281d616a5970da5254e46313abd8e01ba234": { "source": { "path": "farfhs-existingFargateService.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "a9ee9af9e3d434b6116e2a30d8a949a49302ca84211d870cc77122140c52ba94.json", + "objectKey": "5c20f249fcb421612b923b9d66c4281d616a5970da5254e46313abd8e01ba234.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhs-existingFargateService.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhs-existingFargateService.template.json index 58db55f4d..80369ae20 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhs-existingFargateService.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhs-existingFargateService.template.json @@ -578,6 +578,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-existingFargateService/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -616,6 +622,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-existingFargateService/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -651,6 +663,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-existingFargateService/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -689,6 +707,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-existingFargateService/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -776,7 +800,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhsexistingFargateServiceIntegDefaultTestDeployAssertFE299A7C.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhsexistingFargateServiceIntegDefaultTestDeployAssertFE299A7C.assets.json index 8d21af915..3424af480 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhsexistingFargateServiceIntegDefaultTestDeployAssertFE299A7C.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/farfhsexistingFargateServiceIntegDefaultTestDeployAssertFE299A7C.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/integ.json index d86be362c..168accce6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farfhs-existingFargateService/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/manifest.json index a385acacc..0dfa30be1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farfhsexistingFargateServiceIntegDefaultTestDeployAssertFE299A7C.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/a9ee9af9e3d434b6116e2a30d8a949a49302ca84211d870cc77122140c52ba94.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/5c20f249fcb421612b923b9d66c4281d616a5970da5254e46313abd8e01ba234.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -280,6 +280,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farfhs-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -358,6 +364,12 @@ "data": "destinationfirehoseKinesisFirehoseE8EB5D91" } ], + "/farfhs-existingFargateService/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-existingFargateService/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/tree.json index 372ec9c6f..86499df83 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingFargateService.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farfhs-existingFargateService/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farfhs-existingFargateService/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farfhs-existingFargateService/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farfhs-existingFargateService/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farfhs-existingFargateService/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farfhs-existingFargateService/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-existingFargateService/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -891,13 +897,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -910,6 +916,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-existingFargateService/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -947,13 +959,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -966,6 +978,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-existingFargateService/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1000,13 +1018,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_FIREHOSE": { @@ -1019,6 +1037,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-existingFargateService/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1056,19 +1080,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1076,7 +1100,7 @@ "path": "farfhs-existingFargateService/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1088,7 +1112,7 @@ "path": "farfhs-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1096,7 +1120,7 @@ "path": "farfhs-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1104,13 +1128,13 @@ "path": "farfhs-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "destination-firehose": { @@ -1155,7 +1179,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -1289,13 +1313,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -1307,19 +1331,19 @@ "path": "farfhs-existingFargateService/destination-firehose/S3LoggingBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "S3Bucket": { @@ -1378,7 +1402,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -1476,13 +1500,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -1494,19 +1518,19 @@ "path": "farfhs-existingFargateService/destination-firehose/S3Bucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-group": { @@ -1522,7 +1546,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-stream": { @@ -1542,19 +1566,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehoseRole": { @@ -1566,7 +1590,7 @@ "path": "farfhs-existingFargateService/destination-firehose/KinesisFirehoseRole/ImportKinesisFirehoseRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1591,13 +1615,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehosePolicy": { @@ -1689,13 +1713,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehose": { @@ -1764,13 +1788,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-kinesisfirehose-s3.KinesisFirehoseToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -1782,7 +1806,7 @@ "path": "farfhs-existingFargateService/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1790,7 +1814,7 @@ "path": "farfhs-existingFargateService/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1798,13 +1822,13 @@ "path": "farfhs-existingFargateService/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "destination-firehoseaws-managed-key": { @@ -1812,7 +1836,7 @@ "path": "farfhs-existingFargateService/destination-firehoseaws-managed-key", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-existingFargateService-ECR_API-security-group": { @@ -1868,13 +1892,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-existingFargateService-ECR_DKR-security-group": { @@ -1930,13 +1954,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1952,13 +1976,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1974,7 +1998,7 @@ "path": "farfhs-existingFargateService/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1999,7 +2023,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -2042,19 +2066,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2100,7 +2124,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -2108,13 +2132,13 @@ "path": "farfhs-existingFargateService/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -2142,13 +2166,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -2200,13 +2224,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams": { @@ -2214,7 +2238,7 @@ "path": "farfhs-existingFargateService/test-fargate-kinesisstreams", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisfirehose.FargateToKinesisFirehose", - "version": "2.63.0" + "version": "2.76.0" } }, "farfhs-existingFargateService-KINESIS_FIREHOSE-security-group": { @@ -2270,13 +2294,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -2292,7 +2316,7 @@ "path": "farfhs-existingFargateService/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -2304,7 +2328,7 @@ "path": "farfhs-existingFargateService/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2312,25 +2336,25 @@ "path": "farfhs-existingFargateService/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2338,7 +2362,7 @@ "path": "farfhs-existingFargateService/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2346,13 +2370,13 @@ "path": "farfhs-existingFargateService/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2360,13 +2384,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhs-existingVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhs-existingVpc.assets.json index c19660df5..e8bd16305 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhs-existingVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhs-existingVpc.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "21da3585a3b6a5b21a950c1096fa00aa0f2a6e8cc61dfe86677fc0219eb61371": { + "4a7e2a32a71e527f9efee5b360e0336da0aecb80af6e79918c2d73b4abe8074d": { "source": { "path": "farfhs-existingVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "21da3585a3b6a5b21a950c1096fa00aa0f2a6e8cc61dfe86677fc0219eb61371.json", + "objectKey": "4a7e2a32a71e527f9efee5b360e0336da0aecb80af6e79918c2d73b4abe8074d.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhs-existingVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhs-existingVpc.template.json index bb844c16c..4898c2930 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhs-existingVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhs-existingVpc.template.json @@ -578,6 +578,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-existingVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -616,6 +622,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-existingVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -654,6 +666,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-existingVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -689,6 +707,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-existingVpc/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -776,7 +800,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhsexistingVpcIntegDefaultTestDeployAssert701C2EAB.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhsexistingVpcIntegDefaultTestDeployAssert701C2EAB.assets.json index 897458c1c..fdba6bb35 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhsexistingVpcIntegDefaultTestDeployAssert701C2EAB.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/farfhsexistingVpcIntegDefaultTestDeployAssert701C2EAB.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/integ.json index b94f64e29..8ee4f3669 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farfhs-existingVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/manifest.json index e80cf2428..502658d71 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farfhsexistingVpcIntegDefaultTestDeployAssert701C2EAB.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/21da3585a3b6a5b21a950c1096fa00aa0f2a6e8cc61dfe86677fc0219eb61371.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/4a7e2a32a71e527f9efee5b360e0336da0aecb80af6e79918c2d73b4abe8074d.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -280,6 +280,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farfhs-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -358,6 +364,12 @@ "data": "destinationfirehoseKinesisFirehoseE8EB5D91" } ], + "/farfhs-existingVpc/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-existingVpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/tree.json index 23e6d39b6..010ba0a11 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-existingVpc.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farfhs-existingVpc/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farfhs-existingVpc/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farfhs-existingVpc/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farfhs-existingVpc/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farfhs-existingVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farfhs-existingVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_FIREHOSE": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-existingVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -891,13 +897,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -910,6 +916,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-existingVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -947,13 +959,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -966,6 +978,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-existingVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1003,13 +1021,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1022,6 +1040,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-existingVpc/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1056,19 +1080,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1076,7 +1100,7 @@ "path": "farfhs-existingVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1088,7 +1112,7 @@ "path": "farfhs-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1096,7 +1120,7 @@ "path": "farfhs-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1104,13 +1128,13 @@ "path": "farfhs-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "destination-firehose": { @@ -1155,7 +1179,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -1289,13 +1313,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -1307,19 +1331,19 @@ "path": "farfhs-existingVpc/destination-firehose/S3LoggingBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "S3Bucket": { @@ -1378,7 +1402,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -1476,13 +1500,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -1494,19 +1518,19 @@ "path": "farfhs-existingVpc/destination-firehose/S3Bucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-group": { @@ -1522,7 +1546,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-stream": { @@ -1542,19 +1566,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehoseRole": { @@ -1566,7 +1590,7 @@ "path": "farfhs-existingVpc/destination-firehose/KinesisFirehoseRole/ImportKinesisFirehoseRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1591,13 +1615,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehosePolicy": { @@ -1689,13 +1713,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehose": { @@ -1764,13 +1788,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-kinesisfirehose-s3.KinesisFirehoseToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -1782,7 +1806,7 @@ "path": "farfhs-existingVpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1790,7 +1814,7 @@ "path": "farfhs-existingVpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1798,13 +1822,13 @@ "path": "farfhs-existingVpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "destination-firehoseaws-managed-key": { @@ -1812,7 +1836,7 @@ "path": "farfhs-existingVpc/destination-firehoseaws-managed-key", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams": { @@ -1820,7 +1844,7 @@ "path": "farfhs-existingVpc/test-fargate-kinesisstreams", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisfirehose.FargateToKinesisFirehose", - "version": "2.63.0" + "version": "2.76.0" } }, "farfhs-existingVpc-KINESIS_FIREHOSE-security-group": { @@ -1876,13 +1900,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-existingVpc-ECR_API-security-group": { @@ -1938,13 +1962,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-existingVpc-ECR_DKR-security-group": { @@ -2000,13 +2024,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-cluster": { @@ -2022,13 +2046,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-taskdef": { @@ -2044,7 +2068,7 @@ "path": "farfhs-existingVpc/test-fargate-kinesisstreams-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2069,7 +2093,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -2112,19 +2136,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2170,7 +2194,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-container": { @@ -2178,13 +2202,13 @@ "path": "farfhs-existingVpc/test-fargate-kinesisstreams-taskdef/test-fargate-kinesisstreams-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-sg": { @@ -2212,13 +2236,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-service": { @@ -2270,13 +2294,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -2292,7 +2316,7 @@ "path": "farfhs-existingVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -2304,7 +2328,7 @@ "path": "farfhs-existingVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2312,25 +2336,25 @@ "path": "farfhs-existingVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2338,7 +2362,7 @@ "path": "farfhs-existingVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2346,13 +2370,13 @@ "path": "farfhs-existingVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2360,13 +2384,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhs-fargateServiceFromProps.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhs-fargateServiceFromProps.assets.json index d99c2f161..ee35ed8b2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhs-fargateServiceFromProps.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhs-fargateServiceFromProps.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6": { "source": { @@ -14,20 +14,20 @@ } } }, - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "f806cd4f449cc586fbf83b3b3870e1280a48507b05cd720b4271aaa12a5bd750": { + "50c8ed44deca6c3c67c36bb9c52c0cec40c2cf87ed38dfae4e7c388c214885d6": { "source": { "path": "farfhs-fargateServiceFromProps.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "f806cd4f449cc586fbf83b3b3870e1280a48507b05cd720b4271aaa12a5bd750.json", + "objectKey": "50c8ed44deca6c3c67c36bb9c52c0cec40c2cf87ed38dfae4e7c388c214885d6.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhs-fargateServiceFromProps.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhs-fargateServiceFromProps.template.json index 2964aa487..32d0d7698 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhs-fargateServiceFromProps.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhs-fargateServiceFromProps.template.json @@ -1200,6 +1200,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-fargateServiceFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1238,6 +1244,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-fargateServiceFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1276,6 +1288,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-fargateServiceFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1311,6 +1329,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-fargateServiceFromProps/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -1398,7 +1422,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhsfargateServiceFromPropsIntegDefaultTestDeployAssertCBEC7D63.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhsfargateServiceFromPropsIntegDefaultTestDeployAssertCBEC7D63.assets.json index 3b0994ad9..6bac16b63 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhsfargateServiceFromPropsIntegDefaultTestDeployAssertCBEC7D63.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/farfhsfargateServiceFromPropsIntegDefaultTestDeployAssertCBEC7D63.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/integ.json index 92d03fbc2..7f917680e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farfhs-fargateServiceFromProps/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/manifest.json index 30a41e03e..3beeb443a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farfhsfargateServiceFromPropsIntegDefaultTestDeployAssertCBEC7D63.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/f806cd4f449cc586fbf83b3b3870e1280a48507b05cd720b4271aaa12a5bd750.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/50c8ed44deca6c3c67c36bb9c52c0cec40c2cf87ed38dfae4e7c388c214885d6.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -154,6 +154,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farfhs-fargateServiceFromProps/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-fargateServiceFromProps/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -358,6 +364,12 @@ "data": "VpcS3A5408339" } ], + "/farfhs-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/tree.json index 4ad0c0457..c24d2502a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-fargateServiceFromProps.js.snapshot/tree.json @@ -50,7 +50,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -184,13 +184,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -202,19 +202,19 @@ "path": "farfhs-fargateServiceFromProps/destination-firehose/S3LoggingBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "S3Bucket": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -371,13 +371,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -389,19 +389,19 @@ "path": "farfhs-fargateServiceFromProps/destination-firehose/S3Bucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-group": { @@ -417,7 +417,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-stream": { @@ -437,19 +437,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehoseRole": { @@ -461,7 +461,7 @@ "path": "farfhs-fargateServiceFromProps/destination-firehose/KinesisFirehoseRole/ImportKinesisFirehoseRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -486,13 +486,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehosePolicy": { @@ -584,13 +584,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehose": { @@ -659,13 +659,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-kinesisfirehose-s3.KinesisFirehoseToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "LatestNodeRuntimeMap": { @@ -673,7 +673,7 @@ "path": "farfhs-fargateServiceFromProps/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -685,7 +685,7 @@ "path": "farfhs-fargateServiceFromProps/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -693,7 +693,7 @@ "path": "farfhs-fargateServiceFromProps/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -701,13 +701,13 @@ "path": "farfhs-fargateServiceFromProps/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "destination-firehoseaws-managed-key": { @@ -715,7 +715,7 @@ "path": "farfhs-fargateServiceFromProps/destination-firehoseaws-managed-key", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams": { @@ -723,7 +723,7 @@ "path": "farfhs-fargateServiceFromProps/test-fargate-kinesisstreams", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisfirehose.FargateToKinesisFirehose", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -750,7 +750,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -794,7 +794,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -802,7 +802,7 @@ "path": "farfhs-fargateServiceFromProps/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -824,7 +824,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -843,7 +843,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -863,7 +863,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -883,7 +883,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -911,13 +911,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -961,7 +961,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -969,7 +969,7 @@ "path": "farfhs-fargateServiceFromProps/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -991,7 +991,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1010,7 +1010,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1030,7 +1030,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -1050,7 +1050,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -1078,13 +1078,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -1128,7 +1128,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1136,7 +1136,7 @@ "path": "farfhs-fargateServiceFromProps/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1158,7 +1158,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1177,7 +1177,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1197,13 +1197,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -1247,7 +1247,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1255,7 +1255,7 @@ "path": "farfhs-fargateServiceFromProps/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1277,7 +1277,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1296,7 +1296,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1316,13 +1316,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -1341,7 +1341,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -1360,7 +1360,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -1372,13 +1372,13 @@ "path": "farfhs-fargateServiceFromProps/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1394,7 +1394,7 @@ "path": "farfhs-fargateServiceFromProps/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1425,7 +1425,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1477,19 +1477,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -1513,13 +1513,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1553,13 +1553,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_FIREHOSE": { @@ -1572,6 +1572,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-fargateServiceFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1609,13 +1615,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1628,6 +1634,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-fargateServiceFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1665,13 +1677,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1684,6 +1696,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-fargateServiceFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1721,13 +1739,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1740,6 +1758,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-fargateServiceFromProps/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1774,19 +1798,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1798,7 +1822,7 @@ "path": "farfhs-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1806,7 +1830,7 @@ "path": "farfhs-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1814,13 +1838,13 @@ "path": "farfhs-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-fargateServiceFromProps-KINESIS_FIREHOSE-security-group": { @@ -1876,13 +1900,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-fargateServiceFromProps-ECR_API-security-group": { @@ -1938,13 +1962,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-fargateServiceFromProps-ECR_DKR-security-group": { @@ -2000,13 +2024,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-cluster": { @@ -2022,13 +2046,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-taskdef": { @@ -2044,7 +2068,7 @@ "path": "farfhs-fargateServiceFromProps/test-fargate-kinesisstreams-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2069,7 +2093,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -2112,19 +2136,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2170,7 +2194,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-container": { @@ -2178,13 +2202,13 @@ "path": "farfhs-fargateServiceFromProps/test-fargate-kinesisstreams-taskdef/test-fargate-kinesisstreams-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-sg": { @@ -2212,13 +2236,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-service": { @@ -2271,13 +2295,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -2293,7 +2317,7 @@ "path": "farfhs-fargateServiceFromProps/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -2305,7 +2329,7 @@ "path": "farfhs-fargateServiceFromProps/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2313,25 +2337,25 @@ "path": "farfhs-fargateServiceFromProps/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2339,7 +2363,7 @@ "path": "farfhs-fargateServiceFromProps/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2347,13 +2371,13 @@ "path": "farfhs-fargateServiceFromProps/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2361,13 +2385,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhs-noArguments.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhs-noArguments.assets.json index cc23724b5..1cfe0f799 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhs-noArguments.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhs-noArguments.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6": { "source": { @@ -15,21 +15,21 @@ } } }, - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "3e1cc2626bb8770e18b846e5b8312a6d13e3121e54fb109aa20735a926ab3bac": { + "5bfd3a79520ea0ce0e721495688ae97ceceaf59755f713fdcef300881e98995c": { "source": { "path": "farfhs-noArguments.template.json", "packaging": "file" @@ -37,7 +37,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "3e1cc2626bb8770e18b846e5b8312a6d13e3121e54fb109aa20735a926ab3bac.json", + "objectKey": "5bfd3a79520ea0ce0e721495688ae97ceceaf59755f713fdcef300881e98995c.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhs-noArguments.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhs-noArguments.template.json index 253356523..fe92819c5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhs-noArguments.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhs-noArguments.template.json @@ -1173,6 +1173,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-noArguments/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1200,6 +1206,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-noArguments/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1227,6 +1239,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-noArguments/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1262,6 +1280,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-noArguments/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -1341,7 +1365,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhsnoArgumentsIntegDefaultTestDeployAssert916C499E.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhsnoArgumentsIntegDefaultTestDeployAssert916C499E.assets.json index 3adfb87be..d3d1bbf2f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhsnoArgumentsIntegDefaultTestDeployAssert916C499E.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/farfhsnoArgumentsIntegDefaultTestDeployAssert916C499E.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/integ.json index 818d1263d..8fcc372db 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farfhs-noArguments/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/manifest.json index 38c1f490b..f27a0d4e1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farfhsnoArgumentsIntegDefaultTestDeployAssert916C499E.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/3e1cc2626bb8770e18b846e5b8312a6d13e3121e54fb109aa20735a926ab3bac.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/5bfd3a79520ea0ce0e721495688ae97ceceaf59755f713fdcef300881e98995c.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -148,6 +148,12 @@ "data": "destinationfirehoseKinesisFirehoseE8EB5D91" } ], + "/farfhs-noArguments/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-noArguments/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -352,6 +358,12 @@ "data": "VpcS3A5408339" } ], + "/farfhs-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/tree.json index 84342e55a..6f4a8af52 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-noArguments.js.snapshot/tree.json @@ -50,7 +50,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -184,13 +184,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -202,19 +202,19 @@ "path": "farfhs-noArguments/destination-firehose/S3LoggingBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "S3Bucket": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -371,13 +371,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -389,19 +389,19 @@ "path": "farfhs-noArguments/destination-firehose/S3Bucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-group": { @@ -417,7 +417,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-stream": { @@ -437,19 +437,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehoseRole": { @@ -461,7 +461,7 @@ "path": "farfhs-noArguments/destination-firehose/KinesisFirehoseRole/ImportKinesisFirehoseRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -486,13 +486,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehosePolicy": { @@ -584,13 +584,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehose": { @@ -651,13 +651,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-kinesisfirehose-s3.KinesisFirehoseToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -669,7 +669,7 @@ "path": "farfhs-noArguments/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -677,7 +677,7 @@ "path": "farfhs-noArguments/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -685,13 +685,13 @@ "path": "farfhs-noArguments/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "destination-firehoseaws-managed-key": { @@ -699,7 +699,7 @@ "path": "farfhs-noArguments/destination-firehoseaws-managed-key", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -707,7 +707,7 @@ "path": "farfhs-noArguments/test-construct", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisfirehose.FargateToKinesisFirehose", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -734,7 +734,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -778,7 +778,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -786,7 +786,7 @@ "path": "farfhs-noArguments/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -808,7 +808,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -827,7 +827,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -847,7 +847,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -867,7 +867,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -895,13 +895,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -945,7 +945,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -953,7 +953,7 @@ "path": "farfhs-noArguments/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -975,7 +975,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -994,7 +994,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1014,7 +1014,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -1034,7 +1034,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -1062,13 +1062,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -1112,7 +1112,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1120,7 +1120,7 @@ "path": "farfhs-noArguments/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1142,7 +1142,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1161,7 +1161,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1181,13 +1181,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -1231,7 +1231,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1239,7 +1239,7 @@ "path": "farfhs-noArguments/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1261,7 +1261,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1280,7 +1280,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1300,13 +1300,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -1325,7 +1325,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -1344,7 +1344,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -1356,13 +1356,13 @@ "path": "farfhs-noArguments/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1378,7 +1378,7 @@ "path": "farfhs-noArguments/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1409,7 +1409,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1461,19 +1461,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -1497,13 +1497,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1537,13 +1537,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_FIREHOSE": { @@ -1556,6 +1556,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-noArguments/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1582,13 +1588,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1601,6 +1607,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-noArguments/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1627,13 +1639,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1646,6 +1658,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-noArguments/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1672,13 +1690,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1691,6 +1709,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-noArguments/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1725,19 +1749,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1749,7 +1773,7 @@ "path": "farfhs-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1757,7 +1781,7 @@ "path": "farfhs-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1765,13 +1789,13 @@ "path": "farfhs-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-noArguments-KINESIS_FIREHOSE-security-group": { @@ -1827,13 +1851,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-noArguments-ECR_API-security-group": { @@ -1889,13 +1913,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-noArguments-ECR_DKR-security-group": { @@ -1951,13 +1975,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1973,13 +1997,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1995,7 +2019,7 @@ "path": "farfhs-noArguments/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2020,7 +2044,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -2063,19 +2087,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2121,7 +2145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -2129,13 +2153,13 @@ "path": "farfhs-noArguments/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -2163,13 +2187,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -2221,13 +2245,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -2243,7 +2267,7 @@ "path": "farfhs-noArguments/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -2255,7 +2279,7 @@ "path": "farfhs-noArguments/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2263,25 +2287,25 @@ "path": "farfhs-noArguments/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2289,7 +2313,7 @@ "path": "farfhs-noArguments/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2297,13 +2321,13 @@ "path": "farfhs-noArguments/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2311,13 +2335,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhs-vpcFromprops.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhs-vpcFromprops.assets.json index 613ff842d..483189603 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhs-vpcFromprops.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhs-vpcFromprops.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6": { "source": { @@ -14,20 +14,20 @@ } } }, - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "c414c6bf526b026d3789c7b8eb97ca10ab988deb0ff98b3dc23806db6b670d6b": { + "536087aa1e50de5a3f300aa0bb2cb552d648f56d25721bc9b5fe6bb184eebb6d": { "source": { "path": "farfhs-vpcFromprops.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "c414c6bf526b026d3789c7b8eb97ca10ab988deb0ff98b3dc23806db6b670d6b.json", + "objectKey": "536087aa1e50de5a3f300aa0bb2cb552d648f56d25721bc9b5fe6bb184eebb6d.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhs-vpcFromprops.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhs-vpcFromprops.template.json index 43e5967ff..971d5b832 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhs-vpcFromprops.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhs-vpcFromprops.template.json @@ -1200,6 +1200,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-vpcFromprops/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1238,6 +1244,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-vpcFromprops/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1276,6 +1288,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-vpcFromprops/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1311,6 +1329,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farfhs-vpcFromprops/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -1398,7 +1422,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhsvpcFrompropsIntegDefaultTestDeployAssert65C8C5A3.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhsvpcFrompropsIntegDefaultTestDeployAssert65C8C5A3.assets.json index 5921834dd..619675f8d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhsvpcFrompropsIntegDefaultTestDeployAssert65C8C5A3.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/farfhsvpcFrompropsIntegDefaultTestDeployAssert65C8C5A3.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/integ.json index 63c39fcf0..45453be07 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farfhs-vpcFromprops/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/manifest.json index dd8d3030e..971e15d03 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farfhsvpcFrompropsIntegDefaultTestDeployAssert65C8C5A3.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c414c6bf526b026d3789c7b8eb97ca10ab988deb0ff98b3dc23806db6b670d6b.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/536087aa1e50de5a3f300aa0bb2cb552d648f56d25721bc9b5fe6bb184eebb6d.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -154,6 +154,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farfhs-vpcFromprops/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-vpcFromprops/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -358,6 +364,12 @@ "data": "VpcS3A5408339" } ], + "/farfhs-vpcFromprops/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farfhs-vpcFromprops/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/tree.json index b4048f6d4..1a2bf6e7b 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisfirehose/test/integ.farfhs-vpcFromprops.js.snapshot/tree.json @@ -50,7 +50,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -184,13 +184,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -202,19 +202,19 @@ "path": "farfhs-vpcFromprops/destination-firehose/S3LoggingBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "S3Bucket": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -371,13 +371,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -389,19 +389,19 @@ "path": "farfhs-vpcFromprops/destination-firehose/S3Bucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-group": { @@ -417,7 +417,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-stream": { @@ -437,19 +437,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehoseRole": { @@ -461,7 +461,7 @@ "path": "farfhs-vpcFromprops/destination-firehose/KinesisFirehoseRole/ImportKinesisFirehoseRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -486,13 +486,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehosePolicy": { @@ -584,13 +584,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehose": { @@ -659,13 +659,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-kinesisfirehose-s3.KinesisFirehoseToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "LatestNodeRuntimeMap": { @@ -673,7 +673,7 @@ "path": "farfhs-vpcFromprops/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -685,7 +685,7 @@ "path": "farfhs-vpcFromprops/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -693,7 +693,7 @@ "path": "farfhs-vpcFromprops/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -701,13 +701,13 @@ "path": "farfhs-vpcFromprops/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "destination-firehoseaws-managed-key": { @@ -715,7 +715,7 @@ "path": "farfhs-vpcFromprops/destination-firehoseaws-managed-key", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams": { @@ -723,7 +723,7 @@ "path": "farfhs-vpcFromprops/test-fargate-kinesisstreams", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisfirehose.FargateToKinesisFirehose", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -750,7 +750,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -794,7 +794,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -802,7 +802,7 @@ "path": "farfhs-vpcFromprops/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -824,7 +824,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -843,7 +843,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -863,7 +863,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -883,7 +883,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -911,13 +911,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -961,7 +961,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -969,7 +969,7 @@ "path": "farfhs-vpcFromprops/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -991,7 +991,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1010,7 +1010,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1030,7 +1030,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -1050,7 +1050,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -1078,13 +1078,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -1128,7 +1128,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1136,7 +1136,7 @@ "path": "farfhs-vpcFromprops/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1158,7 +1158,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1177,7 +1177,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1197,13 +1197,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -1247,7 +1247,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1255,7 +1255,7 @@ "path": "farfhs-vpcFromprops/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1277,7 +1277,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1296,7 +1296,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1316,13 +1316,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -1341,7 +1341,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -1360,7 +1360,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -1372,13 +1372,13 @@ "path": "farfhs-vpcFromprops/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1394,7 +1394,7 @@ "path": "farfhs-vpcFromprops/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1425,7 +1425,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1477,19 +1477,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -1513,13 +1513,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1553,13 +1553,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_FIREHOSE": { @@ -1572,6 +1572,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-vpcFromprops/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1609,13 +1615,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1628,6 +1634,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-vpcFromprops/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1665,13 +1677,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1684,6 +1696,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-vpcFromprops/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1721,13 +1739,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1740,6 +1758,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farfhs-vpcFromprops/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1774,19 +1798,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1798,7 +1822,7 @@ "path": "farfhs-vpcFromprops/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1806,7 +1830,7 @@ "path": "farfhs-vpcFromprops/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1814,13 +1838,13 @@ "path": "farfhs-vpcFromprops/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-vpcFromprops-KINESIS_FIREHOSE-security-group": { @@ -1876,13 +1900,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-vpcFromprops-ECR_API-security-group": { @@ -1938,13 +1962,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farfhs-vpcFromprops-ECR_DKR-security-group": { @@ -2000,13 +2024,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-cluster": { @@ -2022,13 +2046,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-taskdef": { @@ -2044,7 +2068,7 @@ "path": "farfhs-vpcFromprops/test-fargate-kinesisstreams-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2069,7 +2093,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -2112,19 +2136,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2170,7 +2194,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-container": { @@ -2178,13 +2202,13 @@ "path": "farfhs-vpcFromprops/test-fargate-kinesisstreams-taskdef/test-fargate-kinesisstreams-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-sg": { @@ -2212,13 +2236,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-service": { @@ -2270,13 +2294,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -2292,7 +2316,7 @@ "path": "farfhs-vpcFromprops/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -2304,7 +2328,7 @@ "path": "farfhs-vpcFromprops/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2312,25 +2336,25 @@ "path": "farfhs-vpcFromprops/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2338,7 +2362,7 @@ "path": "farfhs-vpcFromprops/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2346,13 +2370,13 @@ "path": "farfhs-vpcFromprops/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2360,13 +2384,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/package.json index 785b2014c..95d75efdb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkin-existingFargateService.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkin-existingFargateService.assets.json index 397ab9629..9ee08a72a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkin-existingFargateService.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkin-existingFargateService.assets.json @@ -1,20 +1,20 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "5c8394fa33caee271877215b79b4b7b7639712530d65bcbf1c13ba56cbaf9999": { + "d30d5464a0686500c2a2050a1a74434ed82ef7417e9bc921bb65f776fbf3944b": { "source": { "path": "farkin-existingFargateService.template.json", "packaging": "file" @@ -22,7 +22,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "5c8394fa33caee271877215b79b4b7b7639712530d65bcbf1c13ba56cbaf9999.json", + "objectKey": "d30d5464a0686500c2a2050a1a74434ed82ef7417e9bc921bb65f776fbf3944b.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkin-existingFargateService.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkin-existingFargateService.template.json index f5f253478..c89caedb0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkin-existingFargateService.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkin-existingFargateService.template.json @@ -578,6 +578,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingFargateService/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -616,6 +622,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingFargateService/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -651,6 +663,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingFargateService/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -689,6 +707,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingFargateService/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -776,7 +800,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkinexistingFargateServiceIntegDefaultTestDeployAssertF1F4EC2C.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkinexistingFargateServiceIntegDefaultTestDeployAssertF1F4EC2C.assets.json index 1a8e8ff0c..597c7caed 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkinexistingFargateServiceIntegDefaultTestDeployAssertF1F4EC2C.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/farkinexistingFargateServiceIntegDefaultTestDeployAssertF1F4EC2C.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/integ.json index 755e94858..6efed0769 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farkin-existingFargateService/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/manifest.json index b2b60035b..7a5b798d0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farkinexistingFargateServiceIntegDefaultTestDeployAssertF1F4EC2C.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/5c8394fa33caee271877215b79b4b7b7639712530d65bcbf1c13ba56cbaf9999.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/d30d5464a0686500c2a2050a1a74434ed82ef7417e9bc921bb65f776fbf3944b.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -280,6 +280,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farkin-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farkin-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/tree.json index 8a6f4051e..16881acce 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingFargateService.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farkin-existingFargateService/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farkin-existingFargateService/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farkin-existingFargateService/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farkin-existingFargateService/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farkin-existingFargateService/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farkin-existingFargateService/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingFargateService/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -891,13 +897,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -910,6 +916,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingFargateService/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -947,13 +959,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -966,6 +978,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingFargateService/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1000,13 +1018,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -1019,6 +1037,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingFargateService/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1056,19 +1080,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1076,7 +1100,7 @@ "path": "farkin-existingFargateService/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1088,7 +1112,7 @@ "path": "farkin-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1096,7 +1120,7 @@ "path": "farkin-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1104,13 +1128,13 @@ "path": "farkin-existingFargateService/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-existingFargateService-ECR_API-security-group": { @@ -1166,13 +1190,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-existingFargateService-ECR_DKR-security-group": { @@ -1228,13 +1252,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1250,13 +1274,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1272,7 +1296,7 @@ "path": "farkin-existingFargateService/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1297,7 +1321,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1339,19 +1363,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1399,7 +1423,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1407,13 +1431,13 @@ "path": "farkin-existingFargateService/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1441,13 +1465,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1499,13 +1523,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams": { @@ -1532,13 +1556,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamGetRecordsIteratorAgeAlarm": { @@ -1563,13 +1587,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -1594,19 +1618,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisstreams.FargateToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "farkin-existingFargateService-KINESIS_STREAMS-security-group": { @@ -1662,13 +1686,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1684,7 +1708,7 @@ "path": "farkin-existingFargateService/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1696,7 +1720,7 @@ "path": "farkin-existingFargateService/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1704,25 +1728,25 @@ "path": "farkin-existingFargateService/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1730,7 +1754,7 @@ "path": "farkin-existingFargateService/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1738,13 +1762,13 @@ "path": "farkin-existingFargateService/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1752,13 +1776,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkin-existingStream.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkin-existingStream.assets.json index d48da1816..b0f10bd9a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkin-existingStream.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkin-existingStream.assets.json @@ -1,20 +1,20 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "1c0d196ae6dc655dccac4c63426c4b830aed739665a8c4a0b9266f5c184802c4": { + "02f768757da11ec532c564045213964ec4e80d5acc5abd714397c5d23988f780": { "source": { "path": "farkin-existingStream.template.json", "packaging": "file" @@ -22,7 +22,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "1c0d196ae6dc655dccac4c63426c4b830aed739665a8c4a0b9266f5c184802c4.json", + "objectKey": "02f768757da11ec532c564045213964ec4e80d5acc5abd714397c5d23988f780.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkin-existingStream.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkin-existingStream.template.json index c794a0a1f..7c6ffb3bc 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkin-existingStream.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkin-existingStream.template.json @@ -619,6 +619,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingStream/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -657,6 +663,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingStream/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -695,6 +707,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingStream/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -730,6 +748,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingStream/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -817,7 +841,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkinexistingStreamIntegDefaultTestDeployAssert24640A36.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkinexistingStreamIntegDefaultTestDeployAssert24640A36.assets.json index afa2a1eb0..d93cd9768 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkinexistingStreamIntegDefaultTestDeployAssert24640A36.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/farkinexistingStreamIntegDefaultTestDeployAssert24640A36.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/integ.json index 2e8d3ab84..9bc7f97e6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farkin-existingStream/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/manifest.json index 597c90fbc..96bfb3bea 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farkinexistingStreamIntegDefaultTestDeployAssert24640A36.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/1c0d196ae6dc655dccac4c63426c4b830aed739665a8c4a0b9266f5c184802c4.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/02f768757da11ec532c564045213964ec4e80d5acc5abd714397c5d23988f780.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -298,6 +298,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farkin-existingStream/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farkin-existingStream/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/tree.json index f745a4b13..4219150ab 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingStream.js.snapshot/tree.json @@ -30,13 +30,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams": { @@ -65,13 +65,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -96,19 +96,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisstreams.FargateToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -135,7 +135,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -179,7 +179,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -187,7 +187,7 @@ "path": "farkin-existingStream/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -209,7 +209,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -228,7 +228,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -248,7 +248,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -268,7 +268,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -296,13 +296,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -346,7 +346,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -354,7 +354,7 @@ "path": "farkin-existingStream/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -376,7 +376,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -395,7 +395,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -415,7 +415,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -435,7 +435,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -463,13 +463,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -513,7 +513,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -521,7 +521,7 @@ "path": "farkin-existingStream/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -543,7 +543,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -562,7 +562,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -582,13 +582,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -632,7 +632,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -640,7 +640,7 @@ "path": "farkin-existingStream/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -662,7 +662,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -681,7 +681,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -701,13 +701,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -726,7 +726,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -745,7 +745,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -757,13 +757,13 @@ "path": "farkin-existingStream/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -779,7 +779,7 @@ "path": "farkin-existingStream/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -810,7 +810,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -862,19 +862,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -898,13 +898,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -938,13 +938,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -957,6 +957,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingStream/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -994,13 +1000,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1013,6 +1019,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingStream/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1050,13 +1062,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1069,6 +1081,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingStream/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1106,13 +1124,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1125,6 +1143,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingStream/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1159,19 +1183,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1179,7 +1203,7 @@ "path": "farkin-existingStream/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1191,7 +1215,7 @@ "path": "farkin-existingStream/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1199,7 +1223,7 @@ "path": "farkin-existingStream/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1207,13 +1231,13 @@ "path": "farkin-existingStream/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-existingStream-KINESIS_STREAMS-security-group": { @@ -1269,13 +1293,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-existingStream-ECR_API-security-group": { @@ -1331,13 +1355,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-existingStream-ECR_DKR-security-group": { @@ -1393,13 +1417,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-cluster": { @@ -1415,13 +1439,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-taskdef": { @@ -1437,7 +1461,7 @@ "path": "farkin-existingStream/test-fargate-kinesisstreams-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1462,7 +1486,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1504,19 +1528,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1564,7 +1588,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-container": { @@ -1572,13 +1596,13 @@ "path": "farkin-existingStream/test-fargate-kinesisstreams-taskdef/test-fargate-kinesisstreams-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-sg": { @@ -1606,13 +1630,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-service": { @@ -1664,13 +1688,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1686,7 +1710,7 @@ "path": "farkin-existingStream/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1698,7 +1722,7 @@ "path": "farkin-existingStream/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1706,25 +1730,25 @@ "path": "farkin-existingStream/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1732,7 +1756,7 @@ "path": "farkin-existingStream/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1740,13 +1764,13 @@ "path": "farkin-existingStream/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1754,13 +1778,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkin-existingVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkin-existingVpc.assets.json index b36882575..9269f8d05 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkin-existingVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkin-existingVpc.assets.json @@ -1,20 +1,20 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "7e7bd0a42766266a48a4fdb48fc7bfae175179befff26b0248213d00b4ff40f6": { + "ea5d2f3a7d0af442a5bfc3f377b8ae7dee5d0b0861222520354c01f08b6e6a8d": { "source": { "path": "farkin-existingVpc.template.json", "packaging": "file" @@ -22,7 +22,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "7e7bd0a42766266a48a4fdb48fc7bfae175179befff26b0248213d00b4ff40f6.json", + "objectKey": "ea5d2f3a7d0af442a5bfc3f377b8ae7dee5d0b0861222520354c01f08b6e6a8d.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkin-existingVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkin-existingVpc.template.json index 7f9a9498f..944f20584 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkin-existingVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkin-existingVpc.template.json @@ -578,6 +578,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -616,6 +622,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -654,6 +666,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -689,6 +707,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farkin-existingVpc/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -776,7 +800,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkinexistingVpcIntegDefaultTestDeployAssert8065A04A.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkinexistingVpcIntegDefaultTestDeployAssert8065A04A.assets.json index 381a34364..5ed2d61ec 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkinexistingVpcIntegDefaultTestDeployAssert8065A04A.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/farkinexistingVpcIntegDefaultTestDeployAssert8065A04A.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/integ.json index ea0bdb437..482b15b8f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farkin-existingVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/manifest.json index b65457d87..f199bda37 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farkinexistingVpcIntegDefaultTestDeployAssert8065A04A.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/7e7bd0a42766266a48a4fdb48fc7bfae175179befff26b0248213d00b4ff40f6.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/ea5d2f3a7d0af442a5bfc3f377b8ae7dee5d0b0861222520354c01f08b6e6a8d.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -280,6 +280,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/tree.json index f53bc97b0..1f96831b8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-existingVpc.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farkin-existingVpc/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farkin-existingVpc/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farkin-existingVpc/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farkin-existingVpc/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farkin-existingVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farkin-existingVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -891,13 +897,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -910,6 +916,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -947,13 +959,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -966,6 +978,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1003,13 +1021,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1022,6 +1040,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-existingVpc/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1056,19 +1080,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1076,7 +1100,7 @@ "path": "farkin-existingVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1088,7 +1112,7 @@ "path": "farkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1096,7 +1120,7 @@ "path": "farkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1104,13 +1128,13 @@ "path": "farkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams": { @@ -1137,13 +1161,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamGetRecordsIteratorAgeAlarm": { @@ -1168,13 +1192,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -1199,19 +1223,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisstreams.FargateToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "farkin-existingVpc-KINESIS_STREAMS-security-group": { @@ -1267,13 +1291,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-existingVpc-ECR_API-security-group": { @@ -1329,13 +1353,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-existingVpc-ECR_DKR-security-group": { @@ -1391,13 +1415,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-cluster": { @@ -1413,13 +1437,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-taskdef": { @@ -1435,7 +1459,7 @@ "path": "farkin-existingVpc/test-fargate-kinesisstreams-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1460,7 +1484,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1502,19 +1526,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1562,7 +1586,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-container": { @@ -1570,13 +1594,13 @@ "path": "farkin-existingVpc/test-fargate-kinesisstreams-taskdef/test-fargate-kinesisstreams-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-sg": { @@ -1604,13 +1628,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-service": { @@ -1662,13 +1686,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1684,7 +1708,7 @@ "path": "farkin-existingVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1696,7 +1720,7 @@ "path": "farkin-existingVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1704,25 +1728,25 @@ "path": "farkin-existingVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1730,7 +1754,7 @@ "path": "farkin-existingVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1738,13 +1762,13 @@ "path": "farkin-existingVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1752,13 +1776,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkin-fargateServiceFromProps.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkin-fargateServiceFromProps.assets.json index 4eec9204d..0ca98dc05 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkin-fargateServiceFromProps.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkin-fargateServiceFromProps.assets.json @@ -1,20 +1,20 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "6c070517b1b20a616b1e030689053bc48c278dee702688dab38eb3e8b6b08483": { + "baec867d045b3ff0488913f145b7eabf823cca6186e1af4bea81c67f52af5459": { "source": { "path": "farkin-fargateServiceFromProps.template.json", "packaging": "file" @@ -22,7 +22,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "6c070517b1b20a616b1e030689053bc48c278dee702688dab38eb3e8b6b08483.json", + "objectKey": "baec867d045b3ff0488913f145b7eabf823cca6186e1af4bea81c67f52af5459.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkin-fargateServiceFromProps.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkin-fargateServiceFromProps.template.json index 0e1f01dae..bd43c4832 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkin-fargateServiceFromProps.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkin-fargateServiceFromProps.template.json @@ -617,6 +617,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-fargateServiceFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -655,6 +661,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-fargateServiceFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -693,6 +705,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-fargateServiceFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -728,6 +746,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farkin-fargateServiceFromProps/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -815,7 +839,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkinfargateServiceFromPropsIntegDefaultTestDeployAssert5047AEA2.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkinfargateServiceFromPropsIntegDefaultTestDeployAssert5047AEA2.assets.json index d0c9c68a1..d8b1bb37f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkinfargateServiceFromPropsIntegDefaultTestDeployAssert5047AEA2.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/farkinfargateServiceFromPropsIntegDefaultTestDeployAssert5047AEA2.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/integ.json index 2cb70aded..7fe88c6a7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farkin-fargateServiceFromProps/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/manifest.json index 6532621c7..3b0a53b8e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farkinfargateServiceFromPropsIntegDefaultTestDeployAssert5047AEA2.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/6c070517b1b20a616b1e030689053bc48c278dee702688dab38eb3e8b6b08483.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/baec867d045b3ff0488913f145b7eabf823cca6186e1af4bea81c67f52af5459.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -298,6 +298,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farkin-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farkin-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/tree.json index 032afc0c4..9bad82c8c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-fargateServiceFromProps.js.snapshot/tree.json @@ -32,13 +32,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamGetRecordsIteratorAgeAlarm": { @@ -63,13 +63,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -94,19 +94,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisstreams.FargateToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -133,7 +133,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -177,7 +177,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -185,7 +185,7 @@ "path": "farkin-fargateServiceFromProps/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -207,7 +207,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -226,7 +226,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -246,7 +246,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -266,7 +266,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -294,13 +294,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -344,7 +344,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -352,7 +352,7 @@ "path": "farkin-fargateServiceFromProps/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -374,7 +374,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -393,7 +393,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -413,7 +413,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -433,7 +433,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -461,13 +461,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -511,7 +511,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -519,7 +519,7 @@ "path": "farkin-fargateServiceFromProps/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -541,7 +541,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -560,7 +560,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -580,13 +580,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -630,7 +630,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -638,7 +638,7 @@ "path": "farkin-fargateServiceFromProps/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -660,7 +660,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -679,7 +679,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -699,13 +699,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -724,7 +724,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -743,7 +743,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -755,13 +755,13 @@ "path": "farkin-fargateServiceFromProps/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -777,7 +777,7 @@ "path": "farkin-fargateServiceFromProps/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -808,7 +808,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -860,19 +860,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -896,13 +896,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -936,13 +936,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -955,6 +955,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-fargateServiceFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -992,13 +998,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1011,6 +1017,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-fargateServiceFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1048,13 +1060,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1067,6 +1079,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-fargateServiceFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1104,13 +1122,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1123,6 +1141,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-fargateServiceFromProps/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1157,19 +1181,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1177,7 +1201,7 @@ "path": "farkin-fargateServiceFromProps/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1189,7 +1213,7 @@ "path": "farkin-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1197,7 +1221,7 @@ "path": "farkin-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1205,13 +1229,13 @@ "path": "farkin-fargateServiceFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-fargateServiceFromProps-KINESIS_STREAMS-security-group": { @@ -1267,13 +1291,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-fargateServiceFromProps-ECR_API-security-group": { @@ -1329,13 +1353,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-fargateServiceFromProps-ECR_DKR-security-group": { @@ -1391,13 +1415,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-cluster": { @@ -1413,13 +1437,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-taskdef": { @@ -1435,7 +1459,7 @@ "path": "farkin-fargateServiceFromProps/test-fargate-kinesisstreams-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1460,7 +1484,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1502,19 +1526,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1562,7 +1586,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-container": { @@ -1570,13 +1594,13 @@ "path": "farkin-fargateServiceFromProps/test-fargate-kinesisstreams-taskdef/test-fargate-kinesisstreams-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-sg": { @@ -1604,13 +1628,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-service": { @@ -1663,13 +1687,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1685,7 +1709,7 @@ "path": "farkin-fargateServiceFromProps/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1697,7 +1721,7 @@ "path": "farkin-fargateServiceFromProps/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1705,25 +1729,25 @@ "path": "farkin-fargateServiceFromProps/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1731,7 +1755,7 @@ "path": "farkin-fargateServiceFromProps/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1739,13 +1763,13 @@ "path": "farkin-fargateServiceFromProps/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1753,13 +1777,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkin-noArguments.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkin-noArguments.assets.json index 7b10e7fc4..9a89be88b 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkin-noArguments.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkin-noArguments.assets.json @@ -1,20 +1,20 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "d7c7472bf3d80a5ee7b57e7c25a5f0ee65dd3a4372eebc84bcf4dd1aec763249": { + "acbd2ef887a9404592ebf00425a1993054eaf53cbacc3aabd2f06accc0d28cf7": { "source": { "path": "farkin-noArguments.template.json", "packaging": "file" @@ -22,7 +22,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "d7c7472bf3d80a5ee7b57e7c25a5f0ee65dd3a4372eebc84bcf4dd1aec763249.json", + "objectKey": "acbd2ef887a9404592ebf00425a1993054eaf53cbacc3aabd2f06accc0d28cf7.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkin-noArguments.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkin-noArguments.template.json index 015616093..91a83183f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkin-noArguments.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkin-noArguments.template.json @@ -617,6 +617,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-noArguments/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -655,6 +661,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-noArguments/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -693,6 +705,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-noArguments/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -728,6 +746,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farkin-noArguments/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -815,7 +839,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkinnoArgumentsIntegDefaultTestDeployAssert5E204AE6.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkinnoArgumentsIntegDefaultTestDeployAssert5E204AE6.assets.json index 8f9d9074e..6e173b5ab 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkinnoArgumentsIntegDefaultTestDeployAssert5E204AE6.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/farkinnoArgumentsIntegDefaultTestDeployAssert5E204AE6.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/integ.json index 294730cc1..d97506050 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farkin-noArguments/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/manifest.json index ff92394e3..d294d93eb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farkinnoArgumentsIntegDefaultTestDeployAssert5E204AE6.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/d7c7472bf3d80a5ee7b57e7c25a5f0ee65dd3a4372eebc84bcf4dd1aec763249.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/acbd2ef887a9404592ebf00425a1993054eaf53cbacc3aabd2f06accc0d28cf7.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -298,6 +298,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farkin-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farkin-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/tree.json index 13a4d9e9b..dd7f24f6e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-noArguments.js.snapshot/tree.json @@ -32,13 +32,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamGetRecordsIteratorAgeAlarm": { @@ -63,13 +63,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -94,19 +94,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisstreams.FargateToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -133,7 +133,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -177,7 +177,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -185,7 +185,7 @@ "path": "farkin-noArguments/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -207,7 +207,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -226,7 +226,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -246,7 +246,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -266,7 +266,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -294,13 +294,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -344,7 +344,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -352,7 +352,7 @@ "path": "farkin-noArguments/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -374,7 +374,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -393,7 +393,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -413,7 +413,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -433,7 +433,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -461,13 +461,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -511,7 +511,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -519,7 +519,7 @@ "path": "farkin-noArguments/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -541,7 +541,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -560,7 +560,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -580,13 +580,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -630,7 +630,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -638,7 +638,7 @@ "path": "farkin-noArguments/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -660,7 +660,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -679,7 +679,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -699,13 +699,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -724,7 +724,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -743,7 +743,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -755,13 +755,13 @@ "path": "farkin-noArguments/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -777,7 +777,7 @@ "path": "farkin-noArguments/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -808,7 +808,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -860,19 +860,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -896,13 +896,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -936,13 +936,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -955,6 +955,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-noArguments/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -992,13 +998,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1011,6 +1017,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-noArguments/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1048,13 +1060,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1067,6 +1079,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-noArguments/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1104,13 +1122,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1123,6 +1141,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-noArguments/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1157,19 +1181,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1177,7 +1201,7 @@ "path": "farkin-noArguments/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1189,7 +1213,7 @@ "path": "farkin-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1197,7 +1221,7 @@ "path": "farkin-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1205,13 +1229,13 @@ "path": "farkin-noArguments/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-noArguments-KINESIS_STREAMS-security-group": { @@ -1267,13 +1291,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-noArguments-ECR_API-security-group": { @@ -1329,13 +1353,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-noArguments-ECR_DKR-security-group": { @@ -1391,13 +1415,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-cluster": { @@ -1413,13 +1437,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-taskdef": { @@ -1435,7 +1459,7 @@ "path": "farkin-noArguments/test-fargate-kinesisstreams-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1460,7 +1484,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1502,19 +1526,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1562,7 +1586,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-container": { @@ -1570,13 +1594,13 @@ "path": "farkin-noArguments/test-fargate-kinesisstreams-taskdef/test-fargate-kinesisstreams-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-sg": { @@ -1604,13 +1628,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-service": { @@ -1662,13 +1686,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1684,7 +1708,7 @@ "path": "farkin-noArguments/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1696,7 +1720,7 @@ "path": "farkin-noArguments/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1704,25 +1728,25 @@ "path": "farkin-noArguments/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1730,7 +1754,7 @@ "path": "farkin-noArguments/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1738,13 +1762,13 @@ "path": "farkin-noArguments/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1752,13 +1776,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkin-streamFromProps.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkin-streamFromProps.assets.json index 44c9b5aac..32dd9299f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkin-streamFromProps.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkin-streamFromProps.assets.json @@ -1,20 +1,20 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "cbda5ec0b48245fea92b86ff6b064efd6671bb2d2041ac1cf2f53b022a181631": { + "27b1a735f2b3431d614b7df5a85f62687dedc38d8857cc7fadfbbb001f750e28": { "source": { "path": "farkin-streamFromProps.template.json", "packaging": "file" @@ -22,7 +22,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "cbda5ec0b48245fea92b86ff6b064efd6671bb2d2041ac1cf2f53b022a181631.json", + "objectKey": "27b1a735f2b3431d614b7df5a85f62687dedc38d8857cc7fadfbbb001f750e28.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkin-streamFromProps.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkin-streamFromProps.template.json index 9455c16ee..57df0b89e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkin-streamFromProps.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkin-streamFromProps.template.json @@ -619,6 +619,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-streamFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -657,6 +663,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-streamFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -695,6 +707,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-streamFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -730,6 +748,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farkin-streamFromProps/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -817,7 +841,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkinstreamFromPropsIntegDefaultTestDeployAssertF891650B.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkinstreamFromPropsIntegDefaultTestDeployAssertF891650B.assets.json index da83c3c2d..79127c1d3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkinstreamFromPropsIntegDefaultTestDeployAssertF891650B.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/farkinstreamFromPropsIntegDefaultTestDeployAssertF891650B.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/integ.json index e07483b4a..f840e2a6f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farkin-streamFromProps/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/manifest.json index a3c19f60c..6a1664fb7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farkinstreamFromPropsIntegDefaultTestDeployAssertF891650B.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/cbda5ec0b48245fea92b86ff6b064efd6671bb2d2041ac1cf2f53b022a181631.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/27b1a735f2b3431d614b7df5a85f62687dedc38d8857cc7fadfbbb001f750e28.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -298,6 +298,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farkin-streamFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farkin-streamFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/tree.json index 231bd7d23..798833a33 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-streamFromProps.js.snapshot/tree.json @@ -34,13 +34,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamGetRecordsIteratorAgeAlarm": { @@ -65,13 +65,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -96,19 +96,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisstreams.FargateToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -135,7 +135,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -179,7 +179,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -187,7 +187,7 @@ "path": "farkin-streamFromProps/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -209,7 +209,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -228,7 +228,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -248,7 +248,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -268,7 +268,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -296,13 +296,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -346,7 +346,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -354,7 +354,7 @@ "path": "farkin-streamFromProps/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -376,7 +376,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -395,7 +395,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -415,7 +415,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -435,7 +435,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -463,13 +463,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -513,7 +513,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -521,7 +521,7 @@ "path": "farkin-streamFromProps/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -543,7 +543,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -562,7 +562,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -582,13 +582,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -632,7 +632,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -640,7 +640,7 @@ "path": "farkin-streamFromProps/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -662,7 +662,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -681,7 +681,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -701,13 +701,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -726,7 +726,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -745,7 +745,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -757,13 +757,13 @@ "path": "farkin-streamFromProps/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -779,7 +779,7 @@ "path": "farkin-streamFromProps/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -810,7 +810,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -862,19 +862,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -898,13 +898,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -938,13 +938,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -957,6 +957,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-streamFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -994,13 +1000,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1013,6 +1019,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-streamFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1050,13 +1062,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1069,6 +1081,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-streamFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1106,13 +1124,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1125,6 +1143,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-streamFromProps/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1159,19 +1183,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1179,7 +1203,7 @@ "path": "farkin-streamFromProps/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1191,7 +1215,7 @@ "path": "farkin-streamFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1199,7 +1223,7 @@ "path": "farkin-streamFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1207,13 +1231,13 @@ "path": "farkin-streamFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-streamFromProps-KINESIS_STREAMS-security-group": { @@ -1269,13 +1293,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-streamFromProps-ECR_API-security-group": { @@ -1331,13 +1355,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-streamFromProps-ECR_DKR-security-group": { @@ -1393,13 +1417,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-cluster": { @@ -1415,13 +1439,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-taskdef": { @@ -1437,7 +1461,7 @@ "path": "farkin-streamFromProps/test-fargate-kinesisstreams-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1462,7 +1486,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1504,19 +1528,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1564,7 +1588,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-container": { @@ -1572,13 +1596,13 @@ "path": "farkin-streamFromProps/test-fargate-kinesisstreams-taskdef/test-fargate-kinesisstreams-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-sg": { @@ -1606,13 +1630,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-service": { @@ -1664,13 +1688,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1686,7 +1710,7 @@ "path": "farkin-streamFromProps/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1698,7 +1722,7 @@ "path": "farkin-streamFromProps/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1706,25 +1730,25 @@ "path": "farkin-streamFromProps/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1732,7 +1756,7 @@ "path": "farkin-streamFromProps/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1740,13 +1764,13 @@ "path": "farkin-streamFromProps/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1754,13 +1778,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkin-vpcFromProps.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkin-vpcFromProps.assets.json index a193b5265..08f2562a0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkin-vpcFromProps.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkin-vpcFromProps.assets.json @@ -1,20 +1,20 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "da32318d0529872bd70b079415c3b29ffaca2da2f4d27cf307e18b6c14b67280": { + "5384a3ab16bb2e667fdd602274fed337c157f4f643e08cfefbedd11c3b682e00": { "source": { "path": "farkin-vpcFromProps.template.json", "packaging": "file" @@ -22,7 +22,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "da32318d0529872bd70b079415c3b29ffaca2da2f4d27cf307e18b6c14b67280.json", + "objectKey": "5384a3ab16bb2e667fdd602274fed337c157f4f643e08cfefbedd11c3b682e00.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkin-vpcFromProps.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkin-vpcFromProps.template.json index 72879aa6e..25e481ae8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkin-vpcFromProps.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkin-vpcFromProps.template.json @@ -617,6 +617,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-vpcFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -655,6 +661,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-vpcFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -693,6 +705,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farkin-vpcFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -728,6 +746,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farkin-vpcFromProps/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -815,7 +839,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkinvpcFromPropsIntegDefaultTestDeployAssert05CE38D4.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkinvpcFromPropsIntegDefaultTestDeployAssert05CE38D4.assets.json index 8b39e143c..4d87ef695 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkinvpcFromPropsIntegDefaultTestDeployAssert05CE38D4.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/farkinvpcFromPropsIntegDefaultTestDeployAssert05CE38D4.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/integ.json index 0c9cd4691..8b6066244 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farkin-vpcFromProps/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/manifest.json index 102198463..a25ce0953 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farkinvpcFromPropsIntegDefaultTestDeployAssert05CE38D4.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/da32318d0529872bd70b079415c3b29ffaca2da2f4d27cf307e18b6c14b67280.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/5384a3ab16bb2e667fdd602274fed337c157f4f643e08cfefbedd11c3b682e00.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -298,6 +298,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/farkin-vpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farkin-vpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/tree.json index 3fe2a31bd..9c7058dae 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-kinesisstreams/test/integ.farkin-vpcFromProps.js.snapshot/tree.json @@ -32,13 +32,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamGetRecordsIteratorAgeAlarm": { @@ -63,13 +63,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -94,19 +94,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-kinesisstreams.FargateToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -133,7 +133,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -177,7 +177,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -185,7 +185,7 @@ "path": "farkin-vpcFromProps/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -207,7 +207,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -226,7 +226,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -246,7 +246,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -266,7 +266,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -294,13 +294,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -344,7 +344,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -352,7 +352,7 @@ "path": "farkin-vpcFromProps/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -374,7 +374,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -393,7 +393,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -413,7 +413,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -433,7 +433,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -461,13 +461,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -511,7 +511,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -519,7 +519,7 @@ "path": "farkin-vpcFromProps/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -541,7 +541,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -560,7 +560,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -580,13 +580,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -630,7 +630,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -638,7 +638,7 @@ "path": "farkin-vpcFromProps/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -660,7 +660,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -679,7 +679,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -699,13 +699,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -724,7 +724,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -743,7 +743,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -755,13 +755,13 @@ "path": "farkin-vpcFromProps/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -777,7 +777,7 @@ "path": "farkin-vpcFromProps/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -808,7 +808,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -860,19 +860,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -896,13 +896,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -936,13 +936,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -955,6 +955,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-vpcFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -992,13 +998,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1011,6 +1017,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-vpcFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1048,13 +1060,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1067,6 +1079,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-vpcFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1104,13 +1122,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1123,6 +1141,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farkin-vpcFromProps/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1157,19 +1181,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1177,7 +1201,7 @@ "path": "farkin-vpcFromProps/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1189,7 +1213,7 @@ "path": "farkin-vpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1197,7 +1221,7 @@ "path": "farkin-vpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1205,13 +1229,13 @@ "path": "farkin-vpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-vpcFromProps-KINESIS_STREAMS-security-group": { @@ -1267,13 +1291,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-vpcFromProps-ECR_API-security-group": { @@ -1329,13 +1353,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farkin-vpcFromProps-ECR_DKR-security-group": { @@ -1391,13 +1415,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-cluster": { @@ -1413,13 +1437,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-taskdef": { @@ -1435,7 +1459,7 @@ "path": "farkin-vpcFromProps/test-fargate-kinesisstreams-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1460,7 +1484,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1502,19 +1526,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1562,7 +1586,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-container": { @@ -1570,13 +1594,13 @@ "path": "farkin-vpcFromProps/test-fargate-kinesisstreams-taskdef/test-fargate-kinesisstreams-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-sg": { @@ -1604,13 +1628,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-fargate-kinesisstreams-service": { @@ -1662,13 +1686,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1684,7 +1708,7 @@ "path": "farkin-vpcFromProps/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1696,7 +1720,7 @@ "path": "farkin-vpcFromProps/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1704,25 +1728,25 @@ "path": "farkin-vpcFromProps/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1730,7 +1754,7 @@ "path": "farkin-vpcFromProps/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1738,13 +1762,13 @@ "path": "farkin-vpcFromProps/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1752,13 +1776,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/package.json index 1886faff2..56d335717 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropn-existing-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropn-existing-resources.assets.json index 0766d635c..6d61a9db9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropn-existing-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropn-existing-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "759d0ffe49c44e1b2b8baeb0b9d27042ea9403d7d90fd525e9fc0aa999bde074": { + "7112bdc7635bbff283e50a7265038798803bee8ead84858322743834af749b52": { "source": { "path": "faropn-existing-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "759d0ffe49c44e1b2b8baeb0b9d27042ea9403d7d90fd525e9fc0aa999bde074.json", + "objectKey": "7112bdc7635bbff283e50a7265038798803bee8ead84858322743834af749b52.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropn-existing-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropn-existing-resources.template.json index dd93fd4fd..a15c87e27 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropn-existing-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropn-existing-resources.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "faropn-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "faropn-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "faropn-existing-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -709,7 +727,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropnexistingresourcesIntegDefaultTestDeployAssert753D5E58.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropnexistingresourcesIntegDefaultTestDeployAssert753D5E58.assets.json index 58338add7..5fe2d1f3d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropnexistingresourcesIntegDefaultTestDeployAssert753D5E58.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/faropnexistingresourcesIntegDefaultTestDeployAssert753D5E58.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/integ.json index a6658c012..52efe86a8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "faropn-existing-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/manifest.json index 4a37055ed..9958af9e0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "faropnexistingresourcesIntegDefaultTestDeployAssert753D5E58.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/759d0ffe49c44e1b2b8baeb0b9d27042ea9403d7d90fd525e9fc0aa999bde074.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/7112bdc7635bbff283e50a7265038798803bee8ead84858322743834af749b52.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -268,6 +268,12 @@ "data": "VpcS3A5408339" } ], + "/faropn-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/faropn-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/tree.json index 550c11d05..790fd8986 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-existing-resources.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "faropn-existing-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "faropn-existing-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "faropn-existing-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "faropn-existing-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "faropn-existing-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "faropn-existing-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "faropn-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "faropn-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "faropn-existing-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,19 +996,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1002,7 +1020,7 @@ "path": "faropn-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1010,7 +1028,7 @@ "path": "faropn-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1018,13 +1036,13 @@ "path": "faropn-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "faropn-existing-resources-ECR_API-security-group": { @@ -1080,13 +1098,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "faropn-existing-resources-ECR_DKR-security-group": { @@ -1142,13 +1160,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1164,13 +1182,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1186,7 +1204,7 @@ "path": "faropn-existing-resources/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1211,13 +1229,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1268,7 +1286,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1276,13 +1294,13 @@ "path": "faropn-existing-resources/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1310,13 +1328,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1368,13 +1386,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1422,13 +1440,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnUserPool", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.UserPool", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoUserPoolClient": { @@ -1466,13 +1484,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnUserPoolClient", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.UserPoolClient", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoIdentityPool": { @@ -1500,7 +1518,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnIdentityPool", - "version": "2.150.0" + "version": "2.174.0" } }, "UserPoolDomain": { @@ -1547,7 +1565,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnUserPoolDomain", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoAuthorizedRole": { @@ -1559,7 +1577,7 @@ "path": "faropn-existing-resources/test-construct/CognitoAuthorizedRole/ImportCognitoAuthorizedRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1660,13 +1678,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "IdentityPoolRoleMapping": { @@ -1690,7 +1708,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnIdentityPoolRoleAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoDashboardConfigureRole": { @@ -1702,7 +1720,7 @@ "path": "faropn-existing-resources/test-construct/CognitoDashboardConfigureRole/ImportCognitoDashboardConfigureRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1727,13 +1745,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoDashboardConfigureRolePolicy": { @@ -1875,13 +1893,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } }, "OpenSearchDomain": { @@ -2054,7 +2072,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_opensearchservice.CfnDomain", - "version": "2.150.0" + "version": "2.174.0" } }, "StatusRedAlarm": { @@ -2079,13 +2097,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "StatusYellowAlarm": { @@ -2110,13 +2128,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "FreeStorageSpaceTooLowAlarm": { @@ -2141,13 +2159,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "IndexWritesBlockedTooHighAlarm": { @@ -2172,13 +2190,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "AutomatedSnapshotFailureTooHighAlarm": { @@ -2203,13 +2221,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "CPUUtilizationTooHighAlarm": { @@ -2234,13 +2252,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "JVMMemoryPressureTooHighAlarm": { @@ -2265,13 +2283,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "MasterCPUUtilizationTooHighAlarm": { @@ -2296,13 +2314,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "MasterJVMMemoryPressureTooHighAlarm": { @@ -2327,19 +2345,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-opensearch.FargateToOpenSearch", - "version": "2.63.0" + "version": "2.76.0" } }, "Integ": { @@ -2355,7 +2373,7 @@ "path": "faropn-existing-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -2367,7 +2385,7 @@ "path": "faropn-existing-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2375,25 +2393,25 @@ "path": "faropn-existing-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2401,7 +2419,7 @@ "path": "faropn-existing-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2409,13 +2427,13 @@ "path": "faropn-existing-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2423,13 +2441,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropn-new-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropn-new-resources.assets.json index 059d0f0e2..db0e6281a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropn-new-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropn-new-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "1ca20800ff127f73fc22d334271e6ad7adca5115fe47b171239c34c90d7f7b92": { + "535c92b36e13738fad084cc72163a8dafd62e1abf3ec853140eac740e7a16508": { "source": { "path": "faropn-new-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "1ca20800ff127f73fc22d334271e6ad7adca5115fe47b171239c34c90d7f7b92.json", + "objectKey": "535c92b36e13738fad084cc72163a8dafd62e1abf3ec853140eac740e7a16508.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropn-new-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropn-new-resources.template.json index 1e412851d..588fd80fa 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropn-new-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropn-new-resources.template.json @@ -1254,6 +1254,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "faropn-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1281,6 +1287,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "faropn-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1316,6 +1328,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "faropn-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -1395,7 +1413,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropnnewresourcesIntegDefaultTestDeployAssert740558EF.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropnnewresourcesIntegDefaultTestDeployAssert740558EF.assets.json index b69e57b44..9bbda034f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropnnewresourcesIntegDefaultTestDeployAssert740558EF.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/faropnnewresourcesIntegDefaultTestDeployAssert740558EF.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/integ.json index d6737307d..69474ec9d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "faropn-new-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/manifest.json index a33911753..392e662d7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "faropnnewresourcesIntegDefaultTestDeployAssert740558EF.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/1ca20800ff127f73fc22d334271e6ad7adca5115fe47b171239c34c90d7f7b92.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/535c92b36e13738fad084cc72163a8dafd62e1abf3ec853140eac740e7a16508.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -376,6 +376,12 @@ "data": "VpcS3A5408339" } ], + "/faropn-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/faropn-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/tree.json index 31c86719b..051954c00 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-opensearch/test/integ.faropn-new-resources.js.snapshot/tree.json @@ -53,13 +53,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnUserPool", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.UserPool", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoUserPoolClient": { @@ -97,13 +97,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnUserPoolClient", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.UserPoolClient", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoIdentityPool": { @@ -131,7 +131,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnIdentityPool", - "version": "2.150.0" + "version": "2.174.0" } }, "UserPoolDomain": { @@ -178,7 +178,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnUserPoolDomain", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoAuthorizedRole": { @@ -190,7 +190,7 @@ "path": "faropn-new-resources/test-construct/CognitoAuthorizedRole/ImportCognitoAuthorizedRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -291,13 +291,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "IdentityPoolRoleMapping": { @@ -321,7 +321,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cognito.CfnIdentityPoolRoleAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoDashboardConfigureRole": { @@ -333,7 +333,7 @@ "path": "faropn-new-resources/test-construct/CognitoDashboardConfigureRole/ImportCognitoDashboardConfigureRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -358,13 +358,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "CognitoDashboardConfigureRolePolicy": { @@ -506,13 +506,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } }, "OpenSearchDomain": { @@ -685,7 +685,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_opensearchservice.CfnDomain", - "version": "2.150.0" + "version": "2.174.0" } }, "StatusRedAlarm": { @@ -710,13 +710,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "StatusYellowAlarm": { @@ -741,13 +741,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "FreeStorageSpaceTooLowAlarm": { @@ -772,13 +772,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "IndexWritesBlockedTooHighAlarm": { @@ -803,13 +803,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "AutomatedSnapshotFailureTooHighAlarm": { @@ -834,13 +834,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "CPUUtilizationTooHighAlarm": { @@ -865,13 +865,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "JVMMemoryPressureTooHighAlarm": { @@ -896,13 +896,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "MasterCPUUtilizationTooHighAlarm": { @@ -927,13 +927,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "MasterJVMMemoryPressureTooHighAlarm": { @@ -958,19 +958,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-opensearch.FargateToOpenSearch", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -997,7 +997,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -1041,7 +1041,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1049,7 +1049,7 @@ "path": "faropn-new-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1071,7 +1071,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1090,7 +1090,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1110,7 +1110,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -1130,7 +1130,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -1158,13 +1158,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -1208,7 +1208,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1216,7 +1216,7 @@ "path": "faropn-new-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1238,7 +1238,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1257,7 +1257,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1277,7 +1277,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -1297,7 +1297,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -1325,13 +1325,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -1375,7 +1375,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1383,7 +1383,7 @@ "path": "faropn-new-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1405,7 +1405,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1424,7 +1424,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1444,13 +1444,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -1494,7 +1494,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1502,7 +1502,7 @@ "path": "faropn-new-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1524,7 +1524,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1543,7 +1543,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1563,13 +1563,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -1588,7 +1588,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -1607,7 +1607,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -1619,13 +1619,13 @@ "path": "faropn-new-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1641,7 +1641,7 @@ "path": "faropn-new-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1672,7 +1672,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1724,19 +1724,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -1760,13 +1760,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1800,13 +1800,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1819,6 +1819,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "faropn-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1845,13 +1851,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1864,6 +1870,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "faropn-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1890,13 +1902,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1909,6 +1921,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "faropn-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1943,19 +1961,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1967,7 +1985,7 @@ "path": "faropn-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1975,7 +1993,7 @@ "path": "faropn-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1983,13 +2001,13 @@ "path": "faropn-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "faropn-new-resources-ECR_API-security-group": { @@ -2045,13 +2063,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "faropn-new-resources-ECR_DKR-security-group": { @@ -2107,13 +2125,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -2129,13 +2147,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -2151,7 +2169,7 @@ "path": "faropn-new-resources/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2176,13 +2194,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -2233,7 +2251,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -2241,13 +2259,13 @@ "path": "faropn-new-resources/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -2275,13 +2293,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -2333,13 +2351,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -2355,7 +2373,7 @@ "path": "faropn-new-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -2367,7 +2385,7 @@ "path": "faropn-new-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2375,25 +2393,25 @@ "path": "faropn-new-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2401,7 +2419,7 @@ "path": "faropn-new-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2409,13 +2427,13 @@ "path": "faropn-new-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2423,13 +2441,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/package.json index d5a0c1075..d8040ba7e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3-existing-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3-existing-resources.assets.json index d90f6ddd1..428dc537d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3-existing-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3-existing-resources.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } @@ -29,7 +29,7 @@ } } }, - "832d64117bc79745919480dd9f484134157e456df0e5622194b8128aa13b523f": { + "f16e264e082331e019fe6772947ff9eead186293085c16ed46bce4a86f1e5e1a": { "source": { "path": "fars3-existing-resources.template.json", "packaging": "file" @@ -37,7 +37,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "832d64117bc79745919480dd9f484134157e456df0e5622194b8128aa13b523f.json", + "objectKey": "f16e264e082331e019fe6772947ff9eead186293085c16ed46bce4a86f1e5e1a.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3-existing-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3-existing-resources.template.json index d594851a9..64e42e1a0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3-existing-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3-existing-resources.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "fars3-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "fars3-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "fars3-existing-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -709,7 +727,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3existingresourcesIntegDefaultTestDeployAssert7461A828.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3existingresourcesIntegDefaultTestDeployAssert7461A828.assets.json index 9783ffa69..ce25a1049 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3existingresourcesIntegDefaultTestDeployAssert7461A828.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/fars3existingresourcesIntegDefaultTestDeployAssert7461A828.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/integ.json index 660f64dc8..466bf5316 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "fars3-existing-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/manifest.json index 9a7034b4b..0737d2041 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "fars3existingresourcesIntegDefaultTestDeployAssert7461A828.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/832d64117bc79745919480dd9f484134157e456df0e5622194b8128aa13b523f.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/f16e264e082331e019fe6772947ff9eead186293085c16ed46bce4a86f1e5e1a.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -268,6 +268,12 @@ "data": "VpcS3A5408339" } ], + "/fars3-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/fars3-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -298,6 +304,12 @@ "data": "scrapBucketLogAutoDeleteObjectsCustomResource307F3D47" } ], + "/fars3-existing-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/fars3-existing-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/tree.json index aa4e6007d..715324f25 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-existing-resources.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "fars3-existing-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "fars3-existing-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "fars3-existing-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "fars3-existing-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "fars3-existing-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "fars3-existing-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "fars3-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "fars3-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "fars3-existing-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,19 +996,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1002,7 +1020,7 @@ "path": "fars3-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1010,7 +1028,7 @@ "path": "fars3-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1018,13 +1036,13 @@ "path": "fars3-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "scrapBucketLog": { @@ -1059,7 +1077,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -1193,13 +1211,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -1211,19 +1229,19 @@ "path": "fars3-existing-resources/scrapBucketLog/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -1235,7 +1253,7 @@ "path": "fars3-existing-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1243,7 +1261,7 @@ "path": "fars3-existing-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1251,13 +1269,13 @@ "path": "fars3-existing-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "scrapBucket": { @@ -1297,7 +1315,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -1395,13 +1413,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -1413,19 +1431,19 @@ "path": "fars3-existing-resources/scrapBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "fars3-existing-resources-ECR_API-security-group": { @@ -1481,13 +1499,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "fars3-existing-resources-ECR_DKR-security-group": { @@ -1543,13 +1561,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1565,13 +1583,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1587,7 +1605,7 @@ "path": "fars3-existing-resources/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1612,7 +1630,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1691,19 +1709,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1760,7 +1778,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1768,13 +1786,13 @@ "path": "fars3-existing-resources/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1802,13 +1820,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1860,13 +1878,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1874,7 +1892,7 @@ "path": "fars3-existing-resources/test-construct", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-s3.FargateToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "Integ": { @@ -1890,7 +1908,7 @@ "path": "fars3-existing-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1902,7 +1920,7 @@ "path": "fars3-existing-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1910,25 +1928,25 @@ "path": "fars3-existing-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1936,7 +1954,7 @@ "path": "fars3-existing-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1944,13 +1962,13 @@ "path": "fars3-existing-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1958,13 +1976,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3-new-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3-new-resources.assets.json index 731c0a25d..8775f2879 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3-new-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3-new-resources.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } @@ -29,7 +29,7 @@ } } }, - "eacec4362785da6cbbedf507c028c6bedfab9131a4f0b4a72775c49c503e71f7": { + "78baccc3dbd65cf59fb06f426b267f3994893f58a0d3f07f6c8a6a8dbd7e1055": { "source": { "path": "fars3-new-resources.template.json", "packaging": "file" @@ -37,7 +37,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "eacec4362785da6cbbedf507c028c6bedfab9131a4f0b4a72775c49c503e71f7.json", + "objectKey": "78baccc3dbd65cf59fb06f426b267f3994893f58a0d3f07f6c8a6a8dbd7e1055.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3-new-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3-new-resources.template.json index 488f4e78f..a71847311 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3-new-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3-new-resources.template.json @@ -912,6 +912,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "fars3-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -939,6 +945,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "fars3-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -966,6 +978,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "fars3-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1045,7 +1063,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3newresourcesIntegDefaultTestDeployAssert2400E90B.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3newresourcesIntegDefaultTestDeployAssert2400E90B.assets.json index 622a419db..236690247 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3newresourcesIntegDefaultTestDeployAssert2400E90B.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/fars3newresourcesIntegDefaultTestDeployAssert2400E90B.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/integ.json index 69c771af2..2ee766ee6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "fars3-new-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/manifest.json index f8e9801c8..e2b52cf0e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "fars3newresourcesIntegDefaultTestDeployAssert2400E90B.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/eacec4362785da6cbbedf507c028c6bedfab9131a4f0b4a72775c49c503e71f7.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/78baccc3dbd65cf59fb06f426b267f3994893f58a0d3f07f6c8a6a8dbd7e1055.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -304,6 +304,12 @@ "data": "VpcECRDKR604E039F" } ], + "/fars3-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/fars3-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -364,6 +370,12 @@ "data": "testconstructserviceService13074A8F" } ], + "/fars3-new-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/fars3-new-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/tree.json index 2d33abb26..efb81b6c2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-s3/test/integ.fars3-new-resources.js.snapshot/tree.json @@ -50,7 +50,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -184,13 +184,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -202,19 +202,19 @@ "path": "fars3-new-resources/test-construct/S3LoggingBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "S3Bucket": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -371,13 +371,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -389,25 +389,25 @@ "path": "fars3-new-resources/test-construct/S3Bucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-s3.FargateToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -434,7 +434,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -478,7 +478,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -486,7 +486,7 @@ "path": "fars3-new-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -508,7 +508,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -527,7 +527,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -547,7 +547,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -567,7 +567,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -595,13 +595,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -645,7 +645,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -653,7 +653,7 @@ "path": "fars3-new-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -675,7 +675,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -694,7 +694,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -714,7 +714,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -734,7 +734,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -762,13 +762,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -812,7 +812,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -820,7 +820,7 @@ "path": "fars3-new-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -842,7 +842,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -861,7 +861,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -881,13 +881,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -931,7 +931,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -939,7 +939,7 @@ "path": "fars3-new-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -961,7 +961,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -980,7 +980,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1000,13 +1000,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -1025,7 +1025,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -1044,7 +1044,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -1056,13 +1056,13 @@ "path": "fars3-new-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1078,7 +1078,7 @@ "path": "fars3-new-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1109,7 +1109,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1161,19 +1161,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -1197,13 +1197,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1237,13 +1237,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1256,6 +1256,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "fars3-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1290,13 +1296,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1309,6 +1315,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "fars3-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1335,13 +1347,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1354,6 +1366,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "fars3-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1380,19 +1398,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1404,7 +1422,7 @@ "path": "fars3-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1412,7 +1430,7 @@ "path": "fars3-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1420,13 +1438,13 @@ "path": "fars3-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "fars3-new-resources-ECR_API-security-group": { @@ -1482,13 +1500,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "fars3-new-resources-ECR_DKR-security-group": { @@ -1544,13 +1562,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1566,13 +1584,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1588,7 +1606,7 @@ "path": "fars3-new-resources/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1613,7 +1631,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1674,19 +1692,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1743,7 +1761,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -1751,13 +1769,13 @@ "path": "fars3-new-resources/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -1785,13 +1803,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -1843,13 +1861,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -1861,7 +1879,7 @@ "path": "fars3-new-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1869,7 +1887,7 @@ "path": "fars3-new-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1877,13 +1895,13 @@ "path": "fars3-new-resources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1899,7 +1917,7 @@ "path": "fars3-new-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1911,7 +1929,7 @@ "path": "fars3-new-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1919,25 +1937,25 @@ "path": "fars3-new-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1945,7 +1963,7 @@ "path": "fars3-new-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1953,13 +1971,13 @@ "path": "fars3-new-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1967,13 +1985,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/package.json index 3d2cea85b..8ece83914 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsec-existing-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsec-existing-resources.assets.json index b2578d788..bdbf6ff8d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsec-existing-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsec-existing-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "d9d96082898e09cd2da4248997427639fd9ae771c184cbbeb9c6e2ecbb4b2568": { + "3521e1e155228b3149d1780235a5cc140218c213db6282a15f7e319a11e1d33d": { "source": { "path": "farsec-existing-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "d9d96082898e09cd2da4248997427639fd9ae771c184cbbeb9c6e2ecbb4b2568.json", + "objectKey": "3521e1e155228b3149d1780235a5cc140218c213db6282a15f7e319a11e1d33d.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsec-existing-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsec-existing-resources.template.json index 58910a918..cd82ef6db 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsec-existing-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsec-existing-resources.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsec-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsec-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farsec-existing-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -657,6 +675,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsec-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -736,7 +760,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsecexistingresourcesIntegDefaultTestDeployAssert0D91D517.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsecexistingresourcesIntegDefaultTestDeployAssert0D91D517.assets.json index 21720aae9..5b38bce63 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsecexistingresourcesIntegDefaultTestDeployAssert0D91D517.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/farsecexistingresourcesIntegDefaultTestDeployAssert0D91D517.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/integ.json index 299f93fc7..1a7ce5a62 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farsec-existing-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/manifest.json index 95ed5e1de..715c4c8a3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farsecexistingresourcesIntegDefaultTestDeployAssert0D91D517.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/d9d96082898e09cd2da4248997427639fd9ae771c184cbbeb9c6e2ecbb4b2568.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/3521e1e155228b3149d1780235a5cc140218c213db6282a15f7e319a11e1d33d.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -274,6 +274,12 @@ "data": "VpcSECRETSMANAGERF52907C2" } ], + "/farsec-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farsec-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/tree.json index 69c080c80..912117446 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-existing-resources.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farsec-existing-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farsec-existing-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farsec-existing-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farsec-existing-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farsec-existing-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farsec-existing-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsec-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsec-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsec-existing-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,13 +996,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "SECRETS_MANAGER": { @@ -997,6 +1015,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsec-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1023,19 +1047,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1047,7 +1071,7 @@ "path": "farsec-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1055,7 +1079,7 @@ "path": "farsec-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1063,13 +1087,13 @@ "path": "farsec-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "secret": { @@ -1087,13 +1111,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_secretsmanager.CfnSecret", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_secretsmanager.Secret", - "version": "2.150.0" + "version": "2.174.0" } }, "farsec-existing-resources-ECR_API-security-group": { @@ -1149,13 +1173,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farsec-existing-resources-ECR_DKR-security-group": { @@ -1211,13 +1235,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1233,13 +1257,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1255,7 +1279,7 @@ "path": "farsec-existing-resources/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1280,7 +1304,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1318,19 +1342,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1378,7 +1402,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1386,13 +1410,13 @@ "path": "farsec-existing-resources/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1420,13 +1444,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1478,13 +1502,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1492,7 +1516,7 @@ "path": "farsec-existing-resources/test-construct", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-secretsmanager.FargateToSecretsmanager", - "version": "2.63.0" + "version": "2.76.0" } }, "farsec-existing-resources-SECRETS_MANAGER-security-group": { @@ -1548,13 +1572,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1570,7 +1594,7 @@ "path": "farsec-existing-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1582,7 +1606,7 @@ "path": "farsec-existing-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1590,25 +1614,25 @@ "path": "farsec-existing-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1616,7 +1640,7 @@ "path": "farsec-existing-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1624,13 +1648,13 @@ "path": "farsec-existing-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1638,13 +1662,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsec-new-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsec-new-resources.assets.json index 84837ac78..3f880a101 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsec-new-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsec-new-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "bc73af352f62b326f1a160e8b28a44d74b8873b6ed6eaf283bd3b8e191d60393": { + "9d269837fa9095fe066bab492c5a9ca2537c656e3d54e410fc78a4a5cfbb0a0c": { "source": { "path": "farsec-new-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "bc73af352f62b326f1a160e8b28a44d74b8873b6ed6eaf283bd3b8e191d60393.json", + "objectKey": "9d269837fa9095fe066bab492c5a9ca2537c656e3d54e410fc78a4a5cfbb0a0c.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsec-new-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsec-new-resources.template.json index 0b6b4b217..b3ad46215 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsec-new-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsec-new-resources.template.json @@ -586,6 +586,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsec-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -613,6 +619,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsec-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -640,6 +652,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsec-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -675,6 +693,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farsec-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -754,7 +778,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsecnewresourcesIntegDefaultTestDeployAssert7EBA6B0F.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsecnewresourcesIntegDefaultTestDeployAssert7EBA6B0F.assets.json index d224a42db..b14f03e27 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsecnewresourcesIntegDefaultTestDeployAssert7EBA6B0F.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/farsecnewresourcesIntegDefaultTestDeployAssert7EBA6B0F.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/integ.json index bc25c0708..f8cf210f1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farsec-new-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/manifest.json index 3b17718d2..8a412fd90 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farsecnewresourcesIntegDefaultTestDeployAssert7EBA6B0F.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/bc73af352f62b326f1a160e8b28a44d74b8873b6ed6eaf283bd3b8e191d60393.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/9d269837fa9095fe066bab492c5a9ca2537c656e3d54e410fc78a4a5cfbb0a0c.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -280,6 +280,12 @@ "data": "VpcS3A5408339" } ], + "/farsec-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farsec-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/tree.json index 38790b581..05915c2c8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-secretsmanager/test/integ.farsec-new-resources.js.snapshot/tree.json @@ -27,19 +27,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_secretsmanager.CfnSecret", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_secretsmanager.Secret", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-secretsmanager.FargateToSecretsmanager", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -66,7 +66,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -110,7 +110,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -118,7 +118,7 @@ "path": "farsec-new-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -140,7 +140,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -159,7 +159,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -179,7 +179,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -199,7 +199,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -227,13 +227,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -277,7 +277,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -285,7 +285,7 @@ "path": "farsec-new-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -307,7 +307,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -326,7 +326,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -346,7 +346,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -366,7 +366,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -394,13 +394,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -444,7 +444,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -452,7 +452,7 @@ "path": "farsec-new-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -474,7 +474,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -493,7 +493,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -513,13 +513,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -563,7 +563,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -571,7 +571,7 @@ "path": "farsec-new-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -593,7 +593,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -612,7 +612,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -632,13 +632,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -657,7 +657,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -676,7 +676,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -688,13 +688,13 @@ "path": "farsec-new-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -710,7 +710,7 @@ "path": "farsec-new-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -741,7 +741,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -793,19 +793,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -829,13 +829,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -869,13 +869,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SECRETS_MANAGER": { @@ -888,6 +888,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsec-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -914,13 +920,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -933,6 +939,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsec-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -959,13 +971,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -978,6 +990,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsec-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1004,13 +1022,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1023,6 +1041,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsec-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1057,19 +1081,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1081,7 +1105,7 @@ "path": "farsec-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1089,7 +1113,7 @@ "path": "farsec-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1097,13 +1121,13 @@ "path": "farsec-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farsec-new-resources-SECRETS_MANAGER-security-group": { @@ -1159,13 +1183,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farsec-new-resources-ECR_API-security-group": { @@ -1221,13 +1245,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farsec-new-resources-ECR_DKR-security-group": { @@ -1283,13 +1307,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1305,13 +1329,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1327,7 +1351,7 @@ "path": "farsec-new-resources/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1352,7 +1376,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1392,19 +1416,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1452,7 +1476,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -1460,13 +1484,13 @@ "path": "farsec-new-resources/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -1494,13 +1518,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -1552,13 +1576,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1574,7 +1598,7 @@ "path": "farsec-new-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1586,7 +1610,7 @@ "path": "farsec-new-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1594,25 +1618,25 @@ "path": "farsec-new-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1620,7 +1644,7 @@ "path": "farsec-new-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1628,13 +1652,13 @@ "path": "farsec-new-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1642,13 +1666,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/package.json index 4c097008b..c8bea58b3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsns-existing-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsns-existing-resources.assets.json index 3ce4ce96d..7c4ca8469 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsns-existing-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsns-existing-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "e93b3f910c7af7d5eb26939c8978950e12ca1f3aad2a25d3bac6197acf5213d0": { + "ffd6508ab0a3f04c4851e2c5f7171f7aa90d8bafda2de5ff4cc8e521c57877de": { "source": { "path": "farsns-existing-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "e93b3f910c7af7d5eb26939c8978950e12ca1f3aad2a25d3bac6197acf5213d0.json", + "objectKey": "ffd6508ab0a3f04c4851e2c5f7171f7aa90d8bafda2de5ff4cc8e521c57877de.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsns-existing-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsns-existing-resources.template.json index a5e65065b..0b22d87c1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsns-existing-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsns-existing-resources.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsns-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsns-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farsns-existing-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -657,6 +675,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsns-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -736,7 +760,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsnsexistingresourcesIntegDefaultTestDeployAssert10CBC809.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsnsexistingresourcesIntegDefaultTestDeployAssert10CBC809.assets.json index 006531a11..9d33b455a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsnsexistingresourcesIntegDefaultTestDeployAssert10CBC809.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/farsnsexistingresourcesIntegDefaultTestDeployAssert10CBC809.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/integ.json index 723c39d7a..ea0530552 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farsns-existing-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/manifest.json index 701f3018e..75a419ae9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farsnsexistingresourcesIntegDefaultTestDeployAssert10CBC809.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/e93b3f910c7af7d5eb26939c8978950e12ca1f3aad2a25d3bac6197acf5213d0.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/ffd6508ab0a3f04c4851e2c5f7171f7aa90d8bafda2de5ff4cc8e521c57877de.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -274,6 +274,12 @@ "data": "VpcSNS5B664381" } ], + "/farsns-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farsns-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/tree.json index 85c238ce7..d3d71a020 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-existing-resources.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farsns-existing-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farsns-existing-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farsns-existing-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farsns-existing-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farsns-existing-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farsns-existing-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsns-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsns-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsns-existing-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,13 +996,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "SNS": { @@ -997,6 +1015,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsns-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1023,19 +1047,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1047,7 +1071,7 @@ "path": "farsns-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1055,7 +1079,7 @@ "path": "farsns-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1063,13 +1087,13 @@ "path": "farsns-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-topic": { @@ -1085,13 +1109,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.CfnTopic", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.Topic", - "version": "2.150.0" + "version": "2.174.0" } }, "farsns-existing-resources-ECR_API-security-group": { @@ -1147,13 +1171,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farsns-existing-resources-ECR_DKR-security-group": { @@ -1209,13 +1233,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1231,13 +1255,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1253,7 +1277,7 @@ "path": "farsns-existing-resources/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1278,7 +1302,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1313,19 +1337,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1382,7 +1406,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1390,13 +1414,13 @@ "path": "farsns-existing-resources/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1424,13 +1448,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1482,13 +1506,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1496,7 +1520,7 @@ "path": "farsns-existing-resources/test-construct", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-sns.FargateToSns", - "version": "2.63.0" + "version": "2.76.0" } }, "farsns-existing-resources-SNS-security-group": { @@ -1552,13 +1576,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1574,7 +1598,7 @@ "path": "farsns-existing-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1586,7 +1610,7 @@ "path": "farsns-existing-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1594,25 +1618,25 @@ "path": "farsns-existing-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1620,7 +1644,7 @@ "path": "farsns-existing-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1628,13 +1652,13 @@ "path": "farsns-existing-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1642,13 +1666,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsns-new-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsns-new-resources.assets.json index 5a9d428c6..cd8da0241 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsns-new-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsns-new-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "8e7788d5daf1e4985abe0b1c71e1b226903e52130ff3e4e7251843cd26fce9ff": { + "1bee7bbe2e9bccf3bcdd5320bf1ba360c84dfda09cfcf42d6a0358c6792c4ccd": { "source": { "path": "farsns-new-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "8e7788d5daf1e4985abe0b1c71e1b226903e52130ff3e4e7251843cd26fce9ff.json", + "objectKey": "1bee7bbe2e9bccf3bcdd5320bf1ba360c84dfda09cfcf42d6a0358c6792c4ccd.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsns-new-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsns-new-resources.template.json index fedbd0cb3..1fa6303e3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsns-new-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsns-new-resources.template.json @@ -665,6 +665,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsns-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -692,6 +698,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsns-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -719,6 +731,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsns-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -754,6 +772,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farsns-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -833,7 +857,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsnsnewresourcesIntegDefaultTestDeployAssertCC977A5A.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsnsnewresourcesIntegDefaultTestDeployAssertCC977A5A.assets.json index 3795525d3..a79a45137 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsnsnewresourcesIntegDefaultTestDeployAssertCC977A5A.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/farsnsnewresourcesIntegDefaultTestDeployAssertCC977A5A.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/integ.json index 767efdcde..d1ba7758b 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farsns-new-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/manifest.json index 875000e37..4fff2bb69 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farsnsnewresourcesIntegDefaultTestDeployAssertCC977A5A.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/8e7788d5daf1e4985abe0b1c71e1b226903e52130ff3e4e7251843cd26fce9ff.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/1bee7bbe2e9bccf3bcdd5320bf1ba360c84dfda09cfcf42d6a0358c6792c4ccd.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -286,6 +286,12 @@ "data": "VpcS3A5408339" } ], + "/farsns-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farsns-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/tree.json index f9c38245f..5982efc16 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sns/test/integ.farsns-new-resources.js.snapshot/tree.json @@ -17,7 +17,7 @@ "path": "farsns-new-resources/test-construct/aws-managed-key", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "SnsTopic": { @@ -46,7 +46,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.CfnTopic", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -138,25 +138,25 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.CfnTopicPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.TopicPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.Topic", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-sns.FargateToSns", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -183,7 +183,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -227,7 +227,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -235,7 +235,7 @@ "path": "farsns-new-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -257,7 +257,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -276,7 +276,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -296,7 +296,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -316,7 +316,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -344,13 +344,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -394,7 +394,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -402,7 +402,7 @@ "path": "farsns-new-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -424,7 +424,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -443,7 +443,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -463,7 +463,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -483,7 +483,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -511,13 +511,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -561,7 +561,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -569,7 +569,7 @@ "path": "farsns-new-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -591,7 +591,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -610,7 +610,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -630,13 +630,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -680,7 +680,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -688,7 +688,7 @@ "path": "farsns-new-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -710,7 +710,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -729,7 +729,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -749,13 +749,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -774,7 +774,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -793,7 +793,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -805,13 +805,13 @@ "path": "farsns-new-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -827,7 +827,7 @@ "path": "farsns-new-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -858,7 +858,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -910,19 +910,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -946,13 +946,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -986,13 +986,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SNS": { @@ -1005,6 +1005,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsns-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1031,13 +1037,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1050,6 +1056,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsns-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1076,13 +1088,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1095,6 +1107,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsns-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1121,13 +1139,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1140,6 +1158,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsns-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1174,19 +1198,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1198,7 +1222,7 @@ "path": "farsns-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1206,7 +1230,7 @@ "path": "farsns-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1214,13 +1238,13 @@ "path": "farsns-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farsns-new-resources-SNS-security-group": { @@ -1276,13 +1300,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farsns-new-resources-ECR_API-security-group": { @@ -1338,13 +1362,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farsns-new-resources-ECR_DKR-security-group": { @@ -1400,13 +1424,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1422,13 +1446,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1444,7 +1468,7 @@ "path": "farsns-new-resources/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1469,7 +1493,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1504,19 +1528,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1573,7 +1597,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -1581,13 +1605,13 @@ "path": "farsns-new-resources/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -1615,13 +1639,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -1673,13 +1697,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1695,7 +1719,7 @@ "path": "farsns-new-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1707,7 +1731,7 @@ "path": "farsns-new-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1715,25 +1739,25 @@ "path": "farsns-new-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1741,7 +1765,7 @@ "path": "farsns-new-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1749,13 +1773,13 @@ "path": "farsns-new-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1763,13 +1787,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/package.json index ea69a8a86..5a1e2360e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqs-existing-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqs-existing-resources.assets.json index 200b6a428..8d50ca2ea 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqs-existing-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqs-existing-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "4fc9534a9d0a07d6f1678ad1abf0b695e94d9f32ef91d581fb5d233e0e5c5471": { + "9a4ec39fe498a4c54ada6c01db131f1970a5681dbb6e2eacbce7948d02e01c93": { "source": { "path": "farsqs-existing-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "4fc9534a9d0a07d6f1678ad1abf0b695e94d9f32ef91d581fb5d233e0e5c5471.json", + "objectKey": "9a4ec39fe498a4c54ada6c01db131f1970a5681dbb6e2eacbce7948d02e01c93.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqs-existing-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqs-existing-resources.template.json index 9b915b5a7..f93a9184d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqs-existing-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqs-existing-resources.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsqs-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsqs-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farsqs-existing-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -657,6 +675,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsqs-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -736,7 +760,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqsexistingresourcesIntegDefaultTestDeployAssertCA7F7165.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqsexistingresourcesIntegDefaultTestDeployAssertCA7F7165.assets.json index c2650380e..745b3eee6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqsexistingresourcesIntegDefaultTestDeployAssertCA7F7165.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/farsqsexistingresourcesIntegDefaultTestDeployAssertCA7F7165.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/integ.json index 878b42b6d..726810074 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farsqs-existing-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/manifest.json index a4735417a..e01714ed5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farsqsexistingresourcesIntegDefaultTestDeployAssertCA7F7165.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/4fc9534a9d0a07d6f1678ad1abf0b695e94d9f32ef91d581fb5d233e0e5c5471.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/9a4ec39fe498a4c54ada6c01db131f1970a5681dbb6e2eacbce7948d02e01c93.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -274,6 +274,12 @@ "data": "VpcSQSDF166A88" } ], + "/farsqs-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farsqs-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/tree.json index b728d64b7..a9ee3a0ac 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-existing-resources.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farsqs-existing-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farsqs-existing-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farsqs-existing-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farsqs-existing-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farsqs-existing-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farsqs-existing-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsqs-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsqs-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsqs-existing-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,13 +996,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "SQS": { @@ -997,6 +1015,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsqs-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1023,19 +1047,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1047,7 +1071,7 @@ "path": "farsqs-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1055,7 +1079,7 @@ "path": "farsqs-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1063,13 +1087,13 @@ "path": "farsqs-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-queue": { @@ -1088,13 +1112,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.150.0" + "version": "2.174.0" } }, "farsqs-existing-resources-ECR_API-security-group": { @@ -1150,13 +1174,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farsqs-existing-resources-ECR_DKR-security-group": { @@ -1212,13 +1236,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1234,13 +1258,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1256,7 +1280,7 @@ "path": "farsqs-existing-resources/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1281,7 +1305,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1326,19 +1350,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1395,7 +1419,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1403,13 +1427,13 @@ "path": "farsqs-existing-resources/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1437,13 +1461,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1495,13 +1519,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1509,7 +1533,7 @@ "path": "farsqs-existing-resources/test-construct", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-sqs.FargateToSqs", - "version": "2.63.0" + "version": "2.76.0" } }, "farsqs-existing-resources-SQS-security-group": { @@ -1565,13 +1589,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1587,7 +1611,7 @@ "path": "farsqs-existing-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1599,7 +1623,7 @@ "path": "farsqs-existing-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1607,25 +1631,25 @@ "path": "farsqs-existing-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1633,7 +1657,7 @@ "path": "farsqs-existing-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1641,13 +1665,13 @@ "path": "farsqs-existing-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1655,13 +1679,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqs-new-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqs-new-resources.assets.json index c6d7de404..2e6fb0d67 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqs-new-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqs-new-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "3211088c04de2a8759bf90733b89c479ab3ccb31389e7d75083cc29f9a45bb43": { + "e8a2a207d2ef6fb708f917ccecdd7b046493f725cfdb1d6bee0e68ee9f756657": { "source": { "path": "farsqs-new-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "3211088c04de2a8759bf90733b89c479ab3ccb31389e7d75083cc29f9a45bb43.json", + "objectKey": "e8a2a207d2ef6fb708f917ccecdd7b046493f725cfdb1d6bee0e68ee9f756657.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqs-new-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqs-new-resources.template.json index 0c6ea4c69..577adbdac 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqs-new-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqs-new-resources.template.json @@ -644,6 +644,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsqs-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -671,6 +677,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsqs-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -698,6 +710,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farsqs-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -733,6 +751,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farsqs-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -812,7 +836,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqsnewresourcesIntegDefaultTestDeployAssert05F2901E.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqsnewresourcesIntegDefaultTestDeployAssert05F2901E.assets.json index 80949d0db..89362b8d5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqsnewresourcesIntegDefaultTestDeployAssert05F2901E.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/farsqsnewresourcesIntegDefaultTestDeployAssert05F2901E.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/integ.json index 5c7acf6f6..73e31d476 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farsqs-new-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/manifest.json index eaa713b40..fb45cc607 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farsqsnewresourcesIntegDefaultTestDeployAssert05F2901E.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/3211088c04de2a8759bf90733b89c479ab3ccb31389e7d75083cc29f9a45bb43.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/e8a2a207d2ef6fb708f917ccecdd7b046493f725cfdb1d6bee0e68ee9f756657.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -286,6 +286,12 @@ "data": "VpcS3A5408339" } ], + "/farsqs-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farsqs-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/tree.json index 7aa1db862..10eaf8ade 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-sqs/test/integ.farsqs-new-resources.js.snapshot/tree.json @@ -28,7 +28,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -107,25 +107,25 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-sqs.FargateToSqs", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -152,7 +152,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -196,7 +196,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -204,7 +204,7 @@ "path": "farsqs-new-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -226,7 +226,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -245,7 +245,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -265,7 +265,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -285,7 +285,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -313,13 +313,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -363,7 +363,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -371,7 +371,7 @@ "path": "farsqs-new-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -393,7 +393,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -412,7 +412,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -432,7 +432,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -452,7 +452,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -480,13 +480,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -530,7 +530,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -538,7 +538,7 @@ "path": "farsqs-new-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -560,7 +560,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -579,7 +579,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -599,13 +599,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -649,7 +649,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -657,7 +657,7 @@ "path": "farsqs-new-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -679,7 +679,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -698,7 +698,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -718,13 +718,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -743,7 +743,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -762,7 +762,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -774,13 +774,13 @@ "path": "farsqs-new-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -796,7 +796,7 @@ "path": "farsqs-new-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -827,7 +827,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -879,19 +879,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -915,13 +915,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -955,13 +955,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SQS": { @@ -974,6 +974,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsqs-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1000,13 +1006,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -1019,6 +1025,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsqs-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1045,13 +1057,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -1064,6 +1076,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsqs-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1090,13 +1108,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1109,6 +1127,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farsqs-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1143,19 +1167,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1167,7 +1191,7 @@ "path": "farsqs-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1175,7 +1199,7 @@ "path": "farsqs-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1183,13 +1207,13 @@ "path": "farsqs-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farsqs-new-resources-SQS-security-group": { @@ -1245,13 +1269,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farsqs-new-resources-ECR_API-security-group": { @@ -1307,13 +1331,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farsqs-new-resources-ECR_DKR-security-group": { @@ -1369,13 +1393,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1391,13 +1415,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1413,7 +1437,7 @@ "path": "farsqs-new-resources/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1438,7 +1462,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1480,19 +1504,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1549,7 +1573,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -1557,13 +1581,13 @@ "path": "farsqs-new-resources/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -1591,13 +1615,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -1649,13 +1673,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1671,7 +1695,7 @@ "path": "farsqs-new-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1683,7 +1707,7 @@ "path": "farsqs-new-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1691,25 +1715,25 @@ "path": "farsqs-new-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1717,7 +1741,7 @@ "path": "farsqs-new-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1725,13 +1749,13 @@ "path": "farsqs-new-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1739,13 +1763,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/package.json index 28bef3363..9a36b2dc5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssm-existing-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssm-existing-resources.assets.json index 2f2f870fe..50dd2a557 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssm-existing-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssm-existing-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "495d13a37cdd0a016533e021332ed428be2c6e6ab3b7a16b18975abaa1b64f81": { + "366779d8483bde4c6de4ef7a92967b9c6755b05d2a24b84de1a78c03d702d604": { "source": { "path": "farssm-existing-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "495d13a37cdd0a016533e021332ed428be2c6e6ab3b7a16b18975abaa1b64f81.json", + "objectKey": "366779d8483bde4c6de4ef7a92967b9c6755b05d2a24b84de1a78c03d702d604.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssm-existing-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssm-existing-resources.template.json index 5929d4be1..6a2e35ef3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssm-existing-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssm-existing-resources.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farssm-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farssm-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farssm-existing-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -657,6 +675,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farssm-existing-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -736,7 +760,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssmexistingresourcesIntegDefaultTestDeployAssertCEFF15CD.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssmexistingresourcesIntegDefaultTestDeployAssertCEFF15CD.assets.json index e81c8fbcf..ec165d7f6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssmexistingresourcesIntegDefaultTestDeployAssertCEFF15CD.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/farssmexistingresourcesIntegDefaultTestDeployAssertCEFF15CD.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/integ.json index a62ee35bb..9079aacd8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farssm-existing-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/manifest.json index 3952babd4..766270e91 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farssmexistingresourcesIntegDefaultTestDeployAssertCEFF15CD.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/495d13a37cdd0a016533e021332ed428be2c6e6ab3b7a16b18975abaa1b64f81.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/366779d8483bde4c6de4ef7a92967b9c6755b05d2a24b84de1a78c03d702d604.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -274,6 +274,12 @@ "data": "VpcSSM173B3B5B" } ], + "/farssm-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farssm-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/tree.json index 53624637d..79e881c86 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-existing-resources.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farssm-existing-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farssm-existing-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farssm-existing-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farssm-existing-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farssm-existing-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farssm-existing-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farssm-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farssm-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farssm-existing-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,13 +996,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "SSM": { @@ -997,6 +1015,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farssm-existing-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1023,19 +1047,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1047,7 +1071,7 @@ "path": "farssm-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1055,7 +1079,7 @@ "path": "farssm-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1063,13 +1087,13 @@ "path": "farssm-existing-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "Parameter": { @@ -1090,13 +1114,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ssm.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ssm.StringParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "farssm-existing-resources-ECR_API-security-group": { @@ -1152,13 +1176,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farssm-existing-resources-ECR_DKR-security-group": { @@ -1214,13 +1238,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1236,13 +1260,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1258,7 +1282,7 @@ "path": "farssm-existing-resources/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1283,7 +1307,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1336,19 +1360,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1396,7 +1420,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1404,13 +1428,13 @@ "path": "farssm-existing-resources/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1438,13 +1462,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1496,13 +1520,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1510,7 +1534,7 @@ "path": "farssm-existing-resources/test-construct", "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-ssmstringparameter.FargateToSsmstringparameter", - "version": "2.63.0" + "version": "2.76.0" } }, "farssm-existing-resources-SSM-security-group": { @@ -1566,13 +1590,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1588,7 +1612,7 @@ "path": "farssm-existing-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1600,7 +1624,7 @@ "path": "farssm-existing-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1608,25 +1632,25 @@ "path": "farssm-existing-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1634,7 +1658,7 @@ "path": "farssm-existing-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1642,13 +1666,13 @@ "path": "farssm-existing-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1656,13 +1680,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssm-new-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssm-new-resources.assets.json index 0d4239747..0961967ee 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssm-new-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssm-new-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "81dafc87ed5466fd1f799d18d9461d3d1f2fbe6d20c57f07664f16bc10b39be3": { + "69baab0f49ad2a88cd0b2688e0931a5b2f78844ef960dc30883ffcf6d5579823": { "source": { "path": "farssm-new-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "81dafc87ed5466fd1f799d18d9461d3d1f2fbe6d20c57f07664f16bc10b39be3.json", + "objectKey": "69baab0f49ad2a88cd0b2688e0931a5b2f78844ef960dc30883ffcf6d5579823.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssm-new-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssm-new-resources.template.json index 5a63b415b..dc8bc83f2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssm-new-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssm-new-resources.template.json @@ -575,6 +575,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farssm-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -602,6 +608,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farssm-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -629,6 +641,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farssm-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -664,6 +682,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farssm-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -743,7 +767,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssmnewresourcesIntegDefaultTestDeployAssert75A4E9D9.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssmnewresourcesIntegDefaultTestDeployAssert75A4E9D9.assets.json index d23c2e138..cf95e6916 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssmnewresourcesIntegDefaultTestDeployAssert75A4E9D9.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/farssmnewresourcesIntegDefaultTestDeployAssert75A4E9D9.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/integ.json index 269fa5585..875872779 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farssm-new-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/manifest.json index 45f802748..09cb0c34a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farssmnewresourcesIntegDefaultTestDeployAssert75A4E9D9.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/81dafc87ed5466fd1f799d18d9461d3d1f2fbe6d20c57f07664f16bc10b39be3.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/69baab0f49ad2a88cd0b2688e0931a5b2f78844ef960dc30883ffcf6d5579823.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -280,6 +280,12 @@ "data": "VpcS3A5408339" } ], + "/farssm-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farssm-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/tree.json index acab6a40d..0d2fd9ffa 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-ssmstringparameter/test/integ.farssm-new-resources.js.snapshot/tree.json @@ -28,19 +28,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ssm.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ssm.StringParameter", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-ssmstringparameter.FargateToSsmstringparameter", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -67,7 +67,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -111,7 +111,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -119,7 +119,7 @@ "path": "farssm-new-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -141,7 +141,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -160,7 +160,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -180,7 +180,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -200,7 +200,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -228,13 +228,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -278,7 +278,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -286,7 +286,7 @@ "path": "farssm-new-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -308,7 +308,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -327,7 +327,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -347,7 +347,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -367,7 +367,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -395,13 +395,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -445,7 +445,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -453,7 +453,7 @@ "path": "farssm-new-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -475,7 +475,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -494,7 +494,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -514,13 +514,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -564,7 +564,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -572,7 +572,7 @@ "path": "farssm-new-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -594,7 +594,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -613,7 +613,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -633,13 +633,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -658,7 +658,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -677,7 +677,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -689,13 +689,13 @@ "path": "farssm-new-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -711,7 +711,7 @@ "path": "farssm-new-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -742,7 +742,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -794,19 +794,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -830,13 +830,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -870,13 +870,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SSM": { @@ -889,6 +889,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farssm-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -915,13 +921,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -934,6 +940,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farssm-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -960,13 +972,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -979,6 +991,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farssm-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1005,13 +1023,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -1024,6 +1042,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farssm-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -1058,19 +1082,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1082,7 +1106,7 @@ "path": "farssm-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1090,7 +1114,7 @@ "path": "farssm-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1098,13 +1122,13 @@ "path": "farssm-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farssm-new-resources-SSM-security-group": { @@ -1160,13 +1184,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farssm-new-resources-ECR_API-security-group": { @@ -1222,13 +1246,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farssm-new-resources-ECR_DKR-security-group": { @@ -1284,13 +1308,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-cluster": { @@ -1306,13 +1330,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-taskdef": { @@ -1328,7 +1352,7 @@ "path": "farssm-new-resources/test-construct-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1353,7 +1377,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1405,19 +1429,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1465,7 +1489,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-container": { @@ -1473,13 +1497,13 @@ "path": "farssm-new-resources/test-construct-taskdef/test-construct-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-sg": { @@ -1507,13 +1531,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct-service": { @@ -1565,13 +1589,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1587,7 +1611,7 @@ "path": "farssm-new-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1599,7 +1623,7 @@ "path": "farssm-new-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1607,25 +1631,25 @@ "path": "farssm-new-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1633,7 +1657,7 @@ "path": "farssm-new-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1641,13 +1665,13 @@ "path": "farssm-new-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1655,13 +1679,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/package.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/package.json index 8d590f677..35ee4d99d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstp-new-resources.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstp-new-resources.assets.json index 0126a99c6..5669040e5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstp-new-resources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstp-new-resources.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "1dc05c24a51b2a47906af20aca8a2e14109a98ee859dc2f2d1e28eadd03752f4": { + "48b6d47685b9ec2d27a13ba90a1371cf954c53ecf4d535510997ded9dbe91cee": { "source": { "path": "farstp-new-resources.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "1dc05c24a51b2a47906af20aca8a2e14109a98ee859dc2f2d1e28eadd03752f4.json", + "objectKey": "48b6d47685b9ec2d27a13ba90a1371cf954c53ecf4d535510997ded9dbe91cee.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstp-new-resources.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstp-new-resources.template.json index 75f9e1a59..99d70729f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstp-new-resources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstp-new-resources.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farstp-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farstp-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farstp-new-resources/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -657,6 +675,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farstp-new-resources/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -736,7 +760,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstpnewresourcesIntegDefaultTestDeployAssert36B3414D.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstpnewresourcesIntegDefaultTestDeployAssert36B3414D.assets.json index af6a5f8b8..ed8d5a14d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstpnewresourcesIntegDefaultTestDeployAssert36B3414D.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/farstpnewresourcesIntegDefaultTestDeployAssert36B3414D.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/integ.json index 71a690f3b..933cc005e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farstp-new-resources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/manifest.json index 22e0bca52..6d28cc419 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farstpnewresourcesIntegDefaultTestDeployAssert36B3414D.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/1dc05c24a51b2a47906af20aca8a2e14109a98ee859dc2f2d1e28eadd03752f4.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/48b6d47685b9ec2d27a13ba90a1371cf954c53ecf4d535510997ded9dbe91cee.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -274,6 +274,12 @@ "data": "VpcSTEPFUNCTIONS550F8CB6" } ], + "/farstp-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farstp-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/tree.json index 90ddf59c7..59673f0d1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-new-resources.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farstp-new-resources/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farstp-new-resources/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farstp-new-resources/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farstp-new-resources/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farstp-new-resources/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farstp-new-resources/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farstp-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farstp-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farstp-new-resources/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,13 +996,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "STEP_FUNCTIONS": { @@ -997,6 +1015,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farstp-new-resources/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1023,19 +1047,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1047,7 +1071,7 @@ "path": "farstp-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1055,7 +1079,7 @@ "path": "farstp-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1063,13 +1087,13 @@ "path": "farstp-new-resources/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farstp-new-resources-ECR_API-security-group": { @@ -1125,13 +1149,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farstp-new-resources-ECR_DKR-security-group": { @@ -1187,13 +1211,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1209,13 +1233,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1231,7 +1255,7 @@ "path": "farstp-new-resources/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1256,7 +1280,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1291,19 +1315,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1351,7 +1375,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1359,13 +1383,13 @@ "path": "farstp-new-resources/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1393,13 +1417,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1451,13 +1475,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "lambdafarstp-test": { @@ -1473,7 +1497,7 @@ "path": "farstp-new-resources/lambdafarstp-test/ServiceRole/ImportServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1512,13 +1536,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1542,13 +1566,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "taskfarstp-test": { @@ -1556,7 +1580,7 @@ "path": "farstp-new-resources/taskfarstp-test", "constructInfo": { "fqn": "aws-cdk-lib.aws_stepfunctions_tasks.LambdaInvoke", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1598,13 +1622,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "StateMachine": { @@ -1620,7 +1644,7 @@ "path": "farstp-new-resources/test-construct/StateMachine/Role/ImportRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1645,7 +1669,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1713,19 +1737,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1778,13 +1802,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_stepfunctions.CfnStateMachine", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_stepfunctions.StateMachine", - "version": "2.150.0" + "version": "2.174.0" } }, "ExecutionFailedAlarm": { @@ -1817,13 +1841,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "ExecutionThrottledAlarm": { @@ -1856,13 +1880,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "ExecutionAbortedAlarm": { @@ -1895,19 +1919,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-stepfunctions.FargateToStepfunctions", - "version": "2.63.0" + "version": "2.76.0" } }, "farstp-new-resources-STEP_FUNCTIONS-security-group": { @@ -1963,13 +1987,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1985,7 +2009,7 @@ "path": "farstp-new-resources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1997,7 +2021,7 @@ "path": "farstp-new-resources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2005,25 +2029,25 @@ "path": "farstp-new-resources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2031,7 +2055,7 @@ "path": "farstp-new-resources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2039,13 +2063,13 @@ "path": "farstp-new-resources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2053,13 +2077,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstp-no-cloudwatch-alarms.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstp-no-cloudwatch-alarms.assets.json index 9818b2a63..31b85a575 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstp-no-cloudwatch-alarms.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstp-no-cloudwatch-alarms.assets.json @@ -1,21 +1,21 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } } }, - "3ba1c511c2b6ee3e7c0ab76e808edfe0a0b9c111b2dc2147b9839c3bee113597": { + "e2fa1aa6cc3567daf95f84993c353ae65d2f591ea1a1b4663714316adb6704b2": { "source": { "path": "farstp-no-cloudwatch-alarms.template.json", "packaging": "file" @@ -23,7 +23,7 @@ "destinations": { "current_account-us-east-1": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1", - "objectKey": "3ba1c511c2b6ee3e7c0ab76e808edfe0a0b9c111b2dc2147b9839c3bee113597.json", + "objectKey": "e2fa1aa6cc3567daf95f84993c353ae65d2f591ea1a1b4663714316adb6704b2.json", "region": "us-east-1", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-us-east-1" } diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstp-no-cloudwatch-alarms.template.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstp-no-cloudwatch-alarms.template.json index 6817fe220..3ce0e46e7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstp-no-cloudwatch-alarms.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstp-no-cloudwatch-alarms.template.json @@ -568,6 +568,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farstp-no-cloudwatch-alarms/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -595,6 +601,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farstp-no-cloudwatch-alarms/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -630,6 +642,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "farstp-no-cloudwatch-alarms/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -657,6 +675,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "farstp-no-cloudwatch-alarms/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -736,7 +760,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstpnocloudwatchalarmsIntegDefaultTestDeployAssertC4578F22.assets.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstpnocloudwatchalarmsIntegDefaultTestDeployAssertC4578F22.assets.json index 8df31a02f..31f5c2e1d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstpnocloudwatchalarmsIntegDefaultTestDeployAssertC4578F22.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/farstpnocloudwatchalarmsIntegDefaultTestDeployAssertC4578F22.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/integ.json index eb3e21dc3..caa49a315 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "farstp-no-cloudwatch-alarms/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/manifest.json index 0e28f33d3..16b657803 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "farstpnocloudwatchalarmsIntegDefaultTestDeployAssertC4578F22.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-us-east-1", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/3ba1c511c2b6ee3e7c0ab76e808edfe0a0b9c111b2dc2147b9839c3bee113597.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-us-east-1/e2fa1aa6cc3567daf95f84993c353ae65d2f591ea1a1b4663714316adb6704b2.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -274,6 +274,12 @@ "data": "VpcSTEPFUNCTIONS550F8CB6" } ], + "/farstp-no-cloudwatch-alarms/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/farstp-no-cloudwatch-alarms/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/tree.json index 70f0b55dd..b3b5237f9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-fargate-stepfunctions/test/integ.farstp-no-cloudwatch-alarms.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "farstp-no-cloudwatch-alarms/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "farstp-no-cloudwatch-alarms/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "farstp-no-cloudwatch-alarms/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "farstp-no-cloudwatch-alarms/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "farstp-no-cloudwatch-alarms/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "farstp-no-cloudwatch-alarms/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_API": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farstp-no-cloudwatch-alarms/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -880,13 +886,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "ECR_DKR": { @@ -899,6 +905,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farstp-no-cloudwatch-alarms/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -925,13 +937,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -944,6 +956,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farstp-no-cloudwatch-alarms/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -978,13 +996,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } }, "STEP_FUNCTIONS": { @@ -997,6 +1015,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "farstp-no-cloudwatch-alarms/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1023,19 +1047,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1047,7 +1071,7 @@ "path": "farstp-no-cloudwatch-alarms/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1055,7 +1079,7 @@ "path": "farstp-no-cloudwatch-alarms/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1063,13 +1087,13 @@ "path": "farstp-no-cloudwatch-alarms/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "farstp-no-cloudwatch-alarms-ECR_API-security-group": { @@ -1125,13 +1149,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "farstp-no-cloudwatch-alarms-ECR_DKR-security-group": { @@ -1187,13 +1211,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-cluster": { @@ -1209,13 +1233,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnCluster", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.Cluster", - "version": "2.150.0" + "version": "2.174.0" } }, "test-taskdef": { @@ -1231,7 +1255,7 @@ "path": "farstp-no-cloudwatch-alarms/test-taskdef/TaskRole/ImportTaskRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1256,7 +1280,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1291,19 +1315,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1351,7 +1375,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-container": { @@ -1359,13 +1383,13 @@ "path": "farstp-no-cloudwatch-alarms/test-taskdef/test-container", "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.ContainerDefinition", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateTaskDefinition", - "version": "2.150.0" + "version": "2.174.0" } }, "test-sg": { @@ -1393,13 +1417,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "test-service": { @@ -1451,13 +1475,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.CfnService", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ecs.FargateService", - "version": "2.150.0" + "version": "2.174.0" } }, "lambdafarstp-test": { @@ -1473,7 +1497,7 @@ "path": "farstp-no-cloudwatch-alarms/lambdafarstp-test/ServiceRole/ImportServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1512,13 +1536,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1542,13 +1566,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "taskfarstp-test": { @@ -1556,7 +1580,7 @@ "path": "farstp-no-cloudwatch-alarms/taskfarstp-test", "constructInfo": { "fqn": "aws-cdk-lib.aws_stepfunctions_tasks.LambdaInvoke", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1598,13 +1622,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "StateMachine": { @@ -1620,7 +1644,7 @@ "path": "farstp-no-cloudwatch-alarms/test-construct/StateMachine/Role/ImportRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1645,7 +1669,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1713,19 +1737,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1778,19 +1802,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_stepfunctions.CfnStateMachine", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_stepfunctions.StateMachine", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-fargate-stepfunctions.FargateToStepfunctions", - "version": "2.63.0" + "version": "2.76.0" } }, "farstp-no-cloudwatch-alarms-STEP_FUNCTIONS-security-group": { @@ -1846,13 +1870,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1868,7 +1892,7 @@ "path": "farstp-no-cloudwatch-alarms/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1880,7 +1904,7 @@ "path": "farstp-no-cloudwatch-alarms/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1888,25 +1912,25 @@ "path": "farstp-no-cloudwatch-alarms/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1914,7 +1938,7 @@ "path": "farstp-no-cloudwatch-alarms/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1922,13 +1946,13 @@ "path": "farstp-no-cloudwatch-alarms/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1936,13 +1960,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-kinesisfirehose-s3/package.json b/source/patterns/@aws-solutions-constructs/aws-iot-kinesisfirehose-s3/package.json index fe4c625be..755949de6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-kinesisfirehose-s3/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-kinesisfirehose-s3/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-kinesisstreams/package.json b/source/patterns/@aws-solutions-constructs/aws-iot-kinesisstreams/package.json index 11f5f902a..8d64f4b5c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-kinesisstreams/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-kinesisstreams/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/package.json b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/package.json index 83b1d0945..e6206d7e4 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.3a18fd3de4803f72260a058823accffd4f8d69986c6862a23cd86265f6cafa0f/index.js b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.3a18fd3de4803f72260a058823accffd4f8d69986c6862a23cd86265f6cafa0f/index.js new file mode 100644 index 000000000..b8d33b611 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.3a18fd3de4803f72260a058823accffd4f8d69986c6862a23cd86265f6cafa0f/index.js @@ -0,0 +1,23 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +console.log('Loading function'); + +exports.handler = async (event, context) => { + console.log('Received event:', JSON.stringify(event, null, 2)); +    return { +      statusCode: 200, +      headers: { 'Content-Type': 'text/plain' }, +      body: `Hello from Project Vesper! You've hit ${event.path}\n` +    }; +}; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.42a35bbf0dec9ef0ac5b0dde87e71a1b8929e8d2d178dd09ccfb2c928ec0198c/index.js b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.42a35bbf0dec9ef0ac5b0dde87e71a1b8929e8d2d178dd09ccfb2c928ec0198c/index.js deleted file mode 100644 index 4b3640c1e..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.42a35bbf0dec9ef0ac5b0dde87e71a1b8929e8d2d178dd09ccfb2c928ec0198c/index.js +++ /dev/null @@ -1,10 +0,0 @@ -console.log('Loading function'); - -exports.handler = async (event, context) => { - console.log('Received event:', JSON.stringify(event, null, 2)); -    return { -      statusCode: 200, -      headers: { 'Content-Type': 'text/plain' }, -      body: `Hello from Project Vesper! You've hit ${event.path}\n` -    }; -}; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/integ.json index 88e7ae433..bda5eac9f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "iotlamddb-with-vpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddb-with-vpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddb-with-vpc.assets.json index f18c52c07..02251dc50 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddb-with-vpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddb-with-vpc.assets.json @@ -1,33 +1,33 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "42a35bbf0dec9ef0ac5b0dde87e71a1b8929e8d2d178dd09ccfb2c928ec0198c": { + "3a18fd3de4803f72260a058823accffd4f8d69986c6862a23cd86265f6cafa0f": { "source": { - "path": "asset.42a35bbf0dec9ef0ac5b0dde87e71a1b8929e8d2d178dd09ccfb2c928ec0198c", + "path": "asset.3a18fd3de4803f72260a058823accffd4f8d69986c6862a23cd86265f6cafa0f", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "42a35bbf0dec9ef0ac5b0dde87e71a1b8929e8d2d178dd09ccfb2c928ec0198c.zip", + "objectKey": "3a18fd3de4803f72260a058823accffd4f8d69986c6862a23cd86265f6cafa0f.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "45d8144adf6493d8b8f90fb78f43fe3eab31c5865deddfffdeec829ac60c578d": { + "af061c1d6e487b8b265c176966b216c209df18f107be6f451d8d5c6975e14b3e": { "source": { "path": "iotlamddb-with-vpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "45d8144adf6493d8b8f90fb78f43fe3eab31c5865deddfffdeec829ac60c578d.json", + "objectKey": "af061c1d6e487b8b265c176966b216c209df18f107be6f451d8d5c6975e14b3e.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddb-with-vpc.template.json b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddb-with-vpc.template.json index 3a9c6fddc..6f8f46246 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddb-with-vpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddb-with-vpc.template.json @@ -166,7 +166,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "42a35bbf0dec9ef0ac5b0dde87e71a1b8929e8d2d178dd09ccfb2c928ec0198c.zip" + "S3Key": "3a18fd3de4803f72260a058823accffd4f8d69986c6862a23cd86265f6cafa0f.zip" }, "Environment": { "Variables": { @@ -574,6 +574,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "testiotlambdadynamodbstackVpc1986A4BB" @@ -683,7 +689,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddbwithvpcIntegDefaultTestDeployAssertBBC79152.assets.json b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddbwithvpcIntegDefaultTestDeployAssertBBC79152.assets.json index 43537d294..939168d74 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddbwithvpcIntegDefaultTestDeployAssertBBC79152.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/iotlamddbwithvpcIntegDefaultTestDeployAssertBBC79152.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/manifest.json index eebd424a0..363686730 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "iotlamddbwithvpcIntegDefaultTestDeployAssertBBC79152.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/45d8144adf6493d8b8f90fb78f43fe3eab31c5865deddfffdeec829ac60c578d.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/af061c1d6e487b8b265c176966b216c209df18f107be6f451d8d5c6975e14b3e.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -208,6 +208,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/iotlamddb-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/iotlamddb-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/tree.json index 95fcf3b14..19fb6eab0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda-dynamodb/test/integ.iotlamddb-with-vpc.js.snapshot/tree.json @@ -25,7 +25,7 @@ "path": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/LambdaToDynamoDB/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -88,7 +88,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -157,19 +157,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -197,13 +197,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -219,7 +219,7 @@ "path": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/LambdaToDynamoDB/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -227,13 +227,13 @@ "path": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/LambdaToDynamoDB/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -246,7 +246,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "42a35bbf0dec9ef0ac5b0dde87e71a1b8929e8d2d178dd09ccfb2c928ec0198c.zip" + "s3Key": "3a18fd3de4803f72260a058823accffd4f8d69986c6862a23cd86265f6cafa0f.zip" }, "environment": { "variables": { @@ -289,7 +289,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } }, "AwsIotLambdaInvokePermission-1": { @@ -316,13 +316,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnPermission", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "DynamoTable": { @@ -358,7 +358,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.CfnTable", - "version": "2.150.0" + "version": "2.174.0" } }, "ScalingRole": { @@ -366,19 +366,19 @@ "path": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/LambdaToDynamoDB/DynamoTable/ScalingRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.Table", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-dynamodb.LambdaToDynamoDB", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -405,7 +405,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -449,7 +449,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -457,7 +457,7 @@ "path": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -479,7 +479,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -498,13 +498,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -548,7 +548,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -556,7 +556,7 @@ "path": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -597,13 +597,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -615,13 +615,13 @@ "path": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -637,7 +637,7 @@ "path": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -668,7 +668,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -720,19 +720,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -756,13 +756,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -796,13 +796,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "DDB": { @@ -815,6 +815,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "iotlamddb-with-vpc/test-iot-lambda-dynamodb-stack/Vpc" + } + ], "routeTableIds": [ { "Ref": "testiotlambdadynamodbstackVpcisolatedSubnet1RouteTableE28AAAB5" @@ -843,19 +849,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "IotToLambda": { @@ -889,19 +895,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iot.CfnTopicRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-iot-lambda.IotToLambda", - "version": "2.63.0" + "version": "2.76.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-iot-lambda-dynamodb.IotToLambdaToDynamoDB", - "version": "2.63.0" + "version": "2.76.0" } }, "LatestNodeRuntimeMap": { @@ -909,7 +915,7 @@ "path": "iotlamddb-with-vpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -921,7 +927,7 @@ "path": "iotlamddb-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -929,7 +935,7 @@ "path": "iotlamddb-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -937,13 +943,13 @@ "path": "iotlamddb-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -959,7 +965,7 @@ "path": "iotlamddb-with-vpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -971,7 +977,7 @@ "path": "iotlamddb-with-vpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -979,25 +985,25 @@ "path": "iotlamddb-with-vpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1005,7 +1011,7 @@ "path": "iotlamddb-with-vpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1013,13 +1019,13 @@ "path": "iotlamddb-with-vpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1027,13 +1033,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-iot-lambda/package.json index 4b6f93e9c..c7ff899f7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-s3/package.json b/source/patterns/@aws-solutions-constructs/aws-iot-s3/package.json index 1005d44fc..22454143b 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-s3/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-s3/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-iot-sqs/package.json b/source/patterns/@aws-solutions-constructs/aws-iot-sqs/package.json index b6b62fb1e..2a8be1006 100644 --- a/source/patterns/@aws-solutions-constructs/aws-iot-sqs/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-iot-sqs/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-kinesisfirehose-s3/package.json b/source/patterns/@aws-solutions-constructs/aws-kinesisfirehose-s3/package.json index 510e593ce..383963a1c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-kinesisfirehose-s3/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-kinesisfirehose-s3/package.json @@ -27,6 +27,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "integ-no-clean": "integ-runner --update-on-failed --no-clean", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, diff --git a/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-gluejob/package.json b/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-gluejob/package.json index f2356d88e..cd1d86d36 100644 --- a/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-gluejob/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-gluejob/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-kinesisfirehose-s3/package.json b/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-kinesisfirehose-s3/package.json index f48d2f091..38ab84f46 100644 --- a/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-kinesisfirehose-s3/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-kinesisfirehose-s3/package.json @@ -27,6 +27,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "integ-no-clean": "integ-runner --update-on-failed --no-clean", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, diff --git a/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-lambda/package.json index f57aeba0f..5fd67e39e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-kinesisstreams-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/package.json index 3ded0de9b..49066d588 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js deleted file mode 100644 index 743e4fdbb..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js +++ /dev/null @@ -1,8 +0,0 @@ -exports.handler = async function(event) { - console.log('request:', JSON.stringify(event, undefined, 2)); - return { - statusCode: 200, - headers: { 'Content-Type': 'text/plain' }, - body: `Hello, CDK! You've hit ${event.path}\n` - }; - }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js new file mode 100644 index 000000000..44a0a9467 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js @@ -0,0 +1,21 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +exports.handler = async function(event) { + console.log('request:', JSON.stringify(event, undefined, 2)); + return { + statusCode: 200, + headers: { 'Content-Type': 'text/plain' }, + body: `Hello, CDK! You've hit ${event.path}\n` + }; + }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/integ.json index b12bd009b..308f053b1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamddb-deployFunctionWithExistingVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddb-deployFunctionWithExistingVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddb-deployFunctionWithExistingVpc.assets.json index eb5274673..6a35decc6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddb-deployFunctionWithExistingVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddb-deployFunctionWithExistingVpc.assets.json @@ -1,33 +1,33 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8": { + "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c": { "source": { - "path": "asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8", + "path": "asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip", + "objectKey": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "4972afae9dfcb6552ba9edd9db4d30104b22d5afa2088981cdfdddebd7f38894": { + "6313cd5affa9c247f04094e1099f5285d50e6bf57cd02e5695591427da5e9f97": { "source": { "path": "lamddb-deployFunctionWithExistingVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "4972afae9dfcb6552ba9edd9db4d30104b22d5afa2088981cdfdddebd7f38894.json", + "objectKey": "6313cd5affa9c247f04094e1099f5285d50e6bf57cd02e5695591427da5e9f97.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddb-deployFunctionWithExistingVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddb-deployFunctionWithExistingVpc.template.json index 7fabc3e82..3bdff2a8f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddb-deployFunctionWithExistingVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddb-deployFunctionWithExistingVpc.template.json @@ -576,6 +576,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "lamddb-deployFunctionWithExistingVpc/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -663,7 +669,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, @@ -873,7 +879,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "S3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "Environment": { "Variables": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddbdeployFunctionWithExistingVpcIntegDefaultTestDeployAssertEE08E38E.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddbdeployFunctionWithExistingVpcIntegDefaultTestDeployAssertEE08E38E.assets.json index c81bba48c..ab6949af2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddbdeployFunctionWithExistingVpcIntegDefaultTestDeployAssertEE08E38E.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/lamddbdeployFunctionWithExistingVpcIntegDefaultTestDeployAssertEE08E38E.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/manifest.json index 074dac547..4b32c0177 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamddbdeployFunctionWithExistingVpcIntegDefaultTestDeployAssertEE08E38E.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/4972afae9dfcb6552ba9edd9db4d30104b22d5afa2088981cdfdddebd7f38894.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/6313cd5affa9c247f04094e1099f5285d50e6bf57cd02e5695591427da5e9f97.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -262,6 +262,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamddb-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamddb-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/tree.json index b83994ecf..911c87f13 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithExistingVpc.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "lamddb-deployFunctionWithExistingVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "DDB": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamddb-deployFunctionWithExistingVpc/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcPrivateSubnet1RouteTableB2C5B500" @@ -888,19 +894,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -908,7 +914,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -920,7 +926,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -928,7 +934,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -936,13 +942,13 @@ "path": "lamddb-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-lambda-dynamodb-stack": { @@ -958,7 +964,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/test-lambda-dynamodb-stack/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1021,7 +1027,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1090,19 +1096,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -1130,13 +1136,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -1152,7 +1158,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/test-lambda-dynamodb-stack/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -1160,13 +1166,13 @@ "path": "lamddb-deployFunctionWithExistingVpc/test-lambda-dynamodb-stack/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1179,7 +1185,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "s3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "environment": { "variables": { @@ -1222,13 +1228,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "DynamoTable": { @@ -1264,7 +1270,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.CfnTable", - "version": "2.150.0" + "version": "2.174.0" } }, "ScalingRole": { @@ -1272,19 +1278,19 @@ "path": "lamddb-deployFunctionWithExistingVpc/test-lambda-dynamodb-stack/DynamoTable/ScalingRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.Table", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-dynamodb.LambdaToDynamoDB", - "version": "2.63.0" + "version": "2.76.0" } }, "Integ": { @@ -1300,7 +1306,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1312,7 +1318,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1320,25 +1326,25 @@ "path": "lamddb-deployFunctionWithExistingVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1346,7 +1352,7 @@ "path": "lamddb-deployFunctionWithExistingVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1354,13 +1360,13 @@ "path": "lamddb-deployFunctionWithExistingVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1368,13 +1374,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js deleted file mode 100644 index 743e4fdbb..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js +++ /dev/null @@ -1,8 +0,0 @@ -exports.handler = async function(event) { - console.log('request:', JSON.stringify(event, undefined, 2)); - return { - statusCode: 200, - headers: { 'Content-Type': 'text/plain' }, - body: `Hello, CDK! You've hit ${event.path}\n` - }; - }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js new file mode 100644 index 000000000..44a0a9467 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js @@ -0,0 +1,21 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +exports.handler = async function(event) { + console.log('request:', JSON.stringify(event, undefined, 2)); + return { + statusCode: 200, + headers: { 'Content-Type': 'text/plain' }, + body: `Hello, CDK! You've hit ${event.path}\n` + }; + }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/integ.json index 4f5178c07..3011245e3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamddb-deployFunctionWithVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddb-deployFunctionWithVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddb-deployFunctionWithVpc.assets.json index c3661f54f..e4cb34d3c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddb-deployFunctionWithVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddb-deployFunctionWithVpc.assets.json @@ -1,33 +1,33 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8": { + "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c": { "source": { - "path": "asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8", + "path": "asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip", + "objectKey": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "d24f111c0760c5f2b4edfde3d8c0b7ef9250c5102f44830bfc16aad0e1421108": { + "530f673a7d663315ec57400b014a6cac65f30fa1891cf9f3edc34f5570161a70": { "source": { "path": "lamddb-deployFunctionWithVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "d24f111c0760c5f2b4edfde3d8c0b7ef9250c5102f44830bfc16aad0e1421108.json", + "objectKey": "530f673a7d663315ec57400b014a6cac65f30fa1891cf9f3edc34f5570161a70.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddb-deployFunctionWithVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddb-deployFunctionWithVpc.template.json index ee6b51e67..2bc41c39d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddb-deployFunctionWithVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddb-deployFunctionWithVpc.template.json @@ -167,7 +167,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "S3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "Environment": { "Variables": { @@ -552,6 +552,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "lamddb-deployFunctionWithVpc/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -639,7 +645,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddbdeployFunctionWithVpcIntegDefaultTestDeployAssert0AB8275C.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddbdeployFunctionWithVpcIntegDefaultTestDeployAssert0AB8275C.assets.json index b3ac9377e..dfbcdfbf0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddbdeployFunctionWithVpcIntegDefaultTestDeployAssert0AB8275C.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/lamddbdeployFunctionWithVpcIntegDefaultTestDeployAssert0AB8275C.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/manifest.json index ff174b50b..6cc78fb91 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamddbdeployFunctionWithVpcIntegDefaultTestDeployAssert0AB8275C.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/d24f111c0760c5f2b4edfde3d8c0b7ef9250c5102f44830bfc16aad0e1421108.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/530f673a7d663315ec57400b014a6cac65f30fa1891cf9f3edc34f5570161a70.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -196,6 +196,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamddb-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamddb-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/tree.json index aa9543faf..1c03630bf 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-dynamodb/test/integ.lamddb-deployFunctionWithVpc.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamddb-deployFunctionWithVpc/test-lambda-dynamodb-stack/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -153,19 +153,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -215,7 +215,7 @@ "path": "lamddb-deployFunctionWithVpc/test-lambda-dynamodb-stack/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -223,13 +223,13 @@ "path": "lamddb-deployFunctionWithVpc/test-lambda-dynamodb-stack/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -242,7 +242,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "s3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "environment": { "variables": { @@ -285,13 +285,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "DynamoTable": { @@ -327,7 +327,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.CfnTable", - "version": "2.150.0" + "version": "2.174.0" } }, "ScalingRole": { @@ -335,19 +335,19 @@ "path": "lamddb-deployFunctionWithVpc/test-lambda-dynamodb-stack/DynamoTable/ScalingRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_dynamodb.Table", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-dynamodb.LambdaToDynamoDB", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -374,7 +374,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -418,7 +418,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -426,7 +426,7 @@ "path": "lamddb-deployFunctionWithVpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -448,7 +448,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -467,13 +467,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -517,7 +517,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -525,7 +525,7 @@ "path": "lamddb-deployFunctionWithVpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -547,7 +547,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -566,13 +566,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -584,13 +584,13 @@ "path": "lamddb-deployFunctionWithVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -606,7 +606,7 @@ "path": "lamddb-deployFunctionWithVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -637,7 +637,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -689,19 +689,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -725,13 +725,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -765,13 +765,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "DDB": { @@ -784,6 +784,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamddb-deployFunctionWithVpc/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcisolatedSubnet1RouteTableE442650B" @@ -812,19 +818,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -832,7 +838,7 @@ "path": "lamddb-deployFunctionWithVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -844,7 +850,7 @@ "path": "lamddb-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -852,7 +858,7 @@ "path": "lamddb-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -860,13 +866,13 @@ "path": "lamddb-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -882,7 +888,7 @@ "path": "lamddb-deployFunctionWithVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -894,7 +900,7 @@ "path": "lamddb-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -902,25 +908,25 @@ "path": "lamddb-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -928,7 +934,7 @@ "path": "lamddb-deployFunctionWithVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -936,13 +942,13 @@ "path": "lamddb-deployFunctionWithVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -950,13 +956,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-elasticachememcached/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-elasticachememcached/package.json index a940df3f9..b80ef8391 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-elasticachememcached/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-elasticachememcached/package.json @@ -27,6 +27,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "integ-no-clean": "integ-runner --update-on-failed --no-clean", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-elasticsearch-kibana/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-elasticsearch-kibana/package.json index cfceb99d4..5a0ead936 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-elasticsearch-kibana/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-elasticsearch-kibana/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/package.json index 917f3a49b..6006dc260 100755 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/integ.json index 2c58bd673..389b7ce00 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamevt-deployFunctionWithNewEventBus/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevt-deployFunctionWithNewEventBus.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevt-deployFunctionWithNewEventBus.assets.json index 03e193f84..fc57a8cd3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevt-deployFunctionWithNewEventBus.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevt-deployFunctionWithNewEventBus.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "e074a360d11ffff03324dba066e398a9b94330410b6efd3a669b020fa0cb8723": { + "4c34f969e8b375f5afac5d84838c625153efb5f4498451f2d2e5e01310edfa30": { "source": { "path": "lamevt-deployFunctionWithNewEventBus.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "e074a360d11ffff03324dba066e398a9b94330410b6efd3a669b020fa0cb8723.json", + "objectKey": "4c34f969e8b375f5afac5d84838c625153efb5f4498451f2d2e5e01310edfa30.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevt-deployFunctionWithNewEventBus.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevt-deployFunctionWithNewEventBus.template.json index c021e2464..b268be4c7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevt-deployFunctionWithNewEventBus.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevt-deployFunctionWithNewEventBus.template.json @@ -516,6 +516,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamevt-deployFunctionWithNewEventBus/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -603,7 +609,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevtdeployFunctionWithNewEventBusIntegDefaultTestDeployAssert890EC771.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevtdeployFunctionWithNewEventBusIntegDefaultTestDeployAssert890EC771.assets.json index b7bf6e01c..86977329d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevtdeployFunctionWithNewEventBusIntegDefaultTestDeployAssert890EC771.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/lamevtdeployFunctionWithNewEventBusIntegDefaultTestDeployAssert890EC771.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/manifest.json index c36ddeb3c..232137184 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamevtdeployFunctionWithNewEventBusIntegDefaultTestDeployAssert890EC771.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/e074a360d11ffff03324dba066e398a9b94330410b6efd3a669b020fa0cb8723.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/4c34f969e8b375f5afac5d84838c625153efb5f4498451f2d2e5e01310edfa30.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -196,6 +196,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamevt-deployFunctionWithNewEventBus/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamevt-deployFunctionWithNewEventBus/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/tree.json index 6b5f93ddf..3737d12a3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithNewEventBus.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/test-lambda-eventbridge/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -135,19 +135,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -175,13 +175,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -197,7 +197,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/test-lambda-eventbridge/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -205,13 +205,13 @@ "path": "lamevt-deployFunctionWithNewEventBus/test-lambda-eventbridge/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -267,13 +267,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "CustomEventBus": { @@ -291,19 +291,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.CfnEventBus", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_events.EventBus", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-eventbridge.LambdaToEventbridge", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -330,7 +330,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -374,7 +374,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -382,7 +382,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -404,7 +404,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -423,13 +423,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -473,7 +473,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -481,7 +481,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -503,7 +503,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -522,13 +522,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -540,13 +540,13 @@ "path": "lamevt-deployFunctionWithNewEventBus/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -562,7 +562,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -593,7 +593,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -645,19 +645,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -681,13 +681,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -721,13 +721,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "CLOUDWATCH_EVENTS": { @@ -740,6 +740,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamevt-deployFunctionWithNewEventBus/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -777,19 +783,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -797,7 +803,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -809,7 +815,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -817,7 +823,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -825,13 +831,13 @@ "path": "lamevt-deployFunctionWithNewEventBus/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamevt-deployFunctionWithNewEventBus-CLOUDWATCH_EVENTS-security-group": { @@ -887,13 +893,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -909,7 +915,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -921,7 +927,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -929,25 +935,25 @@ "path": "lamevt-deployFunctionWithNewEventBus/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -955,7 +961,7 @@ "path": "lamevt-deployFunctionWithNewEventBus/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -963,13 +969,13 @@ "path": "lamevt-deployFunctionWithNewEventBus/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -977,13 +983,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/integ.json index bde710e19..c25f63f9e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamevt-deployFunctionWithVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevt-deployFunctionWithVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevt-deployFunctionWithVpc.assets.json index b9b3e254c..9d0208fdc 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevt-deployFunctionWithVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevt-deployFunctionWithVpc.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "c859ebfc1a8e69105ddf0ac76e8d4df69a4e1bc7474c8eccc14e5acc0c391ccb": { + "5d0894ee87f8a17ffa9189a02c7cce98e91e594ab098e8ca22fcb552e8fc7368": { "source": { "path": "lamevt-deployFunctionWithVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "c859ebfc1a8e69105ddf0ac76e8d4df69a4e1bc7474c8eccc14e5acc0c391ccb.json", + "objectKey": "5d0894ee87f8a17ffa9189a02c7cce98e91e594ab098e8ca22fcb552e8fc7368.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevt-deployFunctionWithVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevt-deployFunctionWithVpc.template.json index a2d53a8a8..55f8ca123 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevt-deployFunctionWithVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevt-deployFunctionWithVpc.template.json @@ -522,6 +522,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamevt-deployFunctionWithVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -609,7 +615,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevtdeployFunctionWithVpcIntegDefaultTestDeployAssertF29241C9.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevtdeployFunctionWithVpcIntegDefaultTestDeployAssertF29241C9.assets.json index 9403cf36f..9a6bbac85 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevtdeployFunctionWithVpcIntegDefaultTestDeployAssertF29241C9.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/lamevtdeployFunctionWithVpcIntegDefaultTestDeployAssertF29241C9.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/manifest.json index 04f8e6fd2..9d830c410 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamevtdeployFunctionWithVpcIntegDefaultTestDeployAssertF29241C9.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c859ebfc1a8e69105ddf0ac76e8d4df69a4e1bc7474c8eccc14e5acc0c391ccb.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/5d0894ee87f8a17ffa9189a02c7cce98e91e594ab098e8ca22fcb552e8fc7368.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -190,6 +190,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamevt-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamevt-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/tree.json index 212b862e2..67f9d2904 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-eventbridge/test/integ.lamevt-deployFunctionWithVpc.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamevt-deployFunctionWithVpc/test-lambda-eventbridge/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -149,19 +149,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -189,13 +189,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -211,7 +211,7 @@ "path": "lamevt-deployFunctionWithVpc/test-lambda-eventbridge/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -219,13 +219,13 @@ "path": "lamevt-deployFunctionWithVpc/test-lambda-eventbridge/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -279,13 +279,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "default-event-bus": { @@ -293,13 +293,13 @@ "path": "lamevt-deployFunctionWithVpc/test-lambda-eventbridge/default-event-bus", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-eventbridge.LambdaToEventbridge", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -326,7 +326,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -370,7 +370,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -378,7 +378,7 @@ "path": "lamevt-deployFunctionWithVpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -400,7 +400,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -419,13 +419,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -469,7 +469,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -477,7 +477,7 @@ "path": "lamevt-deployFunctionWithVpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -499,7 +499,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -518,13 +518,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -536,13 +536,13 @@ "path": "lamevt-deployFunctionWithVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -558,7 +558,7 @@ "path": "lamevt-deployFunctionWithVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -589,7 +589,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -641,19 +641,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -677,13 +677,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -717,13 +717,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "CLOUDWATCH_EVENTS": { @@ -736,6 +736,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamevt-deployFunctionWithVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -773,19 +779,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -793,7 +799,7 @@ "path": "lamevt-deployFunctionWithVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -805,7 +811,7 @@ "path": "lamevt-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -813,7 +819,7 @@ "path": "lamevt-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -821,13 +827,13 @@ "path": "lamevt-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamevt-deployFunctionWithVpc-CLOUDWATCH_EVENTS-security-group": { @@ -883,13 +889,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -905,7 +911,7 @@ "path": "lamevt-deployFunctionWithVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -917,7 +923,7 @@ "path": "lamevt-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -925,25 +931,25 @@ "path": "lamevt-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -951,7 +957,7 @@ "path": "lamevt-deployFunctionWithVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -959,13 +965,13 @@ "path": "lamevt-deployFunctionWithVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -973,13 +979,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/lib/index.ts b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/lib/index.ts index bdccc5944..172ba0e9c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/lib/index.ts +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/lib/index.ts @@ -28,7 +28,7 @@ export interface LambdaToKendraProps { * * @default - Optional user provided props to override the default props for the Kendra index. Is this required? */ - readonly kendraIndexProps?: kendra.CfnIndexProps; + readonly kendraIndexProps?: kendra.CfnIndexProps | any; /** * A list of data sources that will provide data to the Kendra index. ?At least 1 must be specified. We will do majority of * processing for some data sources (S3 crawler initially), but for others the props must be complete (e.g. proper roleArn, etc.) @@ -111,10 +111,6 @@ export class LambdaToKendra extends Construct { throw new Error('You may not provide both kendraIndexProps and existingKendraIndexObj'); } - if (props.kendraIndexProps && props.kendraDataSourcesProps) { - throw new Error('You may not provide both kendraDataSourcesProps and existingKendraIndexObj'); - } - if (props.deployVpc || props.existingVpc) { this.vpc = defaults.buildVpc(scope, { defaultVpcProps: defaults.DefaultIsolatedVpcProps(), diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/package.json index cd0cda92d..1dc20cdd2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/package.json @@ -23,6 +23,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "integ-no-clean": "integ-runner --update-on-failed --no-clean", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f/index.js new file mode 100644 index 000000000..297328cfd --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f/index.js @@ -0,0 +1,21 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +exports.handler = async function(event) { + console.log('request:', JSON.stringify(event, undefined, 2)); + return { + statusCode: 200, + headers: { 'Content-Type': 'text/plain' }, + body: `Stub Lambda function for testing - ${event.path}\n` + }; + }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/asset.faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/asset.faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6/index.js new file mode 100644 index 000000000..2f92d06c1 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/asset.faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6/index.js @@ -0,0 +1 @@ +"use strict";var f=Object.create,i=Object.defineProperty,I=Object.getOwnPropertyDescriptor,C=Object.getOwnPropertyNames,w=Object.getPrototypeOf,P=Object.prototype.hasOwnProperty,A=(t,e)=>{for(var o in e)i(t,o,{get:e[o],enumerable:!0})},d=(t,e,o,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of C(e))!P.call(t,s)&&s!==o&&i(t,s,{get:()=>e[s],enumerable:!(r=I(e,s))||r.enumerable});return t},l=(t,e,o)=>(o=t!=null?f(w(t)):{},d(e||!t||!t.__esModule?i(o,"default",{value:t,enumerable:!0}):o,t)),B=t=>d(i({},"__esModule",{value:!0}),t),q={};A(q,{autoDeleteHandler:()=>S,handler:()=>H}),module.exports=B(q);var h=require("@aws-sdk/client-s3"),y=l(require("https")),m=l(require("url")),a={sendHttpRequest:D,log:T,includeStackTraces:!0,userHandlerIndex:"./index"},p="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",L="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";function R(t){return async(e,o)=>{let r={...e,ResponseURL:"..."};if(a.log(JSON.stringify(r,void 0,2)),e.RequestType==="Delete"&&e.PhysicalResourceId===p){a.log("ignoring DELETE event caused by a failed CREATE event"),await u("SUCCESS",e);return}try{let s=await t(r,o),n=k(e,s);await u("SUCCESS",n)}catch(s){let n={...e,Reason:a.includeStackTraces?s.stack:s.message};n.PhysicalResourceId||(e.RequestType==="Create"?(a.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),n.PhysicalResourceId=p):a.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(e)}`)),await u("FAILED",n)}}}function k(t,e={}){let o=e.PhysicalResourceId??t.PhysicalResourceId??t.RequestId;if(t.RequestType==="Delete"&&o!==t.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${t.PhysicalResourceId}" to "${e.PhysicalResourceId}" during deletion`);return{...t,...e,PhysicalResourceId:o}}async function u(t,e){let o={Status:t,Reason:e.Reason??t,StackId:e.StackId,RequestId:e.RequestId,PhysicalResourceId:e.PhysicalResourceId||L,LogicalResourceId:e.LogicalResourceId,NoEcho:e.NoEcho,Data:e.Data},r=m.parse(e.ResponseURL),s=`${r.protocol}//${r.hostname}/${r.pathname}?***`;a.log("submit response to cloudformation",s,o);let n=JSON.stringify(o),E={hostname:r.hostname,path:r.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(n,"utf8")}};await O({attempts:5,sleep:1e3},a.sendHttpRequest)(E,n)}async function D(t,e){return new Promise((o,r)=>{try{let s=y.request(t,n=>{n.resume(),!n.statusCode||n.statusCode>=400?r(new Error(`Unsuccessful HTTP response: ${n.statusCode}`)):o()});s.on("error",r),s.write(e),s.end()}catch(s){r(s)}})}function T(t,...e){console.log(t,...e)}function O(t,e){return async(...o)=>{let r=t.attempts,s=t.sleep;for(;;)try{return await e(...o)}catch(n){if(r--<=0)throw n;await b(Math.floor(Math.random()*s)),s*=2}}}async function b(t){return new Promise(e=>setTimeout(e,t))}var g="aws-cdk:auto-delete-objects",x=JSON.stringify({Version:"2012-10-17",Statement:[]}),c=new h.S3({}),H=R(S);async function S(t){switch(t.RequestType){case"Create":return;case"Update":return{PhysicalResourceId:(await F(t)).PhysicalResourceId};case"Delete":return N(t.ResourceProperties?.BucketName)}}async function F(t){let e=t,o=e.OldResourceProperties?.BucketName;return{PhysicalResourceId:e.ResourceProperties?.BucketName??o}}async function _(t){try{let e=(await c.getBucketPolicy({Bucket:t}))?.Policy??x,o=JSON.parse(e);o.Statement.push({Principal:"*",Effect:"Deny",Action:["s3:PutObject"],Resource:[`arn:aws:s3:::${t}/*`]}),await c.putBucketPolicy({Bucket:t,Policy:JSON.stringify(o)})}catch(e){if(e.name==="NoSuchBucket")throw e;console.log(`Could not set new object deny policy on bucket '${t}' prior to deletion.`)}}async function U(t){let e;do{e=await c.listObjectVersions({Bucket:t});let o=[...e.Versions??[],...e.DeleteMarkers??[]];if(o.length===0)return;let r=o.map(s=>({Key:s.Key,VersionId:s.VersionId}));await c.deleteObjects({Bucket:t,Delete:{Objects:r}})}while(e?.IsTruncated)}async function N(t){if(!t)throw new Error("No BucketName was provided.");try{if(!await W(t)){console.log(`Bucket does not have '${g}' tag, skipping cleaning.`);return}await _(t),await U(t)}catch(e){if(e.name==="NoSuchBucket"){console.log(`Bucket '${t}' does not exist.`);return}throw e}}async function W(t){return(await c.getBucketTagging({Bucket:t})).TagSet?.some(o=>o.Key===g&&o.Value==="true")} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/cdk.out new file mode 100644 index 000000000..c6e612584 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/cdk.out @@ -0,0 +1 @@ +{"version":"38.0.1"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/integ.json new file mode 100644 index 000000000..f487f7d00 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/integ.json @@ -0,0 +1,12 @@ +{ + "version": "38.0.1", + "testCases": { + "lamken-genai-index/Integ/DefaultTest": { + "stacks": [ + "lamken-genai-index" + ], + "assertionStack": "lamken-genai-index/Integ/DefaultTest/DeployAssert", + "assertionStackName": "lamkengenaiindexIntegDefaultTestDeployAssert33BD740C" + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamken-genai-index.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamken-genai-index.assets.json new file mode 100644 index 000000000..282174bbc --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamken-genai-index.assets.json @@ -0,0 +1,45 @@ +{ + "version": "38.0.1", + "files": { + "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6": { + "source": { + "path": "asset.faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6", + "packaging": "zip" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6.zip", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + }, + "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f": { + "source": { + "path": "asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f", + "packaging": "zip" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f.zip", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + }, + "fbb962ff400d6cb12aa78099ff65822e5d5456a2b526afd38675943c4b497988": { + "source": { + "path": "lamken-genai-index.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "fbb962ff400d6cb12aa78099ff65822e5d5456a2b526afd38675943c4b497988.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamken-genai-index.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamken-genai-index.template.json new file mode 100644 index 000000000..2294b1a20 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamken-genai-index.template.json @@ -0,0 +1,997 @@ +{ + "Description": "Integration Test for aws-lambda-kendra", + "Resources": { + "contentBucketLog5B9803A6": { + "Type": "AWS::S3::Bucket", + "Properties": { + "BucketEncryption": { + "ServerSideEncryptionConfiguration": [ + { + "ServerSideEncryptionByDefault": { + "SSEAlgorithm": "AES256" + } + } + ] + }, + "Tags": [ + { + "Key": "aws-cdk:auto-delete-objects", + "Value": "true" + } + ], + "VersioningConfiguration": { + "Status": "Enabled" + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete", + "Metadata": { + "cfn_nag": { + "rules_to_suppress": [ + { + "id": "W35", + "reason": "This is a log bucket" + } + ] + } + } + }, + "contentBucketLogPolicy52155F9C": { + "Type": "AWS::S3::BucketPolicy", + "Properties": { + "Bucket": { + "Ref": "contentBucketLog5B9803A6" + }, + "PolicyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:List*", + "s3:PutBucketPolicy" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092", + "Arn" + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": "s3:PutObject", + "Condition": { + "ArnLike": { + "aws:SourceArn": { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + } + }, + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "logging.s3.amazonaws.com" + }, + "Resource": { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + "/*" + ] + ] + } + } + ], + "Version": "2012-10-17" + } + } + }, + "contentBucketLogAutoDeleteObjectsCustomResource533B8207": { + "Type": "Custom::S3AutoDeleteObjects", + "Properties": { + "ServiceToken": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderHandler9D90184F", + "Arn" + ] + }, + "BucketName": { + "Ref": "contentBucketLog5B9803A6" + } + }, + "DependsOn": [ + "contentBucketLogPolicy52155F9C" + ], + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Version": "2012-10-17", + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "lambda.amazonaws.com" + } + } + ] + }, + "ManagedPolicyArns": [ + { + "Fn::Sub": "arn:${AWS::Partition}:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" + } + ] + } + }, + "CustomS3AutoDeleteObjectsCustomResourceProviderHandler9D90184F": { + "Type": "AWS::Lambda::Function", + "Properties": { + "Code": { + "S3Bucket": { + "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" + }, + "S3Key": "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6.zip" + }, + "Timeout": 900, + "MemorySize": 128, + "Handler": "index.handler", + "Role": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092", + "Arn" + ] + }, + "Runtime": { + "Fn::FindInMap": [ + "LatestNodeRuntimeMap", + { + "Ref": "AWS::Region" + }, + "value" + ] + }, + "Description": { + "Fn::Join": [ + "", + [ + "Lambda function for auto-deleting objects in ", + { + "Ref": "contentBucketLog5B9803A6" + }, + " S3 bucket." + ] + ] + } + }, + "DependsOn": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092" + ], + "Metadata": { + "cfn_nag": { + "rules_to_suppress": [ + { + "id": "W58", + "reason": "CDK generated custom resource" + }, + { + "id": "W89", + "reason": "CDK generated custom resource" + }, + { + "id": "W92", + "reason": "CDK generated custom resource" + } + ] + } + } + }, + "contentBucket356CF7A5": { + "Type": "AWS::S3::Bucket", + "Properties": { + "BucketEncryption": { + "ServerSideEncryptionConfiguration": [ + { + "ServerSideEncryptionByDefault": { + "SSEAlgorithm": "AES256" + } + } + ] + }, + "LoggingConfiguration": { + "DestinationBucketName": { + "Ref": "contentBucketLog5B9803A6" + } + }, + "Tags": [ + { + "Key": "aws-cdk:auto-delete-objects", + "Value": "true" + } + ], + "VersioningConfiguration": { + "Status": "Enabled" + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "contentBucketPolicy71256B1B": { + "Type": "AWS::S3::BucketPolicy", + "Properties": { + "Bucket": { + "Ref": "contentBucket356CF7A5" + }, + "PolicyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:List*", + "s3:PutBucketPolicy" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092", + "Arn" + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + } + ], + "Version": "2012-10-17" + } + } + }, + "contentBucketAutoDeleteObjectsCustomResourceD6F9707E": { + "Type": "Custom::S3AutoDeleteObjects", + "Properties": { + "ServiceToken": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderHandler9D90184F", + "Arn" + ] + }, + "BucketName": { + "Ref": "contentBucket356CF7A5" + } + }, + "DependsOn": [ + "contentBucketPolicy71256B1B" + ], + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "genaiindexLambdaFunctionServiceRoleE929EAD8": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "lambda.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "Policies": [ + { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "logs:CreateLogGroup", + "logs:CreateLogStream", + "logs:PutLogEvents" + ], + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/lambda/*" + ] + ] + } + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "LambdaFunctionServiceRolePolicy" + } + ] + }, + "Metadata": { + "guard": { + "SuppressedRules": [ + "IAM_NO_INLINE_POLICY_CHECK" + ] + } + } + }, + "genaiindexLambdaFunctionServiceRoleDefaultPolicy18386D50": { + "Type": "AWS::IAM::Policy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "xray:PutTelemetryRecords", + "xray:PutTraceSegments" + ], + "Effect": "Allow", + "Resource": "*" + }, + { + "Action": [ + "kendra:BatchGet*", + "kendra:Describe*", + "kendra:Get*", + "kendra:List*", + "kendra:Query", + "kendra:Retrieve", + "kendra:SubmitFeedback" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "genaiindexkendraindexgenaiindex5FFB72B4", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "genaiindexLambdaFunctionServiceRoleDefaultPolicy18386D50", + "Roles": [ + { + "Ref": "genaiindexLambdaFunctionServiceRoleE929EAD8" + } + ] + }, + "Metadata": { + "cfn_nag": { + "rules_to_suppress": [ + { + "id": "W12", + "reason": "Lambda needs the following minimum required permissions to send trace data to X-Ray and access ENIs in a VPC." + } + ] + } + } + }, + "genaiindexLambdaFunctionD79F5018": { + "Type": "AWS::Lambda::Function", + "Properties": { + "Code": { + "S3Bucket": { + "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" + }, + "S3Key": "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f.zip" + }, + "Environment": { + "Variables": { + "AWS_NODEJS_CONNECTION_REUSE_ENABLED": "1", + "KENDRA_INDEX_ID": { + "Fn::GetAtt": [ + "genaiindexkendraindexgenaiindex5FFB72B4", + "Id" + ] + } + } + }, + "Handler": "index.handler", + "Role": { + "Fn::GetAtt": [ + "genaiindexLambdaFunctionServiceRoleE929EAD8", + "Arn" + ] + }, + "Runtime": "nodejs20.x", + "TracingConfig": { + "Mode": "Active" + } + }, + "DependsOn": [ + "genaiindexLambdaFunctionServiceRoleDefaultPolicy18386D50", + "genaiindexLambdaFunctionServiceRoleE929EAD8" + ], + "Metadata": { + "cfn_nag": { + "rules_to_suppress": [ + { + "id": "W58", + "reason": "Lambda functions has the required permission to write CloudWatch Logs. It uses custom policy instead of arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole with tighter permissions." + }, + { + "id": "W89", + "reason": "This is not a rule for the general case, just for specific use cases/industries" + }, + { + "id": "W92", + "reason": "Impossible for us to define the correct concurrency for clients" + } + ] + } + } + }, + "genaiindexkendraindexrolegenaiindex2848B249": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "kendra.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "Description": "Allow Kendra index to write CloudWatch Logs", + "Policies": [ + { + "PolicyDocument": { + "Statement": [ + { + "Action": "cloudwatch:PutMetricData", + "Condition": { + "StringEquals": { + "cloudwatch:namespace": "AWS/Kendra" + } + }, + "Effect": "Allow", + "Resource": "*" + }, + { + "Action": "logs:CreateLogGroup", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/kendra/*" + ] + ] + } + }, + { + "Action": "logs:DescribeLogGroups", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/kendra/*" + ] + ] + } + }, + { + "Action": [ + "logs:CreateLogStream", + "logs:DescribeLogStream", + "logs:PutLogEvents" + ], + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/kendra/*:log-stream:*" + ] + ] + } + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "AllowLogging" + } + ] + }, + "Metadata": { + "cfn_nag": { + "rules_to_suppress": [ + { + "id": "W11", + "reason": "PutMetricData does not allow resource specification, scope is narrowed by the namespace condition. https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazoncloudwatch.html" + } + ] + }, + "guard": { + "SuppressedRules": [ + "IAM_NO_INLINE_POLICY_CHECK" + ] + } + } + }, + "genaiindexkendraindexgenaiindex5FFB72B4": { + "Type": "AWS::Kendra::Index", + "Properties": { + "Edition": "GEN_AI_ENTERPRISE_EDITION", + "Name": "genai-index", + "RoleArn": { + "Fn::GetAtt": [ + "genaiindexkendraindexrolegenaiindex2848B249", + "Arn" + ] + } + }, + "Metadata": { + "cfn_nag": { + "rules_to_suppress": [ + { + "id": "W80", + "reason": "We consulted the Kendra TFC and they confirmed the default encryption is sufficient for general use cases" + } + ] + } + } + }, + "genaiindexdatasourcerolegenaiindex0F97D641C": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "kendra.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "Description": "Policy for Kendra S3 Data Source", + "Policies": [ + { + "PolicyDocument": { + "Statement": [ + { + "Action": "s3:GetObject", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:s3:::", + { + "Ref": "contentBucket356CF7A5" + }, + "/*" + ] + ] + } + }, + { + "Action": "s3:ListBucket", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:s3:::", + { + "Ref": "contentBucket356CF7A5" + } + ] + ] + } + }, + { + "Action": [ + "kendra:BatchDeleteDocument", + "kendra:BatchPutDocument" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "genaiindexkendraindexgenaiindex5FFB72B4", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "s3CrawlPolicy" + } + ] + }, + "Metadata": { + "guard": { + "SuppressedRules": [ + "IAM_NO_INLINE_POLICY_CHECK" + ] + } + } + }, + "genaiindexdatasourcegenaiindex07856CA22": { + "Type": "AWS::Kendra::DataSource", + "Properties": { + "DataSourceConfiguration": { + "S3Configuration": { + "BucketName": { + "Ref": "contentBucket356CF7A5" + } + } + }, + "IndexId": { + "Ref": "genaiindexkendraindexgenaiindex5FFB72B4" + }, + "Name": { + "Fn::Join": [ + "", + [ + "s3-datasourcegenai-index0-", + { + "Fn::Select": [ + 2, + { + "Fn::Split": [ + "/", + { + "Ref": "AWS::StackId" + } + ] + } + ] + } + ] + ] + }, + "RoleArn": { + "Fn::GetAtt": [ + "genaiindexdatasourcerolegenaiindex0F97D641C", + "Arn" + ] + }, + "Type": "S3" + } + } + }, + "Mappings": { + "LatestNodeRuntimeMap": { + "af-south-1": { + "value": "nodejs20.x" + }, + "ap-east-1": { + "value": "nodejs20.x" + }, + "ap-northeast-1": { + "value": "nodejs20.x" + }, + "ap-northeast-2": { + "value": "nodejs20.x" + }, + "ap-northeast-3": { + "value": "nodejs20.x" + }, + "ap-south-1": { + "value": "nodejs20.x" + }, + "ap-south-2": { + "value": "nodejs20.x" + }, + "ap-southeast-1": { + "value": "nodejs20.x" + }, + "ap-southeast-2": { + "value": "nodejs20.x" + }, + "ap-southeast-3": { + "value": "nodejs20.x" + }, + "ap-southeast-4": { + "value": "nodejs20.x" + }, + "ap-southeast-5": { + "value": "nodejs20.x" + }, + "ap-southeast-7": { + "value": "nodejs20.x" + }, + "ca-central-1": { + "value": "nodejs20.x" + }, + "ca-west-1": { + "value": "nodejs20.x" + }, + "cn-north-1": { + "value": "nodejs18.x" + }, + "cn-northwest-1": { + "value": "nodejs18.x" + }, + "eu-central-1": { + "value": "nodejs20.x" + }, + "eu-central-2": { + "value": "nodejs20.x" + }, + "eu-isoe-west-1": { + "value": "nodejs18.x" + }, + "eu-north-1": { + "value": "nodejs20.x" + }, + "eu-south-1": { + "value": "nodejs20.x" + }, + "eu-south-2": { + "value": "nodejs20.x" + }, + "eu-west-1": { + "value": "nodejs20.x" + }, + "eu-west-2": { + "value": "nodejs20.x" + }, + "eu-west-3": { + "value": "nodejs20.x" + }, + "il-central-1": { + "value": "nodejs20.x" + }, + "me-central-1": { + "value": "nodejs20.x" + }, + "me-south-1": { + "value": "nodejs20.x" + }, + "mx-central-1": { + "value": "nodejs20.x" + }, + "sa-east-1": { + "value": "nodejs20.x" + }, + "us-east-1": { + "value": "nodejs20.x" + }, + "us-east-2": { + "value": "nodejs20.x" + }, + "us-gov-east-1": { + "value": "nodejs18.x" + }, + "us-gov-west-1": { + "value": "nodejs18.x" + }, + "us-iso-east-1": { + "value": "nodejs18.x" + }, + "us-iso-west-1": { + "value": "nodejs18.x" + }, + "us-isob-east-1": { + "value": "nodejs18.x" + }, + "us-west-1": { + "value": "nodejs20.x" + }, + "us-west-2": { + "value": "nodejs20.x" + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.assets.json new file mode 100644 index 000000000..b0cc98088 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.assets.json @@ -0,0 +1,19 @@ +{ + "version": "38.0.1", + "files": { + "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { + "source": { + "path": "lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.template.json new file mode 100644 index 000000000..ad9d0fb73 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.template.json @@ -0,0 +1,36 @@ +{ + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/manifest.json new file mode 100644 index 000000000..7e745ec1d --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/manifest.json @@ -0,0 +1,209 @@ +{ + "version": "38.0.1", + "artifacts": { + "lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "lamkengenaiindexIntegDefaultTestDeployAssert33BD740C": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.template.json", + "terminationProtection": false, + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "lamkengenaiindexIntegDefaultTestDeployAssert33BD740C.assets" + ], + "metadata": { + "/lamken-genai-index/Integ/DefaultTest/DeployAssert/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/lamken-genai-index/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "lamken-genai-index/Integ/DefaultTest/DeployAssert" + }, + "lamken-genai-index.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "lamken-genai-index.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "lamken-genai-index": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "lamken-genai-index.template.json", + "terminationProtection": false, + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/fbb962ff400d6cb12aa78099ff65822e5d5456a2b526afd38675943c4b497988.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "lamken-genai-index.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "lamken-genai-index.assets" + ], + "metadata": { + "/lamken-genai-index/contentBucketLog/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "contentBucketLog5B9803A6" + } + ], + "/lamken-genai-index/contentBucketLog/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "contentBucketLogPolicy52155F9C" + } + ], + "/lamken-genai-index/contentBucketLog/AutoDeleteObjectsCustomResource/Default": [ + { + "type": "aws:cdk:logicalId", + "data": "contentBucketLogAutoDeleteObjectsCustomResource533B8207" + } + ], + "/lamken-genai-index/LatestNodeRuntimeMap": [ + { + "type": "aws:cdk:logicalId", + "data": "LatestNodeRuntimeMap" + } + ], + "/lamken-genai-index/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], + "/lamken-genai-index/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ + { + "type": "aws:cdk:logicalId", + "data": "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092" + } + ], + "/lamken-genai-index/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler": [ + { + "type": "aws:cdk:logicalId", + "data": "CustomS3AutoDeleteObjectsCustomResourceProviderHandler9D90184F" + } + ], + "/lamken-genai-index/contentBucket/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "contentBucket356CF7A5" + } + ], + "/lamken-genai-index/contentBucket/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "contentBucketPolicy71256B1B" + } + ], + "/lamken-genai-index/contentBucket/AutoDeleteObjectsCustomResource/Default": [ + { + "type": "aws:cdk:logicalId", + "data": "contentBucketAutoDeleteObjectsCustomResourceD6F9707E" + } + ], + "/lamken-genai-index/genai-index/LambdaFunctionServiceRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "genaiindexLambdaFunctionServiceRoleE929EAD8" + } + ], + "/lamken-genai-index/genai-index/LambdaFunctionServiceRole/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "genaiindexLambdaFunctionServiceRoleDefaultPolicy18386D50" + } + ], + "/lamken-genai-index/genai-index/LambdaFunction/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "genaiindexLambdaFunctionD79F5018" + } + ], + "/lamken-genai-index/genai-index/kendra-index-role-genai-index/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "genaiindexkendraindexrolegenaiindex2848B249" + } + ], + "/lamken-genai-index/genai-index/kendra-index-genai-index": [ + { + "type": "aws:cdk:logicalId", + "data": "genaiindexkendraindexgenaiindex5FFB72B4" + } + ], + "/lamken-genai-index/genai-index/data-source-role-genai-index0/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "genaiindexdatasourcerolegenaiindex0F97D641C" + } + ], + "/lamken-genai-index/genai-index/data-source-genai-index0": [ + { + "type": "aws:cdk:logicalId", + "data": "genaiindexdatasourcegenaiindex07856CA22" + } + ], + "/lamken-genai-index/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/lamken-genai-index/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "lamken-genai-index" + }, + "Tree": { + "type": "cdk:tree", + "properties": { + "file": "tree.json" + } + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/tree.json new file mode 100644 index 000000000..0ec93f509 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.js.snapshot/tree.json @@ -0,0 +1,1044 @@ +{ + "version": "tree-0.1", + "tree": { + "id": "App", + "path": "", + "children": { + "lamken-genai-index": { + "id": "lamken-genai-index", + "path": "lamken-genai-index", + "children": { + "contentBucketLog": { + "id": "contentBucketLog", + "path": "lamken-genai-index/contentBucketLog", + "children": { + "Resource": { + "id": "Resource", + "path": "lamken-genai-index/contentBucketLog/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::Bucket", + "aws:cdk:cloudformation:props": { + "bucketEncryption": { + "serverSideEncryptionConfiguration": [ + { + "serverSideEncryptionByDefault": { + "sseAlgorithm": "AES256" + } + } + ] + }, + "tags": [ + { + "key": "aws-cdk:auto-delete-objects", + "value": "true" + } + ], + "versioningConfiguration": { + "status": "Enabled" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.CfnBucket", + "version": "2.173.2" + } + }, + "Policy": { + "id": "Policy", + "path": "lamken-genai-index/contentBucketLog/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "lamken-genai-index/contentBucketLog/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::BucketPolicy", + "aws:cdk:cloudformation:props": { + "bucket": { + "Ref": "contentBucketLog5B9803A6" + }, + "policyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:List*", + "s3:PutBucketPolicy" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092", + "Arn" + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": "s3:PutObject", + "Condition": { + "ArnLike": { + "aws:SourceArn": { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + } + }, + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "logging.s3.amazonaws.com" + }, + "Resource": { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucketLog5B9803A6", + "Arn" + ] + }, + "/*" + ] + ] + } + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", + "version": "2.173.2" + } + }, + "AutoDeleteObjectsCustomResource": { + "id": "AutoDeleteObjectsCustomResource", + "path": "lamken-genai-index/contentBucketLog/AutoDeleteObjectsCustomResource", + "children": { + "Default": { + "id": "Default", + "path": "lamken-genai-index/contentBucketLog/AutoDeleteObjectsCustomResource/Default", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnResource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.CustomResource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.Bucket", + "version": "2.173.2" + } + }, + "LatestNodeRuntimeMap": { + "id": "LatestNodeRuntimeMap", + "path": "lamken-genai-index/LatestNodeRuntimeMap", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnMapping", + "version": "2.173.2" + } + }, + "Custom::S3AutoDeleteObjectsCustomResourceProvider": { + "id": "Custom::S3AutoDeleteObjectsCustomResourceProvider", + "path": "lamken-genai-index/Custom::S3AutoDeleteObjectsCustomResourceProvider", + "children": { + "Staging": { + "id": "Staging", + "path": "lamken-genai-index/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", + "constructInfo": { + "fqn": "aws-cdk-lib.AssetStaging", + "version": "2.173.2" + } + }, + "Role": { + "id": "Role", + "path": "lamken-genai-index/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnResource", + "version": "2.173.2" + } + }, + "Handler": { + "id": "Handler", + "path": "lamken-genai-index/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnResource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.CustomResourceProviderBase", + "version": "2.173.2" + } + }, + "contentBucket": { + "id": "contentBucket", + "path": "lamken-genai-index/contentBucket", + "children": { + "Resource": { + "id": "Resource", + "path": "lamken-genai-index/contentBucket/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::Bucket", + "aws:cdk:cloudformation:props": { + "bucketEncryption": { + "serverSideEncryptionConfiguration": [ + { + "serverSideEncryptionByDefault": { + "sseAlgorithm": "AES256" + } + } + ] + }, + "loggingConfiguration": { + "destinationBucketName": { + "Ref": "contentBucketLog5B9803A6" + } + }, + "tags": [ + { + "key": "aws-cdk:auto-delete-objects", + "value": "true" + } + ], + "versioningConfiguration": { + "status": "Enabled" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.CfnBucket", + "version": "2.173.2" + } + }, + "Policy": { + "id": "Policy", + "path": "lamken-genai-index/contentBucket/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "lamken-genai-index/contentBucket/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::BucketPolicy", + "aws:cdk:cloudformation:props": { + "bucket": { + "Ref": "contentBucket356CF7A5" + }, + "policyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:List*", + "s3:PutBucketPolicy" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092", + "Arn" + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "contentBucket356CF7A5", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", + "version": "2.173.2" + } + }, + "AutoDeleteObjectsCustomResource": { + "id": "AutoDeleteObjectsCustomResource", + "path": "lamken-genai-index/contentBucket/AutoDeleteObjectsCustomResource", + "children": { + "Default": { + "id": "Default", + "path": "lamken-genai-index/contentBucket/AutoDeleteObjectsCustomResource/Default", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnResource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.CustomResource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.Bucket", + "version": "2.173.2" + } + }, + "genai-index": { + "id": "genai-index", + "path": "lamken-genai-index/genai-index", + "children": { + "LambdaFunctionServiceRole": { + "id": "LambdaFunctionServiceRole", + "path": "lamken-genai-index/genai-index/LambdaFunctionServiceRole", + "children": { + "ImportLambdaFunctionServiceRole": { + "id": "ImportLambdaFunctionServiceRole", + "path": "lamken-genai-index/genai-index/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.173.2" + } + }, + "Resource": { + "id": "Resource", + "path": "lamken-genai-index/genai-index/LambdaFunctionServiceRole/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:props": { + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "lambda.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "policies": [ + { + "policyName": "LambdaFunctionServiceRolePolicy", + "policyDocument": { + "Statement": [ + { + "Action": [ + "logs:CreateLogGroup", + "logs:CreateLogStream", + "logs:PutLogEvents" + ], + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/lambda/*" + ] + ] + } + } + ], + "Version": "2012-10-17" + } + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "2.173.2" + } + }, + "DefaultPolicy": { + "id": "DefaultPolicy", + "path": "lamken-genai-index/genai-index/LambdaFunctionServiceRole/DefaultPolicy", + "children": { + "Resource": { + "id": "Resource", + "path": "lamken-genai-index/genai-index/LambdaFunctionServiceRole/DefaultPolicy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Policy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "xray:PutTelemetryRecords", + "xray:PutTraceSegments" + ], + "Effect": "Allow", + "Resource": "*" + }, + { + "Action": [ + "kendra:BatchGet*", + "kendra:Describe*", + "kendra:Get*", + "kendra:List*", + "kendra:Query", + "kendra:Retrieve", + "kendra:SubmitFeedback" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "genaiindexkendraindexgenaiindex5FFB72B4", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "policyName": "genaiindexLambdaFunctionServiceRoleDefaultPolicy18386D50", + "roles": [ + { + "Ref": "genaiindexLambdaFunctionServiceRoleE929EAD8" + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Policy", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "2.173.2" + } + }, + "LambdaFunction": { + "id": "LambdaFunction", + "path": "lamken-genai-index/genai-index/LambdaFunction", + "children": { + "Code": { + "id": "Code", + "path": "lamken-genai-index/genai-index/LambdaFunction/Code", + "children": { + "Stage": { + "id": "Stage", + "path": "lamken-genai-index/genai-index/LambdaFunction/Code/Stage", + "constructInfo": { + "fqn": "aws-cdk-lib.AssetStaging", + "version": "2.173.2" + } + }, + "AssetBucket": { + "id": "AssetBucket", + "path": "lamken-genai-index/genai-index/LambdaFunction/Code/AssetBucket", + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.BucketBase", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3_assets.Asset", + "version": "2.173.2" + } + }, + "Resource": { + "id": "Resource", + "path": "lamken-genai-index/genai-index/LambdaFunction/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Lambda::Function", + "aws:cdk:cloudformation:props": { + "code": { + "s3Bucket": { + "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" + }, + "s3Key": "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f.zip" + }, + "environment": { + "variables": { + "AWS_NODEJS_CONNECTION_REUSE_ENABLED": "1", + "KENDRA_INDEX_ID": { + "Fn::GetAtt": [ + "genaiindexkendraindexgenaiindex5FFB72B4", + "Id" + ] + } + } + }, + "handler": "index.handler", + "role": { + "Fn::GetAtt": [ + "genaiindexLambdaFunctionServiceRoleE929EAD8", + "Arn" + ] + }, + "runtime": "nodejs20.x", + "tracingConfig": { + "mode": "Active" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.Function", + "version": "2.173.2" + } + }, + "kendra-index-role-genai-index": { + "id": "kendra-index-role-genai-index", + "path": "lamken-genai-index/genai-index/kendra-index-role-genai-index", + "children": { + "Importkendra-index-role-genai-index": { + "id": "Importkendra-index-role-genai-index", + "path": "lamken-genai-index/genai-index/kendra-index-role-genai-index/Importkendra-index-role-genai-index", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.173.2" + } + }, + "Resource": { + "id": "Resource", + "path": "lamken-genai-index/genai-index/kendra-index-role-genai-index/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:props": { + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "kendra.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "description": "Allow Kendra index to write CloudWatch Logs", + "policies": [ + { + "policyName": "AllowLogging", + "policyDocument": { + "Statement": [ + { + "Action": "cloudwatch:PutMetricData", + "Condition": { + "StringEquals": { + "cloudwatch:namespace": "AWS/Kendra" + } + }, + "Effect": "Allow", + "Resource": "*" + }, + { + "Action": "logs:CreateLogGroup", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/kendra/*" + ] + ] + } + }, + { + "Action": "logs:DescribeLogGroups", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/kendra/*" + ] + ] + } + }, + { + "Action": [ + "logs:CreateLogStream", + "logs:DescribeLogStream", + "logs:PutLogEvents" + ], + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/kendra/*:log-stream:*" + ] + ] + } + } + ], + "Version": "2012-10-17" + } + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "2.173.2" + } + }, + "kendra-index-genai-index": { + "id": "kendra-index-genai-index", + "path": "lamken-genai-index/genai-index/kendra-index-genai-index", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Kendra::Index", + "aws:cdk:cloudformation:props": { + "edition": "GEN_AI_ENTERPRISE_EDITION", + "name": "genai-index", + "roleArn": { + "Fn::GetAtt": [ + "genaiindexkendraindexrolegenaiindex2848B249", + "Arn" + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kendra.CfnIndex", + "version": "2.173.2" + } + }, + "data-source-role-genai-index0": { + "id": "data-source-role-genai-index0", + "path": "lamken-genai-index/genai-index/data-source-role-genai-index0", + "children": { + "Importdata-source-role-genai-index0": { + "id": "Importdata-source-role-genai-index0", + "path": "lamken-genai-index/genai-index/data-source-role-genai-index0/Importdata-source-role-genai-index0", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.173.2" + } + }, + "Resource": { + "id": "Resource", + "path": "lamken-genai-index/genai-index/data-source-role-genai-index0/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:props": { + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "kendra.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "description": "Policy for Kendra S3 Data Source", + "policies": [ + { + "policyName": "s3CrawlPolicy", + "policyDocument": { + "Statement": [ + { + "Action": "s3:GetObject", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:s3:::", + { + "Ref": "contentBucket356CF7A5" + }, + "/*" + ] + ] + } + }, + { + "Action": "s3:ListBucket", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:s3:::", + { + "Ref": "contentBucket356CF7A5" + } + ] + ] + } + }, + { + "Action": [ + "kendra:BatchDeleteDocument", + "kendra:BatchPutDocument" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "genaiindexkendraindexgenaiindex5FFB72B4", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + } + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "2.173.2" + } + }, + "data-source-genai-index0": { + "id": "data-source-genai-index0", + "path": "lamken-genai-index/genai-index/data-source-genai-index0", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Kendra::DataSource", + "aws:cdk:cloudformation:props": { + "dataSourceConfiguration": { + "s3Configuration": { + "bucketName": { + "Ref": "contentBucket356CF7A5" + } + } + }, + "indexId": { + "Ref": "genaiindexkendraindexgenaiindex5FFB72B4" + }, + "name": { + "Fn::Join": [ + "", + [ + "s3-datasourcegenai-index0-", + { + "Fn::Select": [ + 2, + { + "Fn::Split": [ + "/", + { + "Ref": "AWS::StackId" + } + ] + } + ] + } + ] + ] + }, + "roleArn": { + "Fn::GetAtt": [ + "genaiindexdatasourcerolegenaiindex0F97D641C", + "Arn" + ] + }, + "type": "S3" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kendra.CfnDataSource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "@aws-solutions-constructs/aws-lambda-kendra.LambdaToKendra", + "version": "2.76.0" + } + }, + "Integ": { + "id": "Integ", + "path": "lamken-genai-index/Integ", + "children": { + "DefaultTest": { + "id": "DefaultTest", + "path": "lamken-genai-index/Integ/DefaultTest", + "children": { + "Default": { + "id": "Default", + "path": "lamken-genai-index/Integ/DefaultTest/Default", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.4.2" + } + }, + "DeployAssert": { + "id": "DeployAssert", + "path": "lamken-genai-index/Integ/DefaultTest/DeployAssert", + "children": { + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "lamken-genai-index/Integ/DefaultTest/DeployAssert/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "2.173.2" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "lamken-genai-index/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", + "version": "2.173.2-alpha.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", + "version": "2.173.2-alpha.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "lamken-genai-index/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "2.173.2" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "lamken-genai-index/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "2.173.2" + } + }, + "Tree": { + "id": "Tree", + "path": "Tree", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.4.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.App", + "version": "2.173.2" + } + } +} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.ts b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.ts new file mode 100644 index 000000000..f09dfadfb --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-genai-index.ts @@ -0,0 +1,54 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +// Imports +import { App, Stack } from "aws-cdk-lib"; +import { LambdaToKendra } from "../lib"; +import * as lambda from 'aws-cdk-lib/aws-lambda'; +import * as defaults from '@aws-solutions-constructs/core'; +import { generateIntegStackName, suppressCustomHandlerCfnNagWarnings } from '@aws-solutions-constructs/core'; +import { IntegTest } from '@aws-cdk/integ-tests-alpha'; + +// Setup +const app = new App(); +const stack = new Stack(app, generateIntegStackName(__filename)); +stack.templateOptions.description = 'Integration Test for aws-lambda-kendra'; +stack.node.setContext("@aws-cdk/aws-s3:serverAccessLogsUseBucketPolicy", true); + +const testBucket = defaults.CreateScrapBucket(stack, "contentBucket"); + +new LambdaToKendra(stack, 'genai-index', { + lambdaFunctionProps: { + code: lambda.Code.fromAsset(`lambda`), + runtime: defaults.COMMERCIAL_REGION_LAMBDA_NODE_RUNTIME, + handler: 'index.handler', + }, + kendraDataSourcesProps: [{ + type: 'S3', + dataSourceConfiguration: { + s3Configuration: { + bucketName: testBucket.bucketName, + } + } + }], + kendraIndexProps: { + edition: 'GEN_AI_ENTERPRISE_EDITION', + name: `genai-index` + }, +}); + +suppressCustomHandlerCfnNagWarnings(stack, 'Custom::S3AutoDeleteObjectsCustomResourceProvider'); +// Synth +new IntegTest(stack, 'Integ', { testCases: [ + stack +] }); diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f/index.js new file mode 100644 index 000000000..297328cfd --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f/index.js @@ -0,0 +1,21 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +exports.handler = async function(event) { + console.log('request:', JSON.stringify(event, undefined, 2)); + return { + statusCode: 200, + headers: { 'Content-Type': 'text/plain' }, + body: `Stub Lambda function for testing - ${event.path}\n` + }; + }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/asset.e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/asset.e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b/index.js deleted file mode 100644 index 3c81710ce..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/asset.e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b/index.js +++ /dev/null @@ -1,8 +0,0 @@ -exports.handler = async function(event) { - console.log('request:', JSON.stringify(event, undefined, 2)); - return { - statusCode: 200, - headers: { 'Content-Type': 'text/plain' }, - body: `Stub Lambda function for testing - ${event.path}\n` - }; - }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/cdk.out index 1f0068d32..c6e612584 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"38.0.1"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/integ.json index a86acdfdb..0db432599 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "38.0.1", "testCases": { "lamken-multiple-sources/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamken-multiple-sources.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamken-multiple-sources.assets.json index 3a1146804..d4fd1f873 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamken-multiple-sources.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamken-multiple-sources.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "38.0.1", "files": { "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6": { "source": { @@ -14,20 +14,20 @@ } } }, - "e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b": { + "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f": { "source": { - "path": "asset.e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b", + "path": "asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b.zip", + "objectKey": "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "6e969eb2789b1c1570ad8fc05ac7fcedbed9626fc6fbf847f956bad2d9fcf90c": { + "e4b3ddf4d570fc26869f0a279914f40550ca2813315b4961ca12c20cf83fbe02": { "source": { "path": "lamken-multiple-sources.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "6e969eb2789b1c1570ad8fc05ac7fcedbed9626fc6fbf847f956bad2d9fcf90c.json", + "objectKey": "e4b3ddf4d570fc26869f0a279914f40550ca2813315b4961ca12c20cf83fbe02.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamken-multiple-sources.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamken-multiple-sources.template.json index eb5eb958a..7d722cd02 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamken-multiple-sources.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamken-multiple-sources.template.json @@ -396,6 +396,317 @@ "UpdateReplacePolicy": "Delete", "DeletionPolicy": "Delete" }, + "secondScrapBucketLog8EF53038": { + "Type": "AWS::S3::Bucket", + "Properties": { + "BucketEncryption": { + "ServerSideEncryptionConfiguration": [ + { + "ServerSideEncryptionByDefault": { + "SSEAlgorithm": "AES256" + } + } + ] + }, + "Tags": [ + { + "Key": "aws-cdk:auto-delete-objects", + "Value": "true" + } + ], + "VersioningConfiguration": { + "Status": "Enabled" + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete", + "Metadata": { + "cfn_nag": { + "rules_to_suppress": [ + { + "id": "W35", + "reason": "This is a log bucket" + } + ] + } + } + }, + "secondScrapBucketLogPolicyE1D83D18": { + "Type": "AWS::S3::BucketPolicy", + "Properties": { + "Bucket": { + "Ref": "secondScrapBucketLog8EF53038" + }, + "PolicyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:List*", + "s3:PutBucketPolicy" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092", + "Arn" + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": "s3:PutObject", + "Condition": { + "ArnLike": { + "aws:SourceArn": { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + } + }, + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "logging.s3.amazonaws.com" + }, + "Resource": { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + "/*" + ] + ] + } + } + ], + "Version": "2012-10-17" + } + } + }, + "secondScrapBucketLogAutoDeleteObjectsCustomResource10C10B13": { + "Type": "Custom::S3AutoDeleteObjects", + "Properties": { + "ServiceToken": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderHandler9D90184F", + "Arn" + ] + }, + "BucketName": { + "Ref": "secondScrapBucketLog8EF53038" + } + }, + "DependsOn": [ + "secondScrapBucketLogPolicyE1D83D18" + ], + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "secondScrapBucketFC127414": { + "Type": "AWS::S3::Bucket", + "Properties": { + "BucketEncryption": { + "ServerSideEncryptionConfiguration": [ + { + "ServerSideEncryptionByDefault": { + "SSEAlgorithm": "AES256" + } + } + ] + }, + "LoggingConfiguration": { + "DestinationBucketName": { + "Ref": "secondScrapBucketLog8EF53038" + } + }, + "Tags": [ + { + "Key": "aws-cdk:auto-delete-objects", + "Value": "true" + } + ], + "VersioningConfiguration": { + "Status": "Enabled" + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "secondScrapBucketPolicy8F815CB9": { + "Type": "AWS::S3::BucketPolicy", + "Properties": { + "Bucket": { + "Ref": "secondScrapBucketFC127414" + }, + "PolicyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:List*", + "s3:PutBucketPolicy" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092", + "Arn" + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + } + ], + "Version": "2012-10-17" + } + } + }, + "secondScrapBucketAutoDeleteObjectsCustomResourceC87751E9": { + "Type": "Custom::S3AutoDeleteObjects", + "Properties": { + "ServiceToken": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderHandler9D90184F", + "Arn" + ] + }, + "BucketName": { + "Ref": "secondScrapBucketFC127414" + } + }, + "DependsOn": [ + "secondScrapBucketPolicy8F815CB9" + ], + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, "existingRole3E995BBA": { "Type": "AWS::IAM::Role", "Properties": { @@ -413,7 +724,7 @@ } } }, - "minimalargumentsLambdaFunctionServiceRole73B77FF7": { + "multiplesourcesLambdaFunctionServiceRole66EC8973": { "Type": "AWS::IAM::Role", "Properties": { "AssumeRolePolicyDocument": { @@ -475,7 +786,7 @@ } } }, - "minimalargumentsLambdaFunctionServiceRoleDefaultPolicy59EC60ED": { + "multiplesourcesLambdaFunctionServiceRoleDefaultPolicyF82ADA6A": { "Type": "AWS::IAM::Policy", "Properties": { "PolicyDocument": { @@ -501,7 +812,7 @@ "Effect": "Allow", "Resource": { "Fn::GetAtt": [ - "minimalargumentskendraindexminimalarguments5CBDD236", + "multiplesourceskendraindexmultiplesourcesD8FB1621", "Arn" ] } @@ -509,10 +820,10 @@ ], "Version": "2012-10-17" }, - "PolicyName": "minimalargumentsLambdaFunctionServiceRoleDefaultPolicy59EC60ED", + "PolicyName": "multiplesourcesLambdaFunctionServiceRoleDefaultPolicyF82ADA6A", "Roles": [ { - "Ref": "minimalargumentsLambdaFunctionServiceRole73B77FF7" + "Ref": "multiplesourcesLambdaFunctionServiceRole66EC8973" } ] }, @@ -527,21 +838,21 @@ } } }, - "minimalargumentsLambdaFunctionC19CFAAC": { + "multiplesourcesLambdaFunction9BDB2DBA": { "Type": "AWS::Lambda::Function", "Properties": { "Code": { "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b.zip" + "S3Key": "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f.zip" }, "Environment": { "Variables": { "AWS_NODEJS_CONNECTION_REUSE_ENABLED": "1", "KENDRA_INDEX_ID": { "Fn::GetAtt": [ - "minimalargumentskendraindexminimalarguments5CBDD236", + "multiplesourceskendraindexmultiplesourcesD8FB1621", "Id" ] } @@ -550,7 +861,7 @@ "Handler": "index.handler", "Role": { "Fn::GetAtt": [ - "minimalargumentsLambdaFunctionServiceRole73B77FF7", + "multiplesourcesLambdaFunctionServiceRole66EC8973", "Arn" ] }, @@ -560,8 +871,8 @@ } }, "DependsOn": [ - "minimalargumentsLambdaFunctionServiceRoleDefaultPolicy59EC60ED", - "minimalargumentsLambdaFunctionServiceRole73B77FF7" + "multiplesourcesLambdaFunctionServiceRoleDefaultPolicyF82ADA6A", + "multiplesourcesLambdaFunctionServiceRole66EC8973" ], "Metadata": { "cfn_nag": { @@ -582,7 +893,7 @@ } } }, - "minimalargumentskendraindexroleminimalargumentsB1DBDF7D": { + "multiplesourceskendraindexrolemultiplesourcesAB2C8779": { "Type": "AWS::IAM::Role", "Properties": { "AssumeRolePolicyDocument": { @@ -707,7 +1018,7 @@ } } }, - "minimalargumentskendraindexminimalarguments5CBDD236": { + "multiplesourceskendraindexmultiplesourcesD8FB1621": { "Type": "AWS::Kendra::Index", "Properties": { "Edition": "DEVELOPER_EDITION", @@ -715,7 +1026,7 @@ "Fn::Join": [ "", [ - "KendraIndexminimal-arguments-", + "KendraIndexmultiple-sources-", { "Fn::Select": [ 2, @@ -734,7 +1045,7 @@ }, "RoleArn": { "Fn::GetAtt": [ - "minimalargumentskendraindexroleminimalargumentsB1DBDF7D", + "multiplesourceskendraindexrolemultiplesourcesAB2C8779", "Arn" ] } @@ -750,7 +1061,7 @@ } } }, - "minimalargumentsdatasourceroleminimalarguments00EAC5006": { + "multiplesourcesdatasourcerolemultiplesources01396504E": { "Type": "AWS::IAM::Role", "Properties": { "AssumeRolePolicyDocument": { @@ -809,7 +1120,7 @@ "Effect": "Allow", "Resource": { "Fn::GetAtt": [ - "minimalargumentskendraindexminimalarguments5CBDD236", + "multiplesourceskendraindexmultiplesourcesD8FB1621", "Arn" ] } @@ -829,7 +1140,7 @@ } } }, - "minimalargumentsdatasourceminimalarguments05A02FF3B": { + "multiplesourcesdatasourcemultiplesources0EC508371": { "Type": "AWS::Kendra::DataSource", "Properties": { "DataSourceConfiguration": { @@ -840,13 +1151,135 @@ } }, "IndexId": { - "Ref": "minimalargumentskendraindexminimalarguments5CBDD236" + "Ref": "multiplesourceskendraindexmultiplesourcesD8FB1621" + }, + "Name": { + "Fn::Join": [ + "", + [ + "s3-datasourcemultiple-sources0-", + { + "Fn::Select": [ + 2, + { + "Fn::Split": [ + "/", + { + "Ref": "AWS::StackId" + } + ] + } + ] + } + ] + ] + }, + "RoleArn": { + "Fn::GetAtt": [ + "multiplesourcesdatasourcerolemultiplesources01396504E", + "Arn" + ] + }, + "Type": "S3" + } + }, + "multiplesourcesdatasourcerolemultiplesources16A50E028": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "kendra.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "Description": "Policy for Kendra S3 Data Source", + "Policies": [ + { + "PolicyDocument": { + "Statement": [ + { + "Action": "s3:GetObject", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:s3:::", + { + "Ref": "secondScrapBucketFC127414" + }, + "/*" + ] + ] + } + }, + { + "Action": "s3:ListBucket", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:s3:::", + { + "Ref": "secondScrapBucketFC127414" + } + ] + ] + } + }, + { + "Action": [ + "kendra:BatchDeleteDocument", + "kendra:BatchPutDocument" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "multiplesourceskendraindexmultiplesourcesD8FB1621", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "s3CrawlPolicy" + } + ] + }, + "Metadata": { + "guard": { + "SuppressedRules": [ + "IAM_NO_INLINE_POLICY_CHECK" + ] + } + } + }, + "multiplesourcesdatasourcemultiplesources1996FC378": { + "Type": "AWS::Kendra::DataSource", + "Properties": { + "DataSourceConfiguration": { + "S3Configuration": { + "BucketName": { + "Ref": "secondScrapBucketFC127414" + } + } + }, + "IndexId": { + "Ref": "multiplesourceskendraindexmultiplesourcesD8FB1621" }, "Name": { "Fn::Join": [ "", [ - "s3-datasourceminimal-arguments0-", + "s3-datasourcemultiple-sources1-", { "Fn::Select": [ 2, @@ -865,14 +1298,14 @@ }, "RoleArn": { "Fn::GetAtt": [ - "minimalargumentsdatasourceroleminimalarguments00EAC5006", + "multiplesourcesdatasourcerolemultiplesources16A50E028", "Arn" ] }, "Type": "S3" } }, - "minimalargumentskendradatasourceminimalarguments1DA6FACEE": { + "multiplesourceskendradatasourcemultiplesources220F30209": { "Type": "AWS::Kendra::DataSource", "Properties": { "DataSourceConfiguration": { @@ -889,7 +1322,7 @@ }, "IndexId": { "Fn::GetAtt": [ - "minimalargumentskendraindexminimalarguments5CBDD236", + "multiplesourceskendraindexmultiplesourcesD8FB1621", "Id" ] }, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamkenmultiplesourcesIntegDefaultTestDeployAssertDE50B828.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamkenmultiplesourcesIntegDefaultTestDeployAssertDE50B828.assets.json index 44b2f4a01..b6f4e2b23 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamkenmultiplesourcesIntegDefaultTestDeployAssertDE50B828.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/lamkenmultiplesourcesIntegDefaultTestDeployAssertDE50B828.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "38.0.1", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/manifest.json index 696f52cab..3d6833103 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "38.0.1", "artifacts": { "lamkenmultiplesourcesIntegDefaultTestDeployAssertDE50B828.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/6e969eb2789b1c1570ad8fc05ac7fcedbed9626fc6fbf847f956bad2d9fcf90c.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/e4b3ddf4d570fc26869f0a279914f40550ca2813315b4961ca12c20cf83fbe02.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -106,6 +106,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamken-multiple-sources/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamken-multiple-sources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -136,58 +142,106 @@ "data": "scrapBucketAutoDeleteObjectsCustomResourceFFFC3275" } ], + "/lamken-multiple-sources/secondScrapBucketLog/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "secondScrapBucketLog8EF53038" + } + ], + "/lamken-multiple-sources/secondScrapBucketLog/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "secondScrapBucketLogPolicyE1D83D18" + } + ], + "/lamken-multiple-sources/secondScrapBucketLog/AutoDeleteObjectsCustomResource/Default": [ + { + "type": "aws:cdk:logicalId", + "data": "secondScrapBucketLogAutoDeleteObjectsCustomResource10C10B13" + } + ], + "/lamken-multiple-sources/secondScrapBucket/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "secondScrapBucketFC127414" + } + ], + "/lamken-multiple-sources/secondScrapBucket/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "secondScrapBucketPolicy8F815CB9" + } + ], + "/lamken-multiple-sources/secondScrapBucket/AutoDeleteObjectsCustomResource/Default": [ + { + "type": "aws:cdk:logicalId", + "data": "secondScrapBucketAutoDeleteObjectsCustomResourceC87751E9" + } + ], "/lamken-multiple-sources/existingRole/Resource": [ { "type": "aws:cdk:logicalId", "data": "existingRole3E995BBA" } ], - "/lamken-multiple-sources/minimal-arguments/LambdaFunctionServiceRole/Resource": [ + "/lamken-multiple-sources/multiple-sources/LambdaFunctionServiceRole/Resource": [ { "type": "aws:cdk:logicalId", - "data": "minimalargumentsLambdaFunctionServiceRole73B77FF7" + "data": "multiplesourcesLambdaFunctionServiceRole66EC8973" } ], - "/lamken-multiple-sources/minimal-arguments/LambdaFunctionServiceRole/DefaultPolicy/Resource": [ + "/lamken-multiple-sources/multiple-sources/LambdaFunctionServiceRole/DefaultPolicy/Resource": [ { "type": "aws:cdk:logicalId", - "data": "minimalargumentsLambdaFunctionServiceRoleDefaultPolicy59EC60ED" + "data": "multiplesourcesLambdaFunctionServiceRoleDefaultPolicyF82ADA6A" } ], - "/lamken-multiple-sources/minimal-arguments/LambdaFunction/Resource": [ + "/lamken-multiple-sources/multiple-sources/LambdaFunction/Resource": [ { "type": "aws:cdk:logicalId", - "data": "minimalargumentsLambdaFunctionC19CFAAC" + "data": "multiplesourcesLambdaFunction9BDB2DBA" } ], - "/lamken-multiple-sources/minimal-arguments/kendra-index-role-minimal-arguments/Resource": [ + "/lamken-multiple-sources/multiple-sources/kendra-index-role-multiple-sources/Resource": [ { "type": "aws:cdk:logicalId", - "data": "minimalargumentskendraindexroleminimalargumentsB1DBDF7D" + "data": "multiplesourceskendraindexrolemultiplesourcesAB2C8779" } ], - "/lamken-multiple-sources/minimal-arguments/kendra-index-minimal-arguments": [ + "/lamken-multiple-sources/multiple-sources/kendra-index-multiple-sources": [ { "type": "aws:cdk:logicalId", - "data": "minimalargumentskendraindexminimalarguments5CBDD236" + "data": "multiplesourceskendraindexmultiplesourcesD8FB1621" } ], - "/lamken-multiple-sources/minimal-arguments/data-source-role-minimal-arguments0/Resource": [ + "/lamken-multiple-sources/multiple-sources/data-source-role-multiple-sources0/Resource": [ { "type": "aws:cdk:logicalId", - "data": "minimalargumentsdatasourceroleminimalarguments00EAC5006" + "data": "multiplesourcesdatasourcerolemultiplesources01396504E" } ], - "/lamken-multiple-sources/minimal-arguments/data-source-minimal-arguments0": [ + "/lamken-multiple-sources/multiple-sources/data-source-multiple-sources0": [ { "type": "aws:cdk:logicalId", - "data": "minimalargumentsdatasourceminimalarguments05A02FF3B" + "data": "multiplesourcesdatasourcemultiplesources0EC508371" } ], - "/lamken-multiple-sources/minimal-arguments/kendra-data-source-minimal-arguments1": [ + "/lamken-multiple-sources/multiple-sources/data-source-role-multiple-sources1/Resource": [ { "type": "aws:cdk:logicalId", - "data": "minimalargumentskendradatasourceminimalarguments1DA6FACEE" + "data": "multiplesourcesdatasourcerolemultiplesources16A50E028" + } + ], + "/lamken-multiple-sources/multiple-sources/data-source-multiple-sources1": [ + { + "type": "aws:cdk:logicalId", + "data": "multiplesourcesdatasourcemultiplesources1996FC378" + } + ], + "/lamken-multiple-sources/multiple-sources/kendra-data-source-multiple-sources2": [ + { + "type": "aws:cdk:logicalId", + "data": "multiplesourceskendradatasourcemultiplesources220F30209" } ], "/lamken-multiple-sources/BootstrapVersion": [ @@ -201,6 +255,96 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } + ], + "minimalargumentsLambdaFunctionServiceRole73B77FF7": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentsLambdaFunctionServiceRole73B77FF7", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } + ], + "minimalargumentsLambdaFunctionServiceRoleDefaultPolicy59EC60ED": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentsLambdaFunctionServiceRoleDefaultPolicy59EC60ED", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } + ], + "minimalargumentsLambdaFunctionC19CFAAC": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentsLambdaFunctionC19CFAAC", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } + ], + "minimalargumentskendraindexroleminimalargumentsB1DBDF7D": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentskendraindexroleminimalargumentsB1DBDF7D", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } + ], + "minimalargumentskendraindexminimalarguments5CBDD236": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentskendraindexminimalarguments5CBDD236", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } + ], + "minimalargumentsdatasourceroleminimalarguments00EAC5006": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentsdatasourceroleminimalarguments00EAC5006", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } + ], + "minimalargumentsdatasourceminimalarguments05A02FF3B": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentsdatasourceminimalarguments05A02FF3B", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } + ], + "minimalargumentsdatasourceroleminimalarguments170BEA8FA": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentsdatasourceroleminimalarguments170BEA8FA", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } + ], + "minimalargumentsdatasourceminimalarguments12CE59405": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentsdatasourceminimalarguments12CE59405", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } + ], + "minimalargumentskendradatasourceminimalarguments23C422502": [ + { + "type": "aws:cdk:logicalId", + "data": "minimalargumentskendradatasourceminimalarguments23C422502", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } ] }, "displayName": "lamken-multiple-sources" diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/tree.json index 9d9a9ade2..64a4651ad 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.js.snapshot/tree.json @@ -40,7 +40,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.173.2" } }, "Policy": { @@ -174,13 +174,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.173.2" } }, "AutoDeleteObjectsCustomResource": { @@ -192,19 +192,19 @@ "path": "lamken-multiple-sources/scrapBucketLog/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.173.2" } }, "LatestNodeRuntimeMap": { @@ -212,7 +212,7 @@ "path": "lamken-multiple-sources/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.173.2" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -224,7 +224,7 @@ "path": "lamken-multiple-sources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.173.2" } }, "Role": { @@ -232,7 +232,7 @@ "path": "lamken-multiple-sources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.173.2" } }, "Handler": { @@ -240,13 +240,13 @@ "path": "lamken-multiple-sources/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.173.2" } }, "scrapBucket": { @@ -286,7 +286,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.173.2" } }, "Policy": { @@ -384,13 +384,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.173.2" } }, "AutoDeleteObjectsCustomResource": { @@ -402,19 +402,386 @@ "path": "lamken-multiple-sources/scrapBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.173.2" + } + }, + "secondScrapBucketLog": { + "id": "secondScrapBucketLog", + "path": "lamken-multiple-sources/secondScrapBucketLog", + "children": { + "Resource": { + "id": "Resource", + "path": "lamken-multiple-sources/secondScrapBucketLog/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::Bucket", + "aws:cdk:cloudformation:props": { + "bucketEncryption": { + "serverSideEncryptionConfiguration": [ + { + "serverSideEncryptionByDefault": { + "sseAlgorithm": "AES256" + } + } + ] + }, + "tags": [ + { + "key": "aws-cdk:auto-delete-objects", + "value": "true" + } + ], + "versioningConfiguration": { + "status": "Enabled" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.CfnBucket", + "version": "2.173.2" + } + }, + "Policy": { + "id": "Policy", + "path": "lamken-multiple-sources/secondScrapBucketLog/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "lamken-multiple-sources/secondScrapBucketLog/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::BucketPolicy", + "aws:cdk:cloudformation:props": { + "bucket": { + "Ref": "secondScrapBucketLog8EF53038" + }, + "policyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:List*", + "s3:PutBucketPolicy" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092", + "Arn" + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": "s3:PutObject", + "Condition": { + "ArnLike": { + "aws:SourceArn": { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + } + }, + "StringEquals": { + "aws:SourceAccount": { + "Ref": "AWS::AccountId" + } + } + }, + "Effect": "Allow", + "Principal": { + "Service": "logging.s3.amazonaws.com" + }, + "Resource": { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketLog8EF53038", + "Arn" + ] + }, + "/*" + ] + ] + } + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", + "version": "2.173.2" + } + }, + "AutoDeleteObjectsCustomResource": { + "id": "AutoDeleteObjectsCustomResource", + "path": "lamken-multiple-sources/secondScrapBucketLog/AutoDeleteObjectsCustomResource", + "children": { + "Default": { + "id": "Default", + "path": "lamken-multiple-sources/secondScrapBucketLog/AutoDeleteObjectsCustomResource/Default", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnResource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.CustomResource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.Bucket", + "version": "2.173.2" + } + }, + "secondScrapBucket": { + "id": "secondScrapBucket", + "path": "lamken-multiple-sources/secondScrapBucket", + "children": { + "Resource": { + "id": "Resource", + "path": "lamken-multiple-sources/secondScrapBucket/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::Bucket", + "aws:cdk:cloudformation:props": { + "bucketEncryption": { + "serverSideEncryptionConfiguration": [ + { + "serverSideEncryptionByDefault": { + "sseAlgorithm": "AES256" + } + } + ] + }, + "loggingConfiguration": { + "destinationBucketName": { + "Ref": "secondScrapBucketLog8EF53038" + } + }, + "tags": [ + { + "key": "aws-cdk:auto-delete-objects", + "value": "true" + } + ], + "versioningConfiguration": { + "status": "Enabled" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.CfnBucket", + "version": "2.173.2" + } + }, + "Policy": { + "id": "Policy", + "path": "lamken-multiple-sources/secondScrapBucket/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "lamken-multiple-sources/secondScrapBucket/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::BucketPolicy", + "aws:cdk:cloudformation:props": { + "bucket": { + "Ref": "secondScrapBucketFC127414" + }, + "policyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:List*", + "s3:PutBucketPolicy" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::GetAtt": [ + "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092", + "Arn" + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "secondScrapBucketFC127414", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", + "version": "2.173.2" + } + }, + "AutoDeleteObjectsCustomResource": { + "id": "AutoDeleteObjectsCustomResource", + "path": "lamken-multiple-sources/secondScrapBucket/AutoDeleteObjectsCustomResource", + "children": { + "Default": { + "id": "Default", + "path": "lamken-multiple-sources/secondScrapBucket/AutoDeleteObjectsCustomResource/Default", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnResource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.CustomResource", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.Bucket", + "version": "2.173.2" } }, "existingRole": { @@ -426,7 +793,7 @@ "path": "lamken-multiple-sources/existingRole/ImportexistingRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.173.2" } }, "Resource": { @@ -451,34 +818,34 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.173.2" } }, - "minimal-arguments": { - "id": "minimal-arguments", - "path": "lamken-multiple-sources/minimal-arguments", + "multiple-sources": { + "id": "multiple-sources", + "path": "lamken-multiple-sources/multiple-sources", "children": { "LambdaFunctionServiceRole": { "id": "LambdaFunctionServiceRole", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunctionServiceRole", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunctionServiceRole", "children": { "ImportLambdaFunctionServiceRole": { "id": "ImportLambdaFunctionServiceRole", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.173.2" } }, "Resource": { "id": "Resource", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunctionServiceRole/Resource", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunctionServiceRole/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::IAM::Role", "aws:cdk:cloudformation:props": { @@ -536,16 +903,16 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.173.2" } }, "DefaultPolicy": { "id": "DefaultPolicy", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunctionServiceRole/DefaultPolicy", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunctionServiceRole/DefaultPolicy", "children": { "Resource": { "id": "Resource", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunctionServiceRole/DefaultPolicy/Resource", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunctionServiceRole/DefaultPolicy/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::IAM::Policy", "aws:cdk:cloudformation:props": { @@ -572,7 +939,7 @@ "Effect": "Allow", "Resource": { "Fn::GetAtt": [ - "minimalargumentskendraindexminimalarguments5CBDD236", + "multiplesourceskendraindexmultiplesourcesD8FB1621", "Arn" ] } @@ -580,64 +947,64 @@ ], "Version": "2012-10-17" }, - "policyName": "minimalargumentsLambdaFunctionServiceRoleDefaultPolicy59EC60ED", + "policyName": "multiplesourcesLambdaFunctionServiceRoleDefaultPolicyF82ADA6A", "roles": [ { - "Ref": "minimalargumentsLambdaFunctionServiceRole73B77FF7" + "Ref": "multiplesourcesLambdaFunctionServiceRole66EC8973" } ] } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.173.2" } }, "LambdaFunction": { "id": "LambdaFunction", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunction", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunction", "children": { "Code": { "id": "Code", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunction/Code", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunction/Code", "children": { "Stage": { "id": "Stage", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunction/Code/Stage", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.173.2" } }, "AssetBucket": { "id": "AssetBucket", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunction/Code/AssetBucket", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.173.2" } }, "Resource": { "id": "Resource", - "path": "lamken-multiple-sources/minimal-arguments/LambdaFunction/Resource", + "path": "lamken-multiple-sources/multiple-sources/LambdaFunction/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::Lambda::Function", "aws:cdk:cloudformation:props": { @@ -645,14 +1012,14 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b.zip" + "s3Key": "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f.zip" }, "environment": { "variables": { "AWS_NODEJS_CONNECTION_REUSE_ENABLED": "1", "KENDRA_INDEX_ID": { "Fn::GetAtt": [ - "minimalargumentskendraindexminimalarguments5CBDD236", + "multiplesourceskendraindexmultiplesourcesD8FB1621", "Id" ] } @@ -661,7 +1028,7 @@ "handler": "index.handler", "role": { "Fn::GetAtt": [ - "minimalargumentsLambdaFunctionServiceRole73B77FF7", + "multiplesourcesLambdaFunctionServiceRole66EC8973", "Arn" ] }, @@ -673,30 +1040,30 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.173.2" } }, - "kendra-index-role-minimal-arguments": { - "id": "kendra-index-role-minimal-arguments", - "path": "lamken-multiple-sources/minimal-arguments/kendra-index-role-minimal-arguments", + "kendra-index-role-multiple-sources": { + "id": "kendra-index-role-multiple-sources", + "path": "lamken-multiple-sources/multiple-sources/kendra-index-role-multiple-sources", "children": { - "Importkendra-index-role-minimal-arguments": { - "id": "Importkendra-index-role-minimal-arguments", - "path": "lamken-multiple-sources/minimal-arguments/kendra-index-role-minimal-arguments/Importkendra-index-role-minimal-arguments", + "Importkendra-index-role-multiple-sources": { + "id": "Importkendra-index-role-multiple-sources", + "path": "lamken-multiple-sources/multiple-sources/kendra-index-role-multiple-sources/Importkendra-index-role-multiple-sources", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.173.2" } }, "Resource": { "id": "Resource", - "path": "lamken-multiple-sources/minimal-arguments/kendra-index-role-minimal-arguments/Resource", + "path": "lamken-multiple-sources/multiple-sources/kendra-index-role-multiple-sources/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::IAM::Role", "aws:cdk:cloudformation:props": { @@ -809,18 +1176,18 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.173.2" } }, - "kendra-index-minimal-arguments": { - "id": "kendra-index-minimal-arguments", - "path": "lamken-multiple-sources/minimal-arguments/kendra-index-minimal-arguments", + "kendra-index-multiple-sources": { + "id": "kendra-index-multiple-sources", + "path": "lamken-multiple-sources/multiple-sources/kendra-index-multiple-sources", "attributes": { "aws:cdk:cloudformation:type": "AWS::Kendra::Index", "aws:cdk:cloudformation:props": { @@ -829,7 +1196,7 @@ "Fn::Join": [ "", [ - "KendraIndexminimal-arguments-", + "KendraIndexmultiple-sources-", { "Fn::Select": [ 2, @@ -848,7 +1215,7 @@ }, "roleArn": { "Fn::GetAtt": [ - "minimalargumentskendraindexroleminimalargumentsB1DBDF7D", + "multiplesourceskendraindexrolemultiplesourcesAB2C8779", "Arn" ] } @@ -856,24 +1223,24 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kendra.CfnIndex", - "version": "2.150.0" + "version": "2.173.2" } }, - "data-source-role-minimal-arguments0": { - "id": "data-source-role-minimal-arguments0", - "path": "lamken-multiple-sources/minimal-arguments/data-source-role-minimal-arguments0", + "data-source-role-multiple-sources0": { + "id": "data-source-role-multiple-sources0", + "path": "lamken-multiple-sources/multiple-sources/data-source-role-multiple-sources0", "children": { - "Importdata-source-role-minimal-arguments0": { - "id": "Importdata-source-role-minimal-arguments0", - "path": "lamken-multiple-sources/minimal-arguments/data-source-role-minimal-arguments0/Importdata-source-role-minimal-arguments0", + "Importdata-source-role-multiple-sources0": { + "id": "Importdata-source-role-multiple-sources0", + "path": "lamken-multiple-sources/multiple-sources/data-source-role-multiple-sources0/Importdata-source-role-multiple-sources0", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.173.2" } }, "Resource": { "id": "Resource", - "path": "lamken-multiple-sources/minimal-arguments/data-source-role-minimal-arguments0/Resource", + "path": "lamken-multiple-sources/multiple-sources/data-source-role-multiple-sources0/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::IAM::Role", "aws:cdk:cloudformation:props": { @@ -934,7 +1301,7 @@ "Effect": "Allow", "Resource": { "Fn::GetAtt": [ - "minimalargumentskendraindexminimalarguments5CBDD236", + "multiplesourceskendraindexmultiplesourcesD8FB1621", "Arn" ] } @@ -948,18 +1315,18 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.173.2" } }, - "data-source-minimal-arguments0": { - "id": "data-source-minimal-arguments0", - "path": "lamken-multiple-sources/minimal-arguments/data-source-minimal-arguments0", + "data-source-multiple-sources0": { + "id": "data-source-multiple-sources0", + "path": "lamken-multiple-sources/multiple-sources/data-source-multiple-sources0", "attributes": { "aws:cdk:cloudformation:type": "AWS::Kendra::DataSource", "aws:cdk:cloudformation:props": { @@ -971,13 +1338,162 @@ } }, "indexId": { - "Ref": "minimalargumentskendraindexminimalarguments5CBDD236" + "Ref": "multiplesourceskendraindexmultiplesourcesD8FB1621" + }, + "name": { + "Fn::Join": [ + "", + [ + "s3-datasourcemultiple-sources0-", + { + "Fn::Select": [ + 2, + { + "Fn::Split": [ + "/", + { + "Ref": "AWS::StackId" + } + ] + } + ] + } + ] + ] + }, + "roleArn": { + "Fn::GetAtt": [ + "multiplesourcesdatasourcerolemultiplesources01396504E", + "Arn" + ] + }, + "type": "S3" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_kendra.CfnDataSource", + "version": "2.173.2" + } + }, + "data-source-role-multiple-sources1": { + "id": "data-source-role-multiple-sources1", + "path": "lamken-multiple-sources/multiple-sources/data-source-role-multiple-sources1", + "children": { + "Importdata-source-role-multiple-sources1": { + "id": "Importdata-source-role-multiple-sources1", + "path": "lamken-multiple-sources/multiple-sources/data-source-role-multiple-sources1/Importdata-source-role-multiple-sources1", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.173.2" + } + }, + "Resource": { + "id": "Resource", + "path": "lamken-multiple-sources/multiple-sources/data-source-role-multiple-sources1/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:props": { + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "kendra.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "description": "Policy for Kendra S3 Data Source", + "policies": [ + { + "policyName": "s3CrawlPolicy", + "policyDocument": { + "Statement": [ + { + "Action": "s3:GetObject", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:s3:::", + { + "Ref": "secondScrapBucketFC127414" + }, + "/*" + ] + ] + } + }, + { + "Action": "s3:ListBucket", + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:aws:s3:::", + { + "Ref": "secondScrapBucketFC127414" + } + ] + ] + } + }, + { + "Action": [ + "kendra:BatchDeleteDocument", + "kendra:BatchPutDocument" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "multiplesourceskendraindexmultiplesourcesD8FB1621", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + } + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "2.173.2" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "2.173.2" + } + }, + "data-source-multiple-sources1": { + "id": "data-source-multiple-sources1", + "path": "lamken-multiple-sources/multiple-sources/data-source-multiple-sources1", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Kendra::DataSource", + "aws:cdk:cloudformation:props": { + "dataSourceConfiguration": { + "s3Configuration": { + "bucketName": { + "Ref": "secondScrapBucketFC127414" + } + } + }, + "indexId": { + "Ref": "multiplesourceskendraindexmultiplesourcesD8FB1621" }, "name": { "Fn::Join": [ "", [ - "s3-datasourceminimal-arguments0-", + "s3-datasourcemultiple-sources1-", { "Fn::Select": [ 2, @@ -996,7 +1512,7 @@ }, "roleArn": { "Fn::GetAtt": [ - "minimalargumentsdatasourceroleminimalarguments00EAC5006", + "multiplesourcesdatasourcerolemultiplesources16A50E028", "Arn" ] }, @@ -1005,12 +1521,12 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kendra.CfnDataSource", - "version": "2.150.0" + "version": "2.173.2" } }, - "kendra-data-source-minimal-arguments1": { - "id": "kendra-data-source-minimal-arguments1", - "path": "lamken-multiple-sources/minimal-arguments/kendra-data-source-minimal-arguments1", + "kendra-data-source-multiple-sources2": { + "id": "kendra-data-source-multiple-sources2", + "path": "lamken-multiple-sources/multiple-sources/kendra-data-source-multiple-sources2", "attributes": { "aws:cdk:cloudformation:type": "AWS::Kendra::DataSource", "aws:cdk:cloudformation:props": { @@ -1028,7 +1544,7 @@ }, "indexId": { "Fn::GetAtt": [ - "minimalargumentskendraindexminimalarguments5CBDD236", + "multiplesourceskendraindexmultiplesourcesD8FB1621", "Id" ] }, @@ -1044,13 +1560,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kendra.CfnDataSource", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-kendra.LambdaToKendra", - "version": "2.63.0" + "version": "2.76.0" } }, "Integ": { @@ -1066,7 +1582,7 @@ "path": "lamken-multiple-sources/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1078,7 +1594,7 @@ "path": "lamken-multiple-sources/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.173.2" } }, "CheckBootstrapVersion": { @@ -1086,25 +1602,25 @@ "path": "lamken-multiple-sources/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.173.2-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.173.2-alpha.0" } }, "BootstrapVersion": { @@ -1112,7 +1628,7 @@ "path": "lamken-multiple-sources/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.173.2" } }, "CheckBootstrapVersion": { @@ -1120,13 +1636,13 @@ "path": "lamken-multiple-sources/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.173.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.173.2" } }, "Tree": { @@ -1134,13 +1650,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.173.2" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.ts b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.ts index ffb52e233..fc8e6df69 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.ts +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-multiple-sources.ts @@ -28,6 +28,7 @@ stack.templateOptions.description = 'Integration Test for aws-lambda-kendra'; stack.node.setContext("@aws-cdk/aws-s3:serverAccessLogsUseBucketPolicy", true); const testBucket = defaults.CreateScrapBucket(stack, "scrapBucket"); +const secondTestBucket = defaults.CreateScrapBucket(stack, "secondScrapBucket"); const existingIamRole = new iam.Role(stack, 'existingRole', { assumedBy: new iam.ServicePrincipal('kendra.amazonaws.com') }); @@ -50,7 +51,7 @@ const webCrawlerSource = { } }; -new LambdaToKendra(stack, 'minimal-arguments', { +new LambdaToKendra(stack, 'multiple-sources', { lambdaFunctionProps: { code: lambda.Code.fromAsset(`lambda`), runtime: defaults.COMMERCIAL_REGION_LAMBDA_NODE_RUNTIME, @@ -64,6 +65,14 @@ new LambdaToKendra(stack, 'minimal-arguments', { } } }, + { + type: 'S3', + dataSourceConfiguration: { + s3Configuration: { + bucketName: secondTestBucket.bucketName, + } + } + }, webCrawlerSource ], }); diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f/index.js new file mode 100644 index 000000000..297328cfd --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f/index.js @@ -0,0 +1,21 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +exports.handler = async function(event) { + console.log('request:', JSON.stringify(event, undefined, 2)); + return { + statusCode: 200, + headers: { 'Content-Type': 'text/plain' }, + body: `Stub Lambda function for testing - ${event.path}\n` + }; + }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b/index.js deleted file mode 100644 index 3c81710ce..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b/index.js +++ /dev/null @@ -1,8 +0,0 @@ -exports.handler = async function(event) { - console.log('request:', JSON.stringify(event, undefined, 2)); - return { - statusCode: 200, - headers: { 'Content-Type': 'text/plain' }, - body: `Stub Lambda function for testing - ${event.path}\n` - }; - }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/integ.json index 99a06bcc3..46a64cafc 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamken-with-vpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamken-with-vpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamken-with-vpc.assets.json index ab7c47ae4..dc575ef65 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamken-with-vpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamken-with-vpc.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6": { "source": { @@ -14,33 +14,33 @@ } } }, - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b": { + "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f": { "source": { - "path": "asset.e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b", + "path": "asset.d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b.zip", + "objectKey": "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "aee37cec948ab75c3c01bd3eb33f592a07fdbb7c94dd02f381f99621e61eaf2b": { + "1af892d3208a7dc4f714d1654f25385053a0a3e01b98a6690a8a3b2eef94345d": { "source": { "path": "lamken-with-vpc.template.json", "packaging": "file" @@ -48,7 +48,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "aee37cec948ab75c3c01bd3eb33f592a07fdbb7c94dd02f381f99621e61eaf2b.json", + "objectKey": "1af892d3208a7dc4f714d1654f25385053a0a3e01b98a6690a8a3b2eef94345d.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamken-with-vpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamken-with-vpc.template.json index 29e8edd8f..1e7eda005 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamken-with-vpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamken-with-vpc.template.json @@ -552,7 +552,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b.zip" + "S3Key": "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f.zip" }, "Environment": { "Variables": { @@ -1206,6 +1206,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamken-with-vpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1293,7 +1299,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamkenwithvpcIntegDefaultTestDeployAssert3CDC35C6.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamkenwithvpcIntegDefaultTestDeployAssert3CDC35C6.assets.json index 57ccf94c4..043856dc2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamkenwithvpcIntegDefaultTestDeployAssert3CDC35C6.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/lamkenwithvpcIntegDefaultTestDeployAssert3CDC35C6.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/manifest.json index 181139404..d3c1808eb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamkenwithvpcIntegDefaultTestDeployAssert3CDC35C6.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/aee37cec948ab75c3c01bd3eb33f592a07fdbb7c94dd02f381f99621e61eaf2b.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/1af892d3208a7dc4f714d1654f25385053a0a3e01b98a6690a8a3b2eef94345d.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -106,6 +106,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamken-with-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamken-with-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -262,6 +268,12 @@ "data": "VpcKENDRAD98378E1" } ], + "/lamken-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamken-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/tree.json index ede5f918a..2d4bf4eef 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/integ.lamken-with-vpc.js.snapshot/tree.json @@ -40,7 +40,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -174,13 +174,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -192,19 +192,19 @@ "path": "lamken-with-vpc/scrapBucketLog/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -212,7 +212,7 @@ "path": "lamken-with-vpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -224,7 +224,7 @@ "path": "lamken-with-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -232,7 +232,7 @@ "path": "lamken-with-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -240,13 +240,13 @@ "path": "lamken-with-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "scrapBucket": { @@ -286,7 +286,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -384,13 +384,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -402,19 +402,19 @@ "path": "lamken-with-vpc/scrapBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "minimal-arguments": { @@ -430,7 +430,7 @@ "path": "lamken-with-vpc/minimal-arguments/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -493,7 +493,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -552,19 +552,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -592,13 +592,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -614,7 +614,7 @@ "path": "lamken-with-vpc/minimal-arguments/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -622,13 +622,13 @@ "path": "lamken-with-vpc/minimal-arguments/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -641,7 +641,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "e0128dd6e376c58a74b37bd6178ded8a5909d414a6891c26547b9778ac25679b.zip" + "s3Key": "d89f058f5194cced1bbf251642417472160658c64061bd045f1e3635f5abae3f.zip" }, "environment": { "variables": { @@ -687,13 +687,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "kendra-index-role-minimal-arguments": { @@ -705,7 +705,7 @@ "path": "lamken-with-vpc/minimal-arguments/kendra-index-role-minimal-arguments/Importkendra-index-role-minimal-arguments", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -823,13 +823,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "kendra-index-minimal-arguments": { @@ -870,7 +870,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kendra.CfnIndex", - "version": "2.150.0" + "version": "2.174.0" } }, "data-source-role-minimal-arguments0": { @@ -882,7 +882,7 @@ "path": "lamken-with-vpc/minimal-arguments/data-source-role-minimal-arguments0/Importdata-source-role-minimal-arguments0", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -962,13 +962,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "data-source-minimal-arguments0": { @@ -1019,13 +1019,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kendra.CfnDataSource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-kendra.LambdaToKendra", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -1052,7 +1052,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -1096,7 +1096,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1104,7 +1104,7 @@ "path": "lamken-with-vpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1126,7 +1126,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1145,13 +1145,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -1195,7 +1195,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1203,7 +1203,7 @@ "path": "lamken-with-vpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1225,7 +1225,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1244,13 +1244,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -1262,13 +1262,13 @@ "path": "lamken-with-vpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1284,7 +1284,7 @@ "path": "lamken-with-vpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1315,7 +1315,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1367,19 +1367,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -1403,13 +1403,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1443,13 +1443,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KENDRA": { @@ -1462,6 +1462,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamken-with-vpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1499,19 +1505,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1523,7 +1529,7 @@ "path": "lamken-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1531,7 +1537,7 @@ "path": "lamken-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1539,13 +1545,13 @@ "path": "lamken-with-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamken-with-vpc-KENDRA-security-group": { @@ -1601,13 +1607,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1623,7 +1629,7 @@ "path": "lamken-with-vpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1635,7 +1641,7 @@ "path": "lamken-with-vpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1643,25 +1649,25 @@ "path": "lamken-with-vpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1669,7 +1675,7 @@ "path": "lamken-with-vpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1677,13 +1683,13 @@ "path": "lamken-with-vpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1691,13 +1697,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/lambda-kendra.test.ts b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/lambda-kendra.test.ts index da156e490..d85b2e08a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/lambda-kendra.test.ts +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kendra/test/lambda-kendra.test.ts @@ -16,7 +16,7 @@ import * as lambda from 'aws-cdk-lib/aws-lambda'; import * as kendra from 'aws-cdk-lib/aws-kendra'; import * as iam from 'aws-cdk-lib/aws-iam'; import * as cdk from "aws-cdk-lib"; -import { Template } from 'aws-cdk-lib/assertions'; +import { Match, Template } from 'aws-cdk-lib/assertions'; import * as defaults from '@aws-solutions-constructs/core'; test('Launch with minimal code and check structure', () => { @@ -943,6 +943,8 @@ test('Launch with multiple S3 data sources', () => { }); const template = Template.fromStack(stack); + defaults.printWarning(`\n\n==dbg==\n${JSON.stringify(template)}\n\n==dbg===\n\n`); + template.resourceCountIs("AWS::Kendra::DataSource", 2); template.hasResourceProperties("AWS::Kendra::DataSource", { Type: 'S3', @@ -966,6 +968,64 @@ test('Launch with multiple S3 data sources', () => { "Fn::GetAtt": ["twosourcesdatasourceroletwosources164176C5E", "Arn"] }, }); + // Confirm we have Roles that appear correct + template.resourceCountIs("AWS::IAM::Role", 4); + template.hasResourceProperties("AWS::IAM::Role", { + AssumeRolePolicyDocument: { + Statement: [ + { + Action: "sts:AssumeRole", + Effect: "Allow", + Principal: { + Service: "kendra.amazonaws.com" + } + } + ] + }, + Policies: [ + { + PolicyDocument: { + Statement: [ + { + Action: "s3:GetObject", + Effect: "Allow", + Resource: Match.stringLikeRegexp(`.*test-bucket-name.*`) + }, + Match.anyValue(), + Match.anyValue() + ], + } + } + ] + }); + template.hasResourceProperties("AWS::IAM::Role", { + AssumeRolePolicyDocument: { + Statement: [ + { + Action: "sts:AssumeRole", + Effect: "Allow", + Principal: { + Service: "kendra.amazonaws.com" + } + } + ] + }, + Policies: [ + { + PolicyDocument: { + Statement: [ + { + Action: "s3:GetObject", + Effect: "Allow", + Resource: Match.stringLikeRegexp(`.*second-bucket-name.*`) + }, + Match.anyValue(), + Match.anyValue() + ], + } + } + ] + }); }); test('Test with custom environment variable name', () => { @@ -1079,3 +1139,257 @@ test('Confirm call to CheckLambdaProps', () => { // Assertion expect(app).toThrowError('Error - Either provide lambdaFunctionProps or existingLambdaObj, but not both.\n'); }); + +test('Launch with non default index type', () => { + const stack = new cdk.Stack(); + const testFunctionName = 'test-function-name24334'; + const testBucketName = 'test-bucket-name12344'; + const indexType = 'GEN_AI_ENTERPRISE_EDITION'; + + const lambdaProps: lambda.FunctionProps = { + functionName: testFunctionName, + code: lambda.Code.fromAsset(`${__dirname}/lambda`), + runtime: defaults.COMMERCIAL_REGION_LAMBDA_NODE_RUNTIME, + handler: 'index.handler' + }; + + new LambdaToKendra(stack, 'sample', { + lambdaFunctionProps: lambdaProps, + kendraDataSourcesProps: [{ + type: 'S3', + dataSourceConfiguration: { + s3Configuration: { + bucketName: testBucketName, + } + } + }], + kendraIndexProps: { + edition: indexType, + name: `enterprise-index` + }, + }); + + const template = Template.fromStack(stack); + template.hasResourceProperties("AWS::Lambda::Function", { + FunctionName: testFunctionName, + Environment: { + Variables: { + KENDRA_INDEX_ID: { + "Fn::GetAtt": ["samplekendraindexsample8A81A6C2", "Id"] + } + } + }, + }); + template.hasResourceProperties("AWS::Kendra::Index", { + RoleArn: { + "Fn::GetAtt": [ + "samplekendraindexrolesample4F9E7B66", + "Arn", + ], + }, + Edition: indexType + }); + template.hasResourceProperties("AWS::Kendra::DataSource", { + Type: 'S3', + DataSourceConfiguration: { + S3Configuration: { + BucketName: testBucketName + }, + }, + RoleArn: { + "Fn::GetAtt": ["sampledatasourcerolesample05A05F8BD", "Arn"] + }, + }); + // Confirm policy for Kendra index + template.hasResourceProperties("AWS::IAM::Role", { + Description: "Allow Kendra index to write CloudWatch Logs", + Policies: [ + { + PolicyDocument: { + Statement: [ + { + Action: "cloudwatch:PutMetricData", + Condition: { + StringEquals: { + "cloudwatch:namespace": "AWS/Kendra" + } + }, + Effect: "Allow", + Resource: "*" + }, + { + Action: "logs:CreateLogGroup", + Effect: "Allow", + Resource: { + "Fn::Join": [ + "", + [ + "arn:aws:logs:", + { + Ref: "AWS::Region" + }, + ":", + { + Ref: "AWS::AccountId" + }, + ":log-group:/aws/kendra/*" + ] + ] + } + }, + { + Action: "logs:DescribeLogGroups", + Effect: "Allow", + Resource: { + "Fn::Join": [ + "", + [ + "arn:", + { + Ref: "AWS::Partition" + }, + ":logs:", + { + Ref: "AWS::Region" + }, + ":", + { + Ref: "AWS::AccountId" + }, + ":log-group:/aws/kendra/*" + ] + ] + } + }, + { + Action: [ + "logs:CreateLogStream", + "logs:PutLogEvents", + "logs:DescribeLogStream" + ], + Effect: "Allow", + Resource: { + "Fn::Join": [ + "", + [ + "arn:", + { + Ref: "AWS::Partition" + }, + ":logs:", + { + Ref: "AWS::Region" + }, + ":", + { + Ref: "AWS::AccountId" + }, + ":log-group:/aws/kendra/*:log-stream:*" + ] + ] + } + } + ], + Version: "2012-10-17" + }, + PolicyName: "AllowLogging" + } + ], + }); + // Confirm policy for Kendra index + template.hasResourceProperties("AWS::IAM::Role", { + Description: "Policy for Kendra S3 Data Source", + AssumeRolePolicyDocument: { + Statement: [ + { + Action: "sts:AssumeRole", + Effect: "Allow", + Principal: { + Service: "kendra.amazonaws.com" + } + } + ], + Version: "2012-10-17" + }, + Policies: [ + { + PolicyDocument: { + Statement: [ + { + Action: "s3:GetObject", + Effect: "Allow", + Resource: `arn:aws:s3:::test-bucket-name12344/*` + }, + { + Action: "s3:ListBucket", + Effect: "Allow", + Resource: `arn:aws:s3:::test-bucket-name12344` + }, + { + Action: [ + "kendra:BatchPutDocument", + "kendra:BatchDeleteDocument" + ], + Effect: "Allow", + Resource: { + "Fn::GetAtt": [ + "samplekendraindexsample8A81A6C2", + "Arn" + ] + } + } + ], + Version: "2012-10-17" + }, + PolicyName: "s3CrawlPolicy" + } + ] + }); + // Confirm that Lambda function has QUERY access + template.hasResourceProperties("AWS::IAM::Policy", { + PolicyDocument: { + Statement: [ + { + Action: [ + "xray:PutTraceSegments", + "xray:PutTelemetryRecords" + ], + Effect: "Allow", + Resource: "*" + }, + { + Action: [ + "kendra:Query", + "kendra:Describe*", + "kendra:Get*", + "kendra:BatchGet*", + "kendra:List*", + "kendra:Retrieve", + ], + Effect: "Allow", + Resource: { + "Fn::GetAtt": [ + "samplekendraindexsample8A81A6C2", + "Arn" + ] + } + }, + { + Action: "kendra:SubmitFeedback", + Effect: "Allow", + Resource: { + "Fn::GetAtt": [ + "samplekendraindexsample8A81A6C2", + "Arn" + ] + } + } + ], + }, + Roles: [ + { + Ref: "sampletestfunctionname24334ServiceRole99395A01" + } + ] + }); +}); diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/package.json index b7f913b4c..768175446 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/package.json @@ -27,6 +27,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "integ-no-clean": "integ-runner --update-on-failed --no-clean", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/integ.json index 1fc0b855b..acb6dd28a 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamfhs-existing-vpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhs-existing-vpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhs-existing-vpc.assets.json index 292b022ff..cde3498ae 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhs-existing-vpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhs-existing-vpc.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6": { "source": { @@ -14,15 +14,15 @@ } } }, - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -40,7 +40,7 @@ } } }, - "76da48a6a750d8a8d1120d82068cdd1d9ea205b4fe236127ad10255b1c3e3a7d": { + "824df44c1ee78a27e5eaa6512741f782b611c303ac7eda5fb130d8d75ddda618": { "source": { "path": "lamfhs-existing-vpc.template.json", "packaging": "file" @@ -48,7 +48,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "76da48a6a750d8a8d1120d82068cdd1d9ea205b4fe236127ad10255b1c3e3a7d.json", + "objectKey": "824df44c1ee78a27e5eaa6512741f782b611c303ac7eda5fb130d8d75ddda618.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhs-existing-vpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhs-existing-vpc.template.json index 61fc78f8d..071a73236 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhs-existing-vpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhs-existing-vpc.template.json @@ -1200,6 +1200,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamfhs-existing-vpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1287,7 +1293,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhsexistingvpcIntegDefaultTestDeployAssert4FA50279.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhsexistingvpcIntegDefaultTestDeployAssert4FA50279.assets.json index 6ab46ed95..cb234a900 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhsexistingvpcIntegDefaultTestDeployAssert4FA50279.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/lamfhsexistingvpcIntegDefaultTestDeployAssert4FA50279.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/manifest.json index c7d30b2ca..861cea2b7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamfhsexistingvpcIntegDefaultTestDeployAssert4FA50279.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/76da48a6a750d8a8d1120d82068cdd1d9ea205b4fe236127ad10255b1c3e3a7d.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/824df44c1ee78a27e5eaa6512741f782b611c303ac7eda5fb130d8d75ddda618.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -154,6 +154,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamfhs-existing-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamfhs-existing-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -340,6 +346,12 @@ "data": "VpcKINESISFIREHOSE4115B5D1" } ], + "/lamfhs-existing-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamfhs-existing-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/tree.json index 09ecd593f..1888ce1e1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-existing-vpc.js.snapshot/tree.json @@ -50,7 +50,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -184,13 +184,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -202,19 +202,19 @@ "path": "lamfhs-existing-vpc/destination-firehose/S3LoggingBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "S3Bucket": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -371,13 +371,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -389,19 +389,19 @@ "path": "lamfhs-existing-vpc/destination-firehose/S3Bucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-group": { @@ -417,7 +417,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-stream": { @@ -437,19 +437,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehoseRole": { @@ -461,7 +461,7 @@ "path": "lamfhs-existing-vpc/destination-firehose/KinesisFirehoseRole/ImportKinesisFirehoseRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -486,13 +486,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehosePolicy": { @@ -584,13 +584,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehose": { @@ -659,13 +659,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-kinesisfirehose-s3.KinesisFirehoseToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "LatestNodeRuntimeMap": { @@ -673,7 +673,7 @@ "path": "lamfhs-existing-vpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -685,7 +685,7 @@ "path": "lamfhs-existing-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -693,7 +693,7 @@ "path": "lamfhs-existing-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -701,13 +701,13 @@ "path": "lamfhs-existing-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "destination-firehoseaws-managed-key": { @@ -715,7 +715,7 @@ "path": "lamfhs-existing-vpc/destination-firehoseaws-managed-key", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Vpc": { @@ -742,7 +742,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -786,7 +786,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -794,7 +794,7 @@ "path": "lamfhs-existing-vpc/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -816,7 +816,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -835,7 +835,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -855,7 +855,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -875,7 +875,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -903,13 +903,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -953,7 +953,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -961,7 +961,7 @@ "path": "lamfhs-existing-vpc/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -983,7 +983,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1002,7 +1002,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1022,7 +1022,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -1042,7 +1042,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -1070,13 +1070,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -1120,7 +1120,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1128,7 +1128,7 @@ "path": "lamfhs-existing-vpc/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1150,7 +1150,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1169,7 +1169,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1189,13 +1189,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -1239,7 +1239,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1247,7 +1247,7 @@ "path": "lamfhs-existing-vpc/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1269,7 +1269,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1288,7 +1288,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -1308,13 +1308,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -1333,7 +1333,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -1352,7 +1352,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -1364,13 +1364,13 @@ "path": "lamfhs-existing-vpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1386,7 +1386,7 @@ "path": "lamfhs-existing-vpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1417,7 +1417,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1469,19 +1469,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -1505,13 +1505,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1545,13 +1545,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_FIREHOSE": { @@ -1564,6 +1564,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamfhs-existing-vpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1601,19 +1607,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1625,7 +1631,7 @@ "path": "lamfhs-existing-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1633,7 +1639,7 @@ "path": "lamfhs-existing-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1641,13 +1647,13 @@ "path": "lamfhs-existing-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -1663,7 +1669,7 @@ "path": "lamfhs-existing-vpc/test-construct/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1726,7 +1732,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1782,19 +1788,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -1822,13 +1828,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -1844,7 +1850,7 @@ "path": "lamfhs-existing-vpc/test-construct/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -1852,13 +1858,13 @@ "path": "lamfhs-existing-vpc/test-construct/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1912,19 +1918,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-kinesisfirehose.LambdaToKinesisFirehose", - "version": "2.63.0" + "version": "2.76.0" } }, "lamfhs-existing-vpc-KINESIS_FIREHOSE-security-group": { @@ -1980,13 +1986,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -2002,7 +2008,7 @@ "path": "lamfhs-existing-vpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -2014,7 +2020,7 @@ "path": "lamfhs-existing-vpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2022,25 +2028,25 @@ "path": "lamfhs-existing-vpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -2048,7 +2054,7 @@ "path": "lamfhs-existing-vpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -2056,13 +2062,13 @@ "path": "lamfhs-existing-vpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -2070,13 +2076,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/integ.json index ede5b8e34..27c55a325 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamfhs-new-vpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhs-new-vpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhs-new-vpc.assets.json index c9ef22d03..8ba271879 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhs-new-vpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhs-new-vpc.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "faa95a81ae7d7373f3e1f242268f904eb748d8d0fdd306e8a6fe515a1905a7d6": { "source": { @@ -14,15 +14,15 @@ } } }, - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -40,7 +40,7 @@ } } }, - "c97dfc8f6cb4690df66f28d712e4df5a77df7a6c0d41913032a5f7604669bbe1": { + "49de85f0b7f679914c82fd9127ed8377bcef513fb05d1957b35193c65630c851": { "source": { "path": "lamfhs-new-vpc.template.json", "packaging": "file" @@ -48,7 +48,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "c97dfc8f6cb4690df66f28d712e4df5a77df7a6c0d41913032a5f7604669bbe1.json", + "objectKey": "49de85f0b7f679914c82fd9127ed8377bcef513fb05d1957b35193c65630c851.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhs-new-vpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhs-new-vpc.template.json index 59bfa29b8..4b558f44f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhs-new-vpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhs-new-vpc.template.json @@ -1134,6 +1134,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamfhs-new-vpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -1221,7 +1227,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhsnewvpcIntegDefaultTestDeployAssertAFD483AD.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhsnewvpcIntegDefaultTestDeployAssertAFD483AD.assets.json index 0b71b6d6e..8bc7099d3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhsnewvpcIntegDefaultTestDeployAssertAFD483AD.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/lamfhsnewvpcIntegDefaultTestDeployAssertAFD483AD.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/manifest.json index 00bcce951..680337115 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamfhsnewvpcIntegDefaultTestDeployAssertAFD483AD.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c97dfc8f6cb4690df66f28d712e4df5a77df7a6c0d41913032a5f7604669bbe1.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/49de85f0b7f679914c82fd9127ed8377bcef513fb05d1957b35193c65630c851.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -154,6 +154,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamfhs-new-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamfhs-new-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", @@ -268,6 +274,12 @@ "data": "VpcKINESISFIREHOSE4115B5D1" } ], + "/lamfhs-new-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamfhs-new-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/tree.json index 0331daaba..b3a924a8c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisfirehose/test/integ.lamfhs-new-vpc.js.snapshot/tree.json @@ -50,7 +50,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -184,13 +184,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -202,19 +202,19 @@ "path": "lamfhs-new-vpc/destination-firehose/S3LoggingBucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "S3Bucket": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -371,13 +371,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } }, "AutoDeleteObjectsCustomResource": { @@ -389,19 +389,19 @@ "path": "lamfhs-new-vpc/destination-firehose/S3Bucket/AutoDeleteObjectsCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-group": { @@ -417,7 +417,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "firehose-log-stream": { @@ -437,19 +437,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehoseRole": { @@ -461,7 +461,7 @@ "path": "lamfhs-new-vpc/destination-firehose/KinesisFirehoseRole/ImportKinesisFirehoseRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -486,13 +486,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehosePolicy": { @@ -584,13 +584,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisFirehose": { @@ -659,13 +659,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-kinesisfirehose-s3.KinesisFirehoseToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "LatestNodeRuntimeMap": { @@ -673,7 +673,7 @@ "path": "lamfhs-new-vpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::S3AutoDeleteObjectsCustomResourceProvider": { @@ -685,7 +685,7 @@ "path": "lamfhs-new-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -693,7 +693,7 @@ "path": "lamfhs-new-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -701,13 +701,13 @@ "path": "lamfhs-new-vpc/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "destination-firehoseaws-managed-key": { @@ -715,7 +715,7 @@ "path": "lamfhs-new-vpc/destination-firehoseaws-managed-key", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "test-construct": { @@ -731,7 +731,7 @@ "path": "lamfhs-new-vpc/test-construct/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -794,7 +794,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -850,19 +850,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -890,13 +890,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -912,7 +912,7 @@ "path": "lamfhs-new-vpc/test-construct/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -920,13 +920,13 @@ "path": "lamfhs-new-vpc/test-construct/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -980,19 +980,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-kinesisfirehose.LambdaToKinesisFirehose", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -1019,7 +1019,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -1063,7 +1063,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1071,7 +1071,7 @@ "path": "lamfhs-new-vpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1093,7 +1093,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1112,13 +1112,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -1162,7 +1162,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -1170,7 +1170,7 @@ "path": "lamfhs-new-vpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -1192,7 +1192,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -1211,13 +1211,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -1229,13 +1229,13 @@ "path": "lamfhs-new-vpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1251,7 +1251,7 @@ "path": "lamfhs-new-vpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1282,7 +1282,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1334,19 +1334,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -1370,13 +1370,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1410,13 +1410,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_FIREHOSE": { @@ -1429,6 +1429,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamfhs-new-vpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1466,19 +1472,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1490,7 +1496,7 @@ "path": "lamfhs-new-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1498,7 +1504,7 @@ "path": "lamfhs-new-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1506,13 +1512,13 @@ "path": "lamfhs-new-vpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamfhs-new-vpc-KINESIS_FIREHOSE-security-group": { @@ -1568,13 +1574,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1590,7 +1596,7 @@ "path": "lamfhs-new-vpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1602,7 +1608,7 @@ "path": "lamfhs-new-vpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1610,25 +1616,25 @@ "path": "lamfhs-new-vpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1636,7 +1642,7 @@ "path": "lamfhs-new-vpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1644,13 +1650,13 @@ "path": "lamfhs-new-vpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1658,13 +1664,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/package.json index 017cf129f..95979b8bb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/integ.json index a14d7ba6c..377d0cd26 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamkin-existingVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkin-existingVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkin-existingVpc.assets.json index b2d396d07..d93112acc 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkin-existingVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkin-existingVpc.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "32dac27396ac8588bd83b462adc449ccd0f9de649645d61bcdd8f0df62cfa39c": { + "5a48c00e0693f71b0ed8f210d1406be0448b731f769bf04378b9ed3ec47ef089": { "source": { "path": "lamkin-existingVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "32dac27396ac8588bd83b462adc449ccd0f9de649645d61bcdd8f0df62cfa39c.json", + "objectKey": "5a48c00e0693f71b0ed8f210d1406be0448b731f769bf04378b9ed3ec47ef089.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkin-existingVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkin-existingVpc.template.json index b05d70ddb..ef7c96307 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkin-existingVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkin-existingVpc.template.json @@ -578,6 +578,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamkin-existingVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -665,7 +671,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkinexistingVpcIntegDefaultTestDeployAssertB97E47BA.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkinexistingVpcIntegDefaultTestDeployAssertB97E47BA.assets.json index d4ced8426..c504bad4e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkinexistingVpcIntegDefaultTestDeployAssertB97E47BA.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/lamkinexistingVpcIntegDefaultTestDeployAssertB97E47BA.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/manifest.json index 3dc15c8e4..9c60aa5da 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamkinexistingVpcIntegDefaultTestDeployAssertB97E47BA.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/32dac27396ac8588bd83b462adc449ccd0f9de649645d61bcdd8f0df62cfa39c.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/5a48c00e0693f71b0ed8f210d1406be0448b731f769bf04378b9ed3ec47ef089.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -262,6 +262,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/tree.json index da0396cee..6d35d5738 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-existingVpc.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "lamkin-existingVpc/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "lamkin-existingVpc/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "lamkin-existingVpc/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "lamkin-existingVpc/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "lamkin-existingVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "lamkin-existingVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamkin-existingVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -891,19 +897,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -911,7 +917,7 @@ "path": "lamkin-existingVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -923,7 +929,7 @@ "path": "lamkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -931,7 +937,7 @@ "path": "lamkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -939,13 +945,13 @@ "path": "lamkin-existingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-lambda-kinesisstreams": { @@ -961,7 +967,7 @@ "path": "lamkin-existingVpc/test-lambda-kinesisstreams/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1024,7 +1030,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1079,19 +1085,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -1119,13 +1125,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -1141,7 +1147,7 @@ "path": "lamkin-existingVpc/test-lambda-kinesisstreams/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -1149,13 +1155,13 @@ "path": "lamkin-existingVpc/test-lambda-kinesisstreams/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1211,13 +1217,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStream": { @@ -1240,13 +1246,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamGetRecordsIteratorAgeAlarm": { @@ -1271,13 +1277,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -1302,19 +1308,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-kinesisstreams.LambdaToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "lamkin-existingVpc-KINESIS_STREAMS-security-group": { @@ -1370,13 +1376,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1392,7 +1398,7 @@ "path": "lamkin-existingVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1404,7 +1410,7 @@ "path": "lamkin-existingVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1412,25 +1418,25 @@ "path": "lamkin-existingVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1438,7 +1444,7 @@ "path": "lamkin-existingVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1446,13 +1452,13 @@ "path": "lamkin-existingVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1460,13 +1466,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/integ.json index 2b25a2ab7..ee949ebdb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamkin-newVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkin-newVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkin-newVpc.assets.json index 2fcb20088..19c7b44b0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkin-newVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkin-newVpc.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "8cd20233ea6ebd600fee69cca7608f9cfafe91f411b6a755c130db4cdae92075": { + "bfecf4a2f0fbd09ecbf10f4858fa73670c836525a4ce9f137e64ff4e60e10931": { "source": { "path": "lamkin-newVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "8cd20233ea6ebd600fee69cca7608f9cfafe91f411b6a755c130db4cdae92075.json", + "objectKey": "bfecf4a2f0fbd09ecbf10f4858fa73670c836525a4ce9f137e64ff4e60e10931.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkin-newVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkin-newVpc.template.json index 4b7b920e0..91864f6fb 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkin-newVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkin-newVpc.template.json @@ -552,6 +552,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamkin-newVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -639,7 +645,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkinnewVpcIntegDefaultTestDeployAssert16AC3D59.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkinnewVpcIntegDefaultTestDeployAssert16AC3D59.assets.json index 1371473ed..69d0922f0 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkinnewVpcIntegDefaultTestDeployAssert16AC3D59.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/lamkinnewVpcIntegDefaultTestDeployAssert16AC3D59.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/manifest.json index 98680712b..c4e6df6b7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamkinnewVpcIntegDefaultTestDeployAssert16AC3D59.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/8cd20233ea6ebd600fee69cca7608f9cfafe91f411b6a755c130db4cdae92075.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/bfecf4a2f0fbd09ecbf10f4858fa73670c836525a4ce9f137e64ff4e60e10931.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -208,6 +208,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamkin-newVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamkin-newVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/tree.json index e2a35bb6e..4a71f129f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpc.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamkin-newVpc/test-lambda-kinesisstreams/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -139,19 +139,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -179,13 +179,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -201,7 +201,7 @@ "path": "lamkin-newVpc/test-lambda-kinesisstreams/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -209,13 +209,13 @@ "path": "lamkin-newVpc/test-lambda-kinesisstreams/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -271,13 +271,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStream": { @@ -300,13 +300,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamGetRecordsIteratorAgeAlarm": { @@ -331,13 +331,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -362,19 +362,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-kinesisstreams.LambdaToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -401,7 +401,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -445,7 +445,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -453,7 +453,7 @@ "path": "lamkin-newVpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -475,7 +475,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -494,13 +494,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -544,7 +544,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -552,7 +552,7 @@ "path": "lamkin-newVpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -574,7 +574,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -593,13 +593,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -611,13 +611,13 @@ "path": "lamkin-newVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -633,7 +633,7 @@ "path": "lamkin-newVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -664,7 +664,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -716,19 +716,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -752,13 +752,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -792,13 +792,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -811,6 +811,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamkin-newVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -848,19 +854,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -868,7 +874,7 @@ "path": "lamkin-newVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -880,7 +886,7 @@ "path": "lamkin-newVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -888,7 +894,7 @@ "path": "lamkin-newVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -896,13 +902,13 @@ "path": "lamkin-newVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamkin-newVpc-KINESIS_STREAMS-security-group": { @@ -958,13 +964,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -980,7 +986,7 @@ "path": "lamkin-newVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -992,7 +998,7 @@ "path": "lamkin-newVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1000,25 +1006,25 @@ "path": "lamkin-newVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1026,7 +1032,7 @@ "path": "lamkin-newVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1034,13 +1040,13 @@ "path": "lamkin-newVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1048,13 +1054,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/integ.json index 906283317..6a35afb24 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamkin-newVpcFromProps/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkin-newVpcFromProps.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkin-newVpcFromProps.assets.json index 291b177ec..8c3b71cd1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkin-newVpcFromProps.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkin-newVpcFromProps.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "788d1e925ecb59bcfda1740b3cc37c8f95a0cde05a9bf78980b4dc116dfa89af": { + "b7d8320d0dc61638a9c1cd8ea88a3e50b0c982f4a44236f1a010675c63f3287e": { "source": { "path": "lamkin-newVpcFromProps.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "788d1e925ecb59bcfda1740b3cc37c8f95a0cde05a9bf78980b4dc116dfa89af.json", + "objectKey": "b7d8320d0dc61638a9c1cd8ea88a3e50b0c982f4a44236f1a010675c63f3287e.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkin-newVpcFromProps.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkin-newVpcFromProps.template.json index 0c2c45b98..cded33c09 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkin-newVpcFromProps.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkin-newVpcFromProps.template.json @@ -488,6 +488,12 @@ "Ref": "VpcisolatedSubnet1SubnetE62B1B9B" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamkin-newVpcFromProps/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -575,7 +581,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkinnewVpcFromPropsIntegDefaultTestDeployAssert95FE0487.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkinnewVpcFromPropsIntegDefaultTestDeployAssert95FE0487.assets.json index ab5fb59e6..df3aa8df7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkinnewVpcFromPropsIntegDefaultTestDeployAssert95FE0487.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/lamkinnewVpcFromPropsIntegDefaultTestDeployAssert95FE0487.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/manifest.json index d7d4f48f8..803cb0931 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamkinnewVpcFromPropsIntegDefaultTestDeployAssert95FE0487.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/788d1e925ecb59bcfda1740b3cc37c8f95a0cde05a9bf78980b4dc116dfa89af.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/b7d8320d0dc61638a9c1cd8ea88a3e50b0c982f4a44236f1a010675c63f3287e.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -190,6 +190,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamkin-newVpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamkin-newVpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/tree.json index 0598aff3d..b5df757c9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-kinesisstreams/test/integ.lamkin-newVpcFromProps.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamkin-newVpcFromProps/test-lambda-kinesisstreams/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -139,19 +139,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -179,13 +179,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -201,7 +201,7 @@ "path": "lamkin-newVpcFromProps/test-lambda-kinesisstreams/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -209,13 +209,13 @@ "path": "lamkin-newVpcFromProps/test-lambda-kinesisstreams/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -268,13 +268,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStream": { @@ -297,13 +297,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamGetRecordsIteratorAgeAlarm": { @@ -328,13 +328,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } }, "KinesisStreamReadProvisionedThroughputExceededAlarm": { @@ -359,19 +359,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-kinesisstreams.LambdaToKinesisStreams", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -398,7 +398,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -442,7 +442,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -450,7 +450,7 @@ "path": "lamkin-newVpcFromProps/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -472,7 +472,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -491,13 +491,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -509,13 +509,13 @@ "path": "lamkin-newVpcFromProps/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -531,7 +531,7 @@ "path": "lamkin-newVpcFromProps/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -562,7 +562,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -614,19 +614,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -650,13 +650,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -690,13 +690,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "KINESIS_STREAMS": { @@ -709,6 +709,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamkin-newVpcFromProps/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -743,19 +749,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -763,7 +769,7 @@ "path": "lamkin-newVpcFromProps/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -775,7 +781,7 @@ "path": "lamkin-newVpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -783,7 +789,7 @@ "path": "lamkin-newVpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -791,13 +797,13 @@ "path": "lamkin-newVpcFromProps/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamkin-newVpcFromProps-KINESIS_STREAMS-security-group": { @@ -853,13 +859,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -875,7 +881,7 @@ "path": "lamkin-newVpcFromProps/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -887,7 +893,7 @@ "path": "lamkin-newVpcFromProps/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -895,25 +901,25 @@ "path": "lamkin-newVpcFromProps/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -921,7 +927,7 @@ "path": "lamkin-newVpcFromProps/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -929,13 +935,13 @@ "path": "lamkin-newVpcFromProps/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -943,13 +949,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-opensearch/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-opensearch/package.json index 26d47df04..4196e0c1b 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-opensearch/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-opensearch/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/package.json index f41628c47..4eee8225e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/package.json @@ -27,6 +27,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "integ-no-clean": "integ-runner --update-on-failed --no-clean", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/integ.json index 2af6b62f0..2e289cb53 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lams3-deployFunctionWithVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3-deployFunctionWithVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3-deployFunctionWithVpc.assets.json index c4654f0c8..5f20ba3c5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3-deployFunctionWithVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3-deployFunctionWithVpc.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "b45d266b265bfa6f42bbf9ee7eba276e51a37e87a85b054d8d0c96d8d6ce9414": { + "ad12a3d04d959bc53477edeb4914e02749c7f31a65fa6017669d60dcd705003d": { "source": { "path": "lams3-deployFunctionWithVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "b45d266b265bfa6f42bbf9ee7eba276e51a37e87a85b054d8d0c96d8d6ce9414.json", + "objectKey": "ad12a3d04d959bc53477edeb4914e02749c7f31a65fa6017669d60dcd705003d.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3-deployFunctionWithVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3-deployFunctionWithVpc.template.json index 0b18bc6c0..3eb84a08d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3-deployFunctionWithVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3-deployFunctionWithVpc.template.json @@ -623,6 +623,12 @@ ] ] }, + "Tags": [ + { + "Key": "Name", + "Value": "lams3-deployFunctionWithVpc/Vpc" + } + ], "VpcEndpointType": "Gateway", "VpcId": { "Ref": "Vpc8378EB38" @@ -710,7 +716,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3deployFunctionWithVpcIntegDefaultTestDeployAssertF619BF7E.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3deployFunctionWithVpcIntegDefaultTestDeployAssertF619BF7E.assets.json index 7104e3880..4a98638d2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3deployFunctionWithVpcIntegDefaultTestDeployAssertF619BF7E.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/lams3deployFunctionWithVpcIntegDefaultTestDeployAssertF619BF7E.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/manifest.json index cea795fc5..b13162e22 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lams3deployFunctionWithVpcIntegDefaultTestDeployAssertF619BF7E.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/b45d266b265bfa6f42bbf9ee7eba276e51a37e87a85b054d8d0c96d8d6ce9414.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/ad12a3d04d959bc53477edeb4914e02749c7f31a65fa6017669d60dcd705003d.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -202,6 +202,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lams3-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lams3-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/tree.json index 8df98fbe2..5dcb40fb8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-s3/test/integ.lams3-deployFunctionWithVpc.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lams3-deployFunctionWithVpc/test-lambda-s3/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -162,19 +162,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -202,13 +202,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -224,7 +224,7 @@ "path": "lams3-deployFunctionWithVpc/test-lambda-s3/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -232,13 +232,13 @@ "path": "lams3-deployFunctionWithVpc/test-lambda-s3/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -294,13 +294,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "S3Bucket": { @@ -348,7 +348,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -407,25 +407,25 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.CfnBucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-s3.LambdaToS3", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -452,7 +452,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -496,7 +496,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -504,7 +504,7 @@ "path": "lams3-deployFunctionWithVpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -526,7 +526,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -545,13 +545,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -595,7 +595,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -603,7 +603,7 @@ "path": "lams3-deployFunctionWithVpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -625,7 +625,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -644,13 +644,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -662,13 +662,13 @@ "path": "lams3-deployFunctionWithVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -684,7 +684,7 @@ "path": "lams3-deployFunctionWithVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -715,7 +715,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -767,19 +767,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -803,13 +803,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -843,13 +843,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "S3": { @@ -862,6 +862,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lams3-deployFunctionWithVpc/Vpc" + } + ], "routeTableIds": [ { "Ref": "VpcisolatedSubnet1RouteTableE442650B" @@ -890,19 +896,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.GatewayVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -910,7 +916,7 @@ "path": "lams3-deployFunctionWithVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -922,7 +928,7 @@ "path": "lams3-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -930,7 +936,7 @@ "path": "lams3-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -938,13 +944,13 @@ "path": "lams3-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -960,7 +966,7 @@ "path": "lams3-deployFunctionWithVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -972,7 +978,7 @@ "path": "lams3-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -980,25 +986,25 @@ "path": "lams3-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1006,7 +1012,7 @@ "path": "lams3-deployFunctionWithVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1014,13 +1020,13 @@ "path": "lams3-deployFunctionWithVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1028,13 +1034,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/package.json index df203f0c8..6c9106824 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sagemakerendpoint/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/package.json index 3d327cb99..40bf89392 100755 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js deleted file mode 100644 index 743e4fdbb..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js +++ /dev/null @@ -1,8 +0,0 @@ -exports.handler = async function(event) { - console.log('request:', JSON.stringify(event, undefined, 2)); - return { - statusCode: 200, - headers: { 'Content-Type': 'text/plain' }, - body: `Hello, CDK! You've hit ${event.path}\n` - }; - }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js new file mode 100644 index 000000000..44a0a9467 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js @@ -0,0 +1,21 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +exports.handler = async function(event) { + console.log('request:', JSON.stringify(event, undefined, 2)); + return { + statusCode: 200, + headers: { 'Content-Type': 'text/plain' }, + body: `Hello, CDK! You've hit ${event.path}\n` + }; + }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/integ.json index b6137d469..58277d4ae 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamsec-deployFunctionWithExistingVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsec-deployFunctionWithExistingVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsec-deployFunctionWithExistingVpc.assets.json index 4c5a4dbb8..94df8ccd6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsec-deployFunctionWithExistingVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsec-deployFunctionWithExistingVpc.assets.json @@ -1,33 +1,33 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8": { + "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c": { "source": { - "path": "asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8", + "path": "asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip", + "objectKey": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "6e86fbde3ee4dfaa7fee180d7129ae0826ccdc07f3ac49de730fc058ea4c90c2": { + "cbdd87f183076388ee1c7e2fef5b4aa72011c3ceb66a40d0062d2ce88e737fe9": { "source": { "path": "lamsec-deployFunctionWithExistingVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "6e86fbde3ee4dfaa7fee180d7129ae0826ccdc07f3ac49de730fc058ea4c90c2.json", + "objectKey": "cbdd87f183076388ee1c7e2fef5b4aa72011c3ceb66a40d0062d2ce88e737fe9.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsec-deployFunctionWithExistingVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsec-deployFunctionWithExistingVpc.template.json index 6ac0db755..0541154f9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsec-deployFunctionWithExistingVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsec-deployFunctionWithExistingVpc.template.json @@ -579,6 +579,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamsec-deployFunctionWithExistingVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -666,7 +672,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, @@ -858,7 +864,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "S3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "Environment": { "Variables": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsecdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert647243A7.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsecdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert647243A7.assets.json index 2c6d94e89..51134fd0b 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsecdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert647243A7.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/lamsecdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert647243A7.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/manifest.json index eb1494d74..a1dbbecb3 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamsecdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert647243A7.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/6e86fbde3ee4dfaa7fee180d7129ae0826ccdc07f3ac49de730fc058ea4c90c2.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/cbdd87f183076388ee1c7e2fef5b4aa72011c3ceb66a40d0062d2ce88e737fe9.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -262,6 +262,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamsec-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamsec-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/tree.json index 69fb8dbd9..f87713dd9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithExistingVpc.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "lamsec-deployFunctionWithExistingVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SECRETS_MANAGER": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamsec-deployFunctionWithExistingVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -891,19 +897,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -911,7 +917,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -923,7 +929,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -931,7 +937,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -939,13 +945,13 @@ "path": "lamsec-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-lambda-secretsmanager-stack": { @@ -961,7 +967,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/test-lambda-secretsmanager-stack/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1024,7 +1030,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1075,19 +1081,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -1115,13 +1121,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -1137,7 +1143,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/test-lambda-secretsmanager-stack/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -1145,13 +1151,13 @@ "path": "lamsec-deployFunctionWithExistingVpc/test-lambda-secretsmanager-stack/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1164,7 +1170,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "s3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "environment": { "variables": { @@ -1207,13 +1213,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "secret": { @@ -1231,19 +1237,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_secretsmanager.CfnSecret", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_secretsmanager.Secret", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-secretsmanager.LambdaToSecretsmanager", - "version": "2.63.0" + "version": "2.76.0" } }, "lamsec-deployFunctionWithExistingVpc-SECRETS_MANAGER-security-group": { @@ -1299,13 +1305,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1321,7 +1327,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1333,7 +1339,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1341,25 +1347,25 @@ "path": "lamsec-deployFunctionWithExistingVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1367,7 +1373,7 @@ "path": "lamsec-deployFunctionWithExistingVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1375,13 +1381,13 @@ "path": "lamsec-deployFunctionWithExistingVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1389,13 +1395,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js deleted file mode 100644 index 743e4fdbb..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js +++ /dev/null @@ -1,8 +0,0 @@ -exports.handler = async function(event) { - console.log('request:', JSON.stringify(event, undefined, 2)); - return { - statusCode: 200, - headers: { 'Content-Type': 'text/plain' }, - body: `Hello, CDK! You've hit ${event.path}\n` - }; - }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js new file mode 100644 index 000000000..44a0a9467 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js @@ -0,0 +1,21 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +exports.handler = async function(event) { + console.log('request:', JSON.stringify(event, undefined, 2)); + return { + statusCode: 200, + headers: { 'Content-Type': 'text/plain' }, + body: `Hello, CDK! You've hit ${event.path}\n` + }; + }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/integ.json index 52e6f205c..79002d2d5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamsec-deployFunctionWithVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsec-deployFunctionWithVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsec-deployFunctionWithVpc.assets.json index d061f18b3..0ca908bdf 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsec-deployFunctionWithVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsec-deployFunctionWithVpc.assets.json @@ -1,33 +1,33 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8": { + "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c": { "source": { - "path": "asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8", + "path": "asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip", + "objectKey": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "778906270efc53a4ceeddc1d26deaf9553d93d3e02a5056fe8e1078e6f902691": { + "554469df7dc68c62e314d2e15a5e504cc7c5cf9ff30ea51202e7acf77d24962e": { "source": { "path": "lamsec-deployFunctionWithVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "778906270efc53a4ceeddc1d26deaf9553d93d3e02a5056fe8e1078e6f902691.json", + "objectKey": "554469df7dc68c62e314d2e15a5e504cc7c5cf9ff30ea51202e7acf77d24962e.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsec-deployFunctionWithVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsec-deployFunctionWithVpc.template.json index 7bc22cb00..4376d3ac6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsec-deployFunctionWithVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsec-deployFunctionWithVpc.template.json @@ -149,7 +149,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "S3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "Environment": { "Variables": { @@ -528,6 +528,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamsec-deployFunctionWithVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -615,7 +621,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsecdeployFunctionWithVpcIntegDefaultTestDeployAssert66148FF5.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsecdeployFunctionWithVpcIntegDefaultTestDeployAssert66148FF5.assets.json index 42dbaff54..e533162f5 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsecdeployFunctionWithVpcIntegDefaultTestDeployAssert66148FF5.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/lamsecdeployFunctionWithVpcIntegDefaultTestDeployAssert66148FF5.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/manifest.json index 3aa12d146..5d5d65723 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamsecdeployFunctionWithVpcIntegDefaultTestDeployAssert66148FF5.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/778906270efc53a4ceeddc1d26deaf9553d93d3e02a5056fe8e1078e6f902691.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/554469df7dc68c62e314d2e15a5e504cc7c5cf9ff30ea51202e7acf77d24962e.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -196,6 +196,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamsec-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamsec-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/tree.json index cc923e7b9..b8c004ee8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-secretsmanager/test/integ.lamsec-deployFunctionWithVpc.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamsec-deployFunctionWithVpc/test-lambda-secretsmanager/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -135,19 +135,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -175,13 +175,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -197,7 +197,7 @@ "path": "lamsec-deployFunctionWithVpc/test-lambda-secretsmanager/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -205,13 +205,13 @@ "path": "lamsec-deployFunctionWithVpc/test-lambda-secretsmanager/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -224,7 +224,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "s3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "environment": { "variables": { @@ -267,13 +267,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "secret": { @@ -291,19 +291,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_secretsmanager.CfnSecret", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_secretsmanager.Secret", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-secretsmanager.LambdaToSecretsmanager", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -330,7 +330,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -374,7 +374,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -382,7 +382,7 @@ "path": "lamsec-deployFunctionWithVpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -404,7 +404,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -423,13 +423,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -473,7 +473,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -481,7 +481,7 @@ "path": "lamsec-deployFunctionWithVpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -503,7 +503,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -522,13 +522,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -540,13 +540,13 @@ "path": "lamsec-deployFunctionWithVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -562,7 +562,7 @@ "path": "lamsec-deployFunctionWithVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -593,7 +593,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -645,19 +645,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -681,13 +681,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -721,13 +721,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SECRETS_MANAGER": { @@ -740,6 +740,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamsec-deployFunctionWithVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -777,19 +783,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -797,7 +803,7 @@ "path": "lamsec-deployFunctionWithVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -809,7 +815,7 @@ "path": "lamsec-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -817,7 +823,7 @@ "path": "lamsec-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -825,13 +831,13 @@ "path": "lamsec-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamsec-deployFunctionWithVpc-SECRETS_MANAGER-security-group": { @@ -887,13 +893,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -909,7 +915,7 @@ "path": "lamsec-deployFunctionWithVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -921,7 +927,7 @@ "path": "lamsec-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -929,25 +935,25 @@ "path": "lamsec-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -955,7 +961,7 @@ "path": "lamsec-deployFunctionWithVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -963,13 +969,13 @@ "path": "lamsec-deployFunctionWithVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -977,13 +983,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/package.json index 3fca82323..feeff334f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/integ.json index 8d7b41ac5..bbda6896c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamsns-deployFunctionWithVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsns-deployFunctionWithVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsns-deployFunctionWithVpc.assets.json index c294bcbc7..da39f5590 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsns-deployFunctionWithVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsns-deployFunctionWithVpc.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "556d2d0ecdf6753499c3fc70b8288c30484b747e14ff0aef391e75a48a41fd6b": { + "fa852462691caa3089915c8467f5bdcc5c8099c50c63ef472c5b033840c25574": { "source": { "path": "lamsns-deployFunctionWithVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "556d2d0ecdf6753499c3fc70b8288c30484b747e14ff0aef391e75a48a41fd6b.json", + "objectKey": "fa852462691caa3089915c8467f5bdcc5c8099c50c63ef472c5b033840c25574.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsns-deployFunctionWithVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsns-deployFunctionWithVpc.template.json index 613732f81..e012770a7 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsns-deployFunctionWithVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsns-deployFunctionWithVpc.template.json @@ -622,6 +622,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamsns-deployFunctionWithVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -709,7 +715,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsnsdeployFunctionWithVpcIntegDefaultTestDeployAssertEDF33408.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsnsdeployFunctionWithVpcIntegDefaultTestDeployAssertEDF33408.assets.json index 949acaf5c..29d05e909 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsnsdeployFunctionWithVpcIntegDefaultTestDeployAssertEDF33408.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/lamsnsdeployFunctionWithVpcIntegDefaultTestDeployAssertEDF33408.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/manifest.json index 949d82836..14bb893bd 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamsnsdeployFunctionWithVpcIntegDefaultTestDeployAssertEDF33408.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/556d2d0ecdf6753499c3fc70b8288c30484b747e14ff0aef391e75a48a41fd6b.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/fa852462691caa3089915c8467f5bdcc5c8099c50c63ef472c5b033840c25574.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -202,6 +202,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamsns-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamsns-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/tree.json index 68e028208..f8956c9ef 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sns/test/integ.lamsns-deployFunctionWithVpc.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamsns-deployFunctionWithVpc/test-lambda-sns/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -132,19 +132,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -172,13 +172,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -194,7 +194,7 @@ "path": "lamsns-deployFunctionWithVpc/test-lambda-sns/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -202,13 +202,13 @@ "path": "lamsns-deployFunctionWithVpc/test-lambda-sns/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -270,13 +270,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "aws-managed-key": { @@ -284,7 +284,7 @@ "path": "lamsns-deployFunctionWithVpc/test-lambda-sns/aws-managed-key", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "SnsTopic": { @@ -321,7 +321,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.CfnTopic", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -417,25 +417,25 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.CfnTopicPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.TopicPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sns.Topic", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-sns.LambdaToSns", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -462,7 +462,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -506,7 +506,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -514,7 +514,7 @@ "path": "lamsns-deployFunctionWithVpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -536,7 +536,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -555,13 +555,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -605,7 +605,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -613,7 +613,7 @@ "path": "lamsns-deployFunctionWithVpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -635,7 +635,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -654,13 +654,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -672,13 +672,13 @@ "path": "lamsns-deployFunctionWithVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -694,7 +694,7 @@ "path": "lamsns-deployFunctionWithVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -725,7 +725,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -777,19 +777,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -813,13 +813,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -853,13 +853,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SNS": { @@ -872,6 +872,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamsns-deployFunctionWithVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -909,19 +915,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -929,7 +935,7 @@ "path": "lamsns-deployFunctionWithVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -941,7 +947,7 @@ "path": "lamsns-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -949,7 +955,7 @@ "path": "lamsns-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -957,13 +963,13 @@ "path": "lamsns-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamsns-deployFunctionWithVpc-SNS-security-group": { @@ -1019,13 +1025,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1041,7 +1047,7 @@ "path": "lamsns-deployFunctionWithVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1053,7 +1059,7 @@ "path": "lamsns-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1061,25 +1067,25 @@ "path": "lamsns-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1087,7 +1093,7 @@ "path": "lamsns-deployFunctionWithVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1095,13 +1101,13 @@ "path": "lamsns-deployFunctionWithVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1109,13 +1115,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/package.json index 799d918dd..b5c840586 100755 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/integ.json index 9eedf1113..e899de0ac 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamsqslam-deployProducerFunctionWithVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslam-deployProducerFunctionWithVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslam-deployProducerFunctionWithVpc.assets.json index d86e983d0..616283bdf 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslam-deployProducerFunctionWithVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslam-deployProducerFunctionWithVpc.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -40,7 +40,7 @@ } } }, - "0f4b95584aff944af3e3df212a90ae39b0a26ad46cd07637d3bd3978d8063c88": { + "b1d0348e11f0d8a442d12fa82aa7469efd28d963c6177dd08a85987882981213": { "source": { "path": "lamsqslam-deployProducerFunctionWithVpc.template.json", "packaging": "file" @@ -48,7 +48,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0f4b95584aff944af3e3df212a90ae39b0a26ad46cd07637d3bd3978d8063c88.json", + "objectKey": "b1d0348e11f0d8a442d12fa82aa7469efd28d963c6177dd08a85987882981213.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslam-deployProducerFunctionWithVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslam-deployProducerFunctionWithVpc.template.json index 84de3508f..54323fd7f 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslam-deployProducerFunctionWithVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslam-deployProducerFunctionWithVpc.template.json @@ -681,6 +681,12 @@ "Ref": "testlambdasqsVpcisolatedSubnet2Subnet320D7431" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "testlambdasqsVpc85322AF3" @@ -1001,7 +1007,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslamdeployProducerFunctionWithVpcIntegDefaultTestDeployAssert1C26B326.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslamdeployProducerFunctionWithVpcIntegDefaultTestDeployAssert1C26B326.assets.json index 407560c5e..23bef5247 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslamdeployProducerFunctionWithVpcIntegDefaultTestDeployAssert1C26B326.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/lamsqslamdeployProducerFunctionWithVpcIntegDefaultTestDeployAssert1C26B326.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/manifest.json index f3ba765c1..d1c0e6853 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamsqslamdeployProducerFunctionWithVpcIntegDefaultTestDeployAssert1C26B326.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/0f4b95584aff944af3e3df212a90ae39b0a26ad46cd07637d3bd3978d8063c88.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/b1d0348e11f0d8a442d12fa82aa7469efd28d963c6177dd08a85987882981213.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -244,6 +244,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamsqslam-deployProducerFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamsqslam-deployProducerFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/tree.json index 8cf7adb88..8b6975cd9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs-lambda/test/integ.lamsqslam-deployProducerFunctionWithVpc.js.snapshot/tree.json @@ -25,7 +25,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/lambda-to-sqs/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -88,7 +88,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -143,19 +143,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -183,13 +183,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -205,7 +205,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/lambda-to-sqs/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -213,13 +213,13 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/lambda-to-sqs/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -275,13 +275,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "queue-dlq": { @@ -299,7 +299,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -382,19 +382,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.150.0" + "version": "2.174.0" } }, "queue": { @@ -421,7 +421,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -504,25 +504,25 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-sqs.LambdaToSqs", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -549,7 +549,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -593,7 +593,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -601,7 +601,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -642,13 +642,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -692,7 +692,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -700,7 +700,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -722,7 +722,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -741,13 +741,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -759,13 +759,13 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -781,7 +781,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -812,7 +812,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -864,19 +864,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -900,13 +900,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -940,13 +940,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SQS": { @@ -959,6 +959,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -996,19 +1002,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "test-lambda-sqs-SQS-security-group": { @@ -1064,13 +1070,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "sqs-to-lambda": { @@ -1086,7 +1092,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/sqs-to-lambda/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1149,7 +1155,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1201,19 +1207,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -1229,7 +1235,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/sqs-to-lambda/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -1237,13 +1243,13 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/test-lambda-sqs/sqs-to-lambda/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1278,7 +1284,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } }, "SqsEventSource:lamsqslamdeployProducerFunctionWithVpctestlambdasqslambdatosqsqueueD62DE11E": { @@ -1304,31 +1310,31 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnEventSourceMapping", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.EventSourceMapping", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-sqs-lambda.SqsToLambda", - "version": "2.63.0" + "version": "2.76.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-sqs-lambda.LambdaToSqsToLambda", - "version": "2.63.0" + "version": "2.76.0" } }, "LatestNodeRuntimeMap": { @@ -1336,7 +1342,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1348,7 +1354,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1356,7 +1362,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1364,13 +1370,13 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1386,7 +1392,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1398,7 +1404,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1406,25 +1412,25 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1432,7 +1438,7 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1440,13 +1446,13 @@ "path": "lamsqslam-deployProducerFunctionWithVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1454,13 +1460,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/package.json index 224e81432..6862b8bd0 100755 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/integ.json index bd29db0af..518c41f08 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamsqs-deployFunctionWithVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqs-deployFunctionWithVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqs-deployFunctionWithVpc.assets.json index 0a4dc66c9..fcdfa7053 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqs-deployFunctionWithVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqs-deployFunctionWithVpc.assets.json @@ -1,15 +1,15 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } @@ -27,7 +27,7 @@ } } }, - "34888f0b529ad8e9622ebaeeb122b43bfc1893d37b92f4bdaf09157e73000c54": { + "edda4ec92b882c6192cb8666776cd10cbdc24f2cc4a8e9363f4488b270c51f6d": { "source": { "path": "lamsqs-deployFunctionWithVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "34888f0b529ad8e9622ebaeeb122b43bfc1893d37b92f4bdaf09157e73000c54.json", + "objectKey": "edda4ec92b882c6192cb8666776cd10cbdc24f2cc4a8e9363f4488b270c51f6d.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqs-deployFunctionWithVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqs-deployFunctionWithVpc.template.json index 7ba15a0f7..140dd3ea4 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqs-deployFunctionWithVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqs-deployFunctionWithVpc.template.json @@ -681,6 +681,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamsqs-deployFunctionWithVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -768,7 +774,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqsdeployFunctionWithVpcIntegDefaultTestDeployAssert1B8DD590.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqsdeployFunctionWithVpcIntegDefaultTestDeployAssert1B8DD590.assets.json index 01754b2f7..7b35acbe4 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqsdeployFunctionWithVpcIntegDefaultTestDeployAssert1B8DD590.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/lamsqsdeployFunctionWithVpcIntegDefaultTestDeployAssert1B8DD590.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/manifest.json index ef690f78b..dcb99d5b1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamsqsdeployFunctionWithVpcIntegDefaultTestDeployAssert1B8DD590.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/34888f0b529ad8e9622ebaeeb122b43bfc1893d37b92f4bdaf09157e73000c54.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/edda4ec92b882c6192cb8666776cd10cbdc24f2cc4a8e9363f4488b270c51f6d.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -214,6 +214,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamsqs-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamsqs-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/tree.json index e8ac7fc47..efa7a1432 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-sqs/test/integ.lamsqs-deployFunctionWithVpc.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamsqs-deployFunctionWithVpc/test-lambda-sqs/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -139,19 +139,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -179,13 +179,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -201,7 +201,7 @@ "path": "lamsqs-deployFunctionWithVpc/test-lambda-sqs/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -209,13 +209,13 @@ "path": "lamsqs-deployFunctionWithVpc/test-lambda-sqs/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -271,13 +271,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "queue-dlq": { @@ -295,7 +295,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -378,19 +378,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.150.0" + "version": "2.174.0" } }, "queue": { @@ -417,7 +417,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueue", - "version": "2.150.0" + "version": "2.174.0" } }, "Policy": { @@ -500,25 +500,25 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.CfnQueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.QueuePolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_sqs.Queue", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-sqs.LambdaToSqs", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -545,7 +545,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -589,7 +589,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -597,7 +597,7 @@ "path": "lamsqs-deployFunctionWithVpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -619,7 +619,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -638,13 +638,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -688,7 +688,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -696,7 +696,7 @@ "path": "lamsqs-deployFunctionWithVpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -718,7 +718,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -737,13 +737,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -755,13 +755,13 @@ "path": "lamsqs-deployFunctionWithVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -777,7 +777,7 @@ "path": "lamsqs-deployFunctionWithVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -808,7 +808,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -860,19 +860,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -896,13 +896,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -936,13 +936,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SQS": { @@ -955,6 +955,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamsqs-deployFunctionWithVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -992,19 +998,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1012,7 +1018,7 @@ "path": "lamsqs-deployFunctionWithVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1024,7 +1030,7 @@ "path": "lamsqs-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1032,7 +1038,7 @@ "path": "lamsqs-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1040,13 +1046,13 @@ "path": "lamsqs-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamsqs-deployFunctionWithVpc-SQS-security-group": { @@ -1102,13 +1108,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1124,7 +1130,7 @@ "path": "lamsqs-deployFunctionWithVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1136,7 +1142,7 @@ "path": "lamsqs-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1144,25 +1150,25 @@ "path": "lamsqs-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1170,7 +1176,7 @@ "path": "lamsqs-deployFunctionWithVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1178,13 +1184,13 @@ "path": "lamsqs-deployFunctionWithVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1192,13 +1198,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/package.json index fc1f41b83..b3661bfa5 100755 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js deleted file mode 100644 index 743e4fdbb..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js +++ /dev/null @@ -1,8 +0,0 @@ -exports.handler = async function(event) { - console.log('request:', JSON.stringify(event, undefined, 2)); - return { - statusCode: 200, - headers: { 'Content-Type': 'text/plain' }, - body: `Hello, CDK! You've hit ${event.path}\n` - }; - }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js new file mode 100644 index 000000000..44a0a9467 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js @@ -0,0 +1,21 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +exports.handler = async function(event) { + console.log('request:', JSON.stringify(event, undefined, 2)); + return { + statusCode: 200, + headers: { 'Content-Type': 'text/plain' }, + body: `Hello, CDK! You've hit ${event.path}\n` + }; + }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/integ.json index f3d70e034..626169998 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamssm-deployFunctionWithExistingVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssm-deployFunctionWithExistingVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssm-deployFunctionWithExistingVpc.assets.json index 83d2d52c7..200d7948e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssm-deployFunctionWithExistingVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssm-deployFunctionWithExistingVpc.assets.json @@ -1,33 +1,33 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8": { + "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c": { "source": { - "path": "asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8", + "path": "asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip", + "objectKey": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "6ca04276ae1d94b2ce0ebe2d4ee71e382e76257091f01206e3a2e33a895a75a4": { + "c25ee66649f1d22a7d4b4b17d72511dfb0fc6a1e704a74c0cb3b3683abf1231a": { "source": { "path": "lamssm-deployFunctionWithExistingVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "6ca04276ae1d94b2ce0ebe2d4ee71e382e76257091f01206e3a2e33a895a75a4.json", + "objectKey": "c25ee66649f1d22a7d4b4b17d72511dfb0fc6a1e704a74c0cb3b3683abf1231a.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssm-deployFunctionWithExistingVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssm-deployFunctionWithExistingVpc.template.json index 19af07580..6d54f3051 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssm-deployFunctionWithExistingVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssm-deployFunctionWithExistingVpc.template.json @@ -579,6 +579,12 @@ "Ref": "VpcPrivateSubnet2Subnet3788AAA1" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamssm-deployFunctionWithExistingVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -666,7 +672,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, @@ -880,7 +886,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "S3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "Environment": { "Variables": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssmdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert63E58D9E.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssmdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert63E58D9E.assets.json index 6513c25d4..30e7c1b1e 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssmdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert63E58D9E.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/lamssmdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert63E58D9E.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/manifest.json index a0b7f4841..f52714738 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamssmdeployFunctionWithExistingVpcIntegDefaultTestDeployAssert63E58D9E.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/6ca04276ae1d94b2ce0ebe2d4ee71e382e76257091f01206e3a2e33a895a75a4.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c25ee66649f1d22a7d4b4b17d72511dfb0fc6a1e704a74c0cb3b3683abf1231a.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -262,6 +262,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamssm-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamssm-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/tree.json index d4f67ec64..d88ddba92 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithExistingVpc.js.snapshot/tree.json @@ -32,7 +32,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet1": { @@ -76,7 +76,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -84,7 +84,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/Vpc/PublicSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -106,7 +106,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -125,7 +125,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -145,7 +145,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -165,7 +165,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -193,13 +193,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PublicSubnet2": { @@ -243,7 +243,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -251,7 +251,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/Vpc/PublicSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -273,7 +273,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -292,7 +292,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -312,7 +312,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } }, "EIP": { @@ -332,7 +332,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnEIP", - "version": "2.150.0" + "version": "2.174.0" } }, "NATGateway": { @@ -360,13 +360,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnNatGateway", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PublicSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet1": { @@ -410,7 +410,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -418,7 +418,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/Vpc/PrivateSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -440,7 +440,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -459,7 +459,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -479,13 +479,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "PrivateSubnet2": { @@ -529,7 +529,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -537,7 +537,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/Vpc/PrivateSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -559,7 +559,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -578,7 +578,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultRoute": { @@ -598,13 +598,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRoute", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "IGW": { @@ -623,7 +623,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnInternetGateway", - "version": "2.150.0" + "version": "2.174.0" } }, "VPCGW": { @@ -642,7 +642,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCGatewayAttachment", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -654,13 +654,13 @@ "path": "lamssm-deployFunctionWithExistingVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -676,7 +676,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -707,7 +707,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -759,19 +759,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -795,13 +795,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -835,13 +835,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SSM": { @@ -854,6 +854,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamssm-deployFunctionWithExistingVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -891,19 +897,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -911,7 +917,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -923,7 +929,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -931,7 +937,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -939,13 +945,13 @@ "path": "lamssm-deployFunctionWithExistingVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "test-lambda-ssmstringparameter": { @@ -961,7 +967,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/test-lambda-ssmstringparameter/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1024,7 +1030,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1097,19 +1103,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -1137,13 +1143,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -1159,7 +1165,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/test-lambda-ssmstringparameter/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -1167,13 +1173,13 @@ "path": "lamssm-deployFunctionWithExistingVpc/test-lambda-ssmstringparameter/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1186,7 +1192,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "s3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "environment": { "variables": { @@ -1229,13 +1235,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "stringParameter": { @@ -1254,19 +1260,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ssm.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ssm.StringParameter", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-ssmstringparameter.LambdaToSsmstringparameter", - "version": "2.63.0" + "version": "2.76.0" } }, "lamssm-deployFunctionWithExistingVpc-SSM-security-group": { @@ -1322,13 +1328,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1344,7 +1350,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1356,7 +1362,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1364,25 +1370,25 @@ "path": "lamssm-deployFunctionWithExistingVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1390,7 +1396,7 @@ "path": "lamssm-deployFunctionWithExistingVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1398,13 +1404,13 @@ "path": "lamssm-deployFunctionWithExistingVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1412,13 +1418,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js deleted file mode 100644 index 743e4fdbb..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8/index.js +++ /dev/null @@ -1,8 +0,0 @@ -exports.handler = async function(event) { - console.log('request:', JSON.stringify(event, undefined, 2)); - return { - statusCode: 200, - headers: { 'Content-Type': 'text/plain' }, - body: `Hello, CDK! You've hit ${event.path}\n` - }; - }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js new file mode 100644 index 000000000..44a0a9467 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c/index.js @@ -0,0 +1,21 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +exports.handler = async function(event) { + console.log('request:', JSON.stringify(event, undefined, 2)); + return { + statusCode: 200, + headers: { 'Content-Type': 'text/plain' }, + body: `Hello, CDK! You've hit ${event.path}\n` + }; + }; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/integ.json index 335e8d2a0..231e0a21c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamssm-deployFunctionWithVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssm-deployFunctionWithVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssm-deployFunctionWithVpc.assets.json index 46ccbdb92..9d3046dda 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssm-deployFunctionWithVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssm-deployFunctionWithVpc.assets.json @@ -1,33 +1,33 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8": { + "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c": { "source": { - "path": "asset.0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8", + "path": "asset.a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip", + "objectKey": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "8f95c86af8d79f0ffe9d77bd33eb0e04f417321b881162418afffdd34bb9e708": { + "f3563950a06fb691c402239d4ecabd2837ec88de6f7665180ce534a09721e44a": { "source": { "path": "lamssm-deployFunctionWithVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "8f95c86af8d79f0ffe9d77bd33eb0e04f417321b881162418afffdd34bb9e708.json", + "objectKey": "f3563950a06fb691c402239d4ecabd2837ec88de6f7665180ce534a09721e44a.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssm-deployFunctionWithVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssm-deployFunctionWithVpc.template.json index f834bbe06..9dfa1d684 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssm-deployFunctionWithVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssm-deployFunctionWithVpc.template.json @@ -171,7 +171,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "S3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "Environment": { "Variables": { @@ -539,6 +539,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamssm-deployFunctionWithVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -626,7 +632,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssmdeployFunctionWithVpcIntegDefaultTestDeployAssertF3551348.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssmdeployFunctionWithVpcIntegDefaultTestDeployAssertF3551348.assets.json index afa3b5a77..1df4c467c 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssmdeployFunctionWithVpcIntegDefaultTestDeployAssertF3551348.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/lamssmdeployFunctionWithVpcIntegDefaultTestDeployAssertF3551348.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/manifest.json index c3b9504c6..38036951d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamssmdeployFunctionWithVpcIntegDefaultTestDeployAssertF3551348.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/8f95c86af8d79f0ffe9d77bd33eb0e04f417321b881162418afffdd34bb9e708.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/f3563950a06fb691c402239d4ecabd2837ec88de6f7665180ce534a09721e44a.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -196,6 +196,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamssm-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamssm-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/tree.json index 1034cdb59..945808b2d 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-ssmstringparameter/test/integ.lamssm-deployFunctionWithVpc.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamssm-deployFunctionWithVpc/test-lambda-ssmstringparameter/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -84,7 +84,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -157,19 +157,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -197,13 +197,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -219,7 +219,7 @@ "path": "lamssm-deployFunctionWithVpc/test-lambda-ssmstringparameter/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -227,13 +227,13 @@ "path": "lamssm-deployFunctionWithVpc/test-lambda-ssmstringparameter/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -246,7 +246,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "0c3255e93ffe7a906c7422e9f0e9cc4c7fd86ee996ee3bb302e2f134b38463c8.zip" + "s3Key": "a0c6248ec595d3ceec1177aa5ac5b494fdf4c66f1b88aa48086befd44f193d8c.zip" }, "environment": { "variables": { @@ -289,13 +289,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "stringParameter": { @@ -314,19 +314,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ssm.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ssm.StringParameter", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-ssmstringparameter.LambdaToSsmstringparameter", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -353,7 +353,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -397,7 +397,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -405,7 +405,7 @@ "path": "lamssm-deployFunctionWithVpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -427,7 +427,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -446,13 +446,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -496,7 +496,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -504,7 +504,7 @@ "path": "lamssm-deployFunctionWithVpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -526,7 +526,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -545,13 +545,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -563,13 +563,13 @@ "path": "lamssm-deployFunctionWithVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -585,7 +585,7 @@ "path": "lamssm-deployFunctionWithVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -616,7 +616,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -668,19 +668,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -704,13 +704,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -744,13 +744,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "SSM": { @@ -763,6 +763,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamssm-deployFunctionWithVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -800,19 +806,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -820,7 +826,7 @@ "path": "lamssm-deployFunctionWithVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -832,7 +838,7 @@ "path": "lamssm-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -840,7 +846,7 @@ "path": "lamssm-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -848,13 +854,13 @@ "path": "lamssm-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamssm-deployFunctionWithVpc-SSM-security-group": { @@ -910,13 +916,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -932,7 +938,7 @@ "path": "lamssm-deployFunctionWithVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -944,7 +950,7 @@ "path": "lamssm-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -952,25 +958,25 @@ "path": "lamssm-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -978,7 +984,7 @@ "path": "lamssm-deployFunctionWithVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -986,13 +992,13 @@ "path": "lamssm-deployFunctionWithVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1000,13 +1006,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/package.json b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/package.json index 89b0bb6ae..2e6734f19 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.013657bdb16018cbdc3923aad71a2273f9175e48c3a74e732d41248f0028fbc5/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.013657bdb16018cbdc3923aad71a2273f9175e48c3a74e732d41248f0028fbc5/index.js new file mode 100644 index 000000000..8d2499730 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.013657bdb16018cbdc3923aad71a2273f9175e48c3a74e732d41248f0028fbc5/index.js @@ -0,0 +1,31 @@ +/** + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance + * with the License. A copy of the License is located at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * or in the 'license' file accompanying this file. This file is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES + * OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions + * and limitations under the License. + */ + +const aws = require('aws-sdk'); + +console.log('Loading function'); + +exports.handler = () => { + const params = { + stateMachineArn: process.env.STATE_MACHINE_ARN, + input: JSON.stringify({}) + }; + const stepFunction = new aws.StepFunctions(); + stepFunction.startExecution(params, function (err, data) { + if (err) { + throw Error('An error occurred executing the step function.'); + } else { + console.log('Step function was successfully executed.'); + } + }) +}; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js new file mode 100644 index 000000000..8567e7388 --- /dev/null +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/__entrypoint__.js @@ -0,0 +1 @@ +"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.external=void 0,exports.handler=handler,exports.withRetries=withRetries;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js similarity index 100% rename from source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/index.js rename to source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200/index.js diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js deleted file mode 100644 index c6d62cd07..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a/__entrypoint__.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.withRetries=exports.handler=exports.external=void 0;const https=require("https"),url=require("url");exports.external={sendHttpRequest:defaultSendHttpRequest,log:defaultLog,includeStackTraces:!0,userHandlerIndex:"./index"};const CREATE_FAILED_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::CREATE_FAILED",MISSING_PHYSICAL_ID_MARKER="AWSCDK::CustomResourceProviderFramework::MISSING_PHYSICAL_ID";async function handler(event,context){const sanitizedEvent={...event,ResponseURL:"..."};if(exports.external.log(JSON.stringify(sanitizedEvent,void 0,2)),event.RequestType==="Delete"&&event.PhysicalResourceId===CREATE_FAILED_PHYSICAL_ID_MARKER){exports.external.log("ignoring DELETE event caused by a failed CREATE event"),await submitResponse("SUCCESS",event);return}try{const userHandler=require(exports.external.userHandlerIndex).handler,result=await userHandler(sanitizedEvent,context),responseEvent=renderResponse(event,result);await submitResponse("SUCCESS",responseEvent)}catch(e){const resp={...event,Reason:exports.external.includeStackTraces?e.stack:e.message};resp.PhysicalResourceId||(event.RequestType==="Create"?(exports.external.log("CREATE failed, responding with a marker physical resource id so that the subsequent DELETE will be ignored"),resp.PhysicalResourceId=CREATE_FAILED_PHYSICAL_ID_MARKER):exports.external.log(`ERROR: Malformed event. "PhysicalResourceId" is required: ${JSON.stringify(event)}`)),await submitResponse("FAILED",resp)}}exports.handler=handler;function renderResponse(cfnRequest,handlerResponse={}){const physicalResourceId=handlerResponse.PhysicalResourceId??cfnRequest.PhysicalResourceId??cfnRequest.RequestId;if(cfnRequest.RequestType==="Delete"&&physicalResourceId!==cfnRequest.PhysicalResourceId)throw new Error(`DELETE: cannot change the physical resource ID from "${cfnRequest.PhysicalResourceId}" to "${handlerResponse.PhysicalResourceId}" during deletion`);return{...cfnRequest,...handlerResponse,PhysicalResourceId:physicalResourceId}}async function submitResponse(status,event){const json={Status:status,Reason:event.Reason??status,StackId:event.StackId,RequestId:event.RequestId,PhysicalResourceId:event.PhysicalResourceId||MISSING_PHYSICAL_ID_MARKER,LogicalResourceId:event.LogicalResourceId,NoEcho:event.NoEcho,Data:event.Data},parsedUrl=url.parse(event.ResponseURL),loggingSafeUrl=`${parsedUrl.protocol}//${parsedUrl.hostname}/${parsedUrl.pathname}?***`;exports.external.log("submit response to cloudformation",loggingSafeUrl,json);const responseBody=JSON.stringify(json),req={hostname:parsedUrl.hostname,path:parsedUrl.path,method:"PUT",headers:{"content-type":"","content-length":Buffer.byteLength(responseBody,"utf8")}};await withRetries({attempts:5,sleep:1e3},exports.external.sendHttpRequest)(req,responseBody)}async function defaultSendHttpRequest(options,requestBody){return new Promise((resolve,reject)=>{try{const request=https.request(options,response=>{response.resume(),!response.statusCode||response.statusCode>=400?reject(new Error(`Unsuccessful HTTP response: ${response.statusCode}`)):resolve()});request.on("error",reject),request.write(requestBody),request.end()}catch(e){reject(e)}})}function defaultLog(fmt,...params){console.log(fmt,...params)}function withRetries(options,fn){return async(...xs)=>{let attempts=options.attempts,ms=options.sleep;for(;;)try{return await fn(...xs)}catch(e){if(attempts--<=0)throw e;await sleep(Math.floor(Math.random()*ms)),ms*=2}}}exports.withRetries=withRetries;async function sleep(ms){return new Promise(ok=>setTimeout(ok,ms))} diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.fd7a741674eeef7951675d2a57f0459376e046d88e5bee9aab601d8f5a704c93/index.js b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.fd7a741674eeef7951675d2a57f0459376e046d88e5bee9aab601d8f5a704c93/index.js deleted file mode 100644 index 2a786d862..000000000 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/asset.fd7a741674eeef7951675d2a57f0459376e046d88e5bee9aab601d8f5a704c93/index.js +++ /dev/null @@ -1,18 +0,0 @@ -const aws = require('aws-sdk'); - -console.log('Loading function'); - -exports.handler = () => { - const params = { - stateMachineArn: process.env.STATE_MACHINE_ARN, - input: JSON.stringify({}) - }; - const stepFunction = new aws.StepFunctions(); - stepFunction.startExecution(params, function (err, data) { - if (err) { - throw Error('An error occurred executing the step function.'); - } else { - console.log('Step function was successfully executed.'); - } - }) -}; \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/cdk.out b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/cdk.out index 1f0068d32..91e1a8b99 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/cdk.out +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"36.0.0"} \ No newline at end of file +{"version":"39.0.0"} \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/integ.json b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/integ.json index 3698cf110..bd1adecb1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/integ.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "testCases": { "lamstp-deployFunctionWithVpc/Integ/DefaultTest": { "stacks": [ diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstp-deployFunctionWithVpc.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstp-deployFunctionWithVpc.assets.json index 86ef5705c..73d4f4ac8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstp-deployFunctionWithVpc.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstp-deployFunctionWithVpc.assets.json @@ -1,33 +1,33 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { - "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a": { + "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200": { "source": { - "path": "asset.ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a", + "path": "asset.7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip", + "objectKey": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "fd7a741674eeef7951675d2a57f0459376e046d88e5bee9aab601d8f5a704c93": { + "013657bdb16018cbdc3923aad71a2273f9175e48c3a74e732d41248f0028fbc5": { "source": { - "path": "asset.fd7a741674eeef7951675d2a57f0459376e046d88e5bee9aab601d8f5a704c93", + "path": "asset.013657bdb16018cbdc3923aad71a2273f9175e48c3a74e732d41248f0028fbc5", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "fd7a741674eeef7951675d2a57f0459376e046d88e5bee9aab601d8f5a704c93.zip", + "objectKey": "013657bdb16018cbdc3923aad71a2273f9175e48c3a74e732d41248f0028fbc5.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "a4dfb3c004a1438aa3cfd2ed65f1056a867dd967860bb588dc560b5373da9328": { + "2d2203c058ae2e39f7bb9e6232dbcba1bf08e6885fef1814cb6f3f74bda6025f": { "source": { "path": "lamstp-deployFunctionWithVpc.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "a4dfb3c004a1438aa3cfd2ed65f1056a867dd967860bb588dc560b5373da9328.json", + "objectKey": "2d2203c058ae2e39f7bb9e6232dbcba1bf08e6885fef1814cb6f3f74bda6025f.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstp-deployFunctionWithVpc.template.json b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstp-deployFunctionWithVpc.template.json index c43516bfe..6a55cf8d6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstp-deployFunctionWithVpc.template.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstp-deployFunctionWithVpc.template.json @@ -245,6 +245,69 @@ "UpdateReplacePolicy": "Delete", "DeletionPolicy": "Delete" }, + "testlambdastepfunctionsExecutionFailedAlarm41073C3F": { + "Type": "AWS::CloudWatch::Alarm", + "Properties": { + "AlarmDescription": "Alarm for the number of executions that failed exceeded the threshold of 1. ", + "ComparisonOperator": "GreaterThanOrEqualToThreshold", + "Dimensions": [ + { + "Name": "StateMachineArn", + "Value": { + "Ref": "testlambdastepfunctionsStateMachine807F0A77" + } + } + ], + "EvaluationPeriods": 1, + "MetricName": "ExecutionsFailed", + "Namespace": "AWS/States", + "Period": 300, + "Statistic": "Sum", + "Threshold": 1 + } + }, + "testlambdastepfunctionsExecutionThrottledAlarm62EABDFD": { + "Type": "AWS::CloudWatch::Alarm", + "Properties": { + "AlarmDescription": "Alarm for the number of executions that throttled exceeded the threshold of 1. ", + "ComparisonOperator": "GreaterThanOrEqualToThreshold", + "Dimensions": [ + { + "Name": "StateMachineArn", + "Value": { + "Ref": "testlambdastepfunctionsStateMachine807F0A77" + } + } + ], + "EvaluationPeriods": 1, + "MetricName": "ExecutionThrottled", + "Namespace": "AWS/States", + "Period": 300, + "Statistic": "Sum", + "Threshold": 1 + } + }, + "testlambdastepfunctionsExecutionAbortedAlarmC9CB5C2D": { + "Type": "AWS::CloudWatch::Alarm", + "Properties": { + "AlarmDescription": "Alarm for the number of executions that aborted exceeded the threshold of 1. ", + "ComparisonOperator": "GreaterThanOrEqualToThreshold", + "Dimensions": [ + { + "Name": "StateMachineArn", + "Value": { + "Ref": "testlambdastepfunctionsStateMachine807F0A77" + } + } + ], + "EvaluationPeriods": 1, + "MetricName": "ExecutionsAborted", + "Namespace": "AWS/States", + "Period": 300, + "Statistic": "Maximum", + "Threshold": 1 + } + }, "testlambdastepfunctionsLambdaFunctionServiceRoleA33E2E9C": { "Type": "AWS::IAM::Role", "Properties": { @@ -390,7 +453,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "fd7a741674eeef7951675d2a57f0459376e046d88e5bee9aab601d8f5a704c93.zip" + "S3Key": "013657bdb16018cbdc3923aad71a2273f9175e48c3a74e732d41248f0028fbc5.zip" }, "Environment": { "Variables": { @@ -467,69 +530,6 @@ } } }, - "testlambdastepfunctionsExecutionFailedAlarm41073C3F": { - "Type": "AWS::CloudWatch::Alarm", - "Properties": { - "AlarmDescription": "Alarm for the number of executions that failed exceeded the threshold of 1. ", - "ComparisonOperator": "GreaterThanOrEqualToThreshold", - "Dimensions": [ - { - "Name": "StateMachineArn", - "Value": { - "Ref": "testlambdastepfunctionsStateMachine807F0A77" - } - } - ], - "EvaluationPeriods": 1, - "MetricName": "ExecutionsFailed", - "Namespace": "AWS/States", - "Period": 300, - "Statistic": "Sum", - "Threshold": 1 - } - }, - "testlambdastepfunctionsExecutionThrottledAlarm62EABDFD": { - "Type": "AWS::CloudWatch::Alarm", - "Properties": { - "AlarmDescription": "Alarm for the number of executions that throttled exceeded the threshold of 1. ", - "ComparisonOperator": "GreaterThanOrEqualToThreshold", - "Dimensions": [ - { - "Name": "StateMachineArn", - "Value": { - "Ref": "testlambdastepfunctionsStateMachine807F0A77" - } - } - ], - "EvaluationPeriods": 1, - "MetricName": "ExecutionThrottled", - "Namespace": "AWS/States", - "Period": 300, - "Statistic": "Sum", - "Threshold": 1 - } - }, - "testlambdastepfunctionsExecutionAbortedAlarmC9CB5C2D": { - "Type": "AWS::CloudWatch::Alarm", - "Properties": { - "AlarmDescription": "Alarm for the number of executions that aborted exceeded the threshold of 1. ", - "ComparisonOperator": "GreaterThanOrEqualToThreshold", - "Dimensions": [ - { - "Name": "StateMachineArn", - "Value": { - "Ref": "testlambdastepfunctionsStateMachine807F0A77" - } - } - ], - "EvaluationPeriods": 1, - "MetricName": "ExecutionsAborted", - "Namespace": "AWS/States", - "Period": 300, - "Statistic": "Maximum", - "Threshold": 1 - } - }, "Vpc8378EB38": { "Type": "AWS::EC2::VPC", "Properties": { @@ -826,6 +826,12 @@ "Ref": "VpcisolatedSubnet2Subnet39217055" } ], + "Tags": [ + { + "Key": "Name", + "Value": "lamstp-deployFunctionWithVpc/Vpc" + } + ], "VpcEndpointType": "Interface", "VpcId": { "Ref": "Vpc8378EB38" @@ -913,7 +919,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "ee7de53d64cc9d6248fa6aa550f92358f6c907b5efd6f3298aeab1b5e7ea358a.zip" + "S3Key": "7fa1e366ee8a9ded01fc355f704cff92bfd179574e6f9cfee800a3541df1b200.zip" }, "Timeout": 900, "MemorySize": 128, diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstpdeployFunctionWithVpcIntegDefaultTestDeployAssertAD49954F.assets.json b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstpdeployFunctionWithVpcIntegDefaultTestDeployAssertAD49954F.assets.json index 8fedb019d..1eb0f8747 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstpdeployFunctionWithVpcIntegDefaultTestDeployAssertAD49954F.assets.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/lamstpdeployFunctionWithVpcIntegDefaultTestDeployAssertAD49954F.assets.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/manifest.json b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/manifest.json index 0345eaed3..83c701568 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/manifest.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "36.0.0", + "version": "39.0.0", "artifacts": { "lamstpdeployFunctionWithVpcIntegDefaultTestDeployAssertAD49954F.assets": { "type": "cdk:asset-manifest", @@ -66,7 +66,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/a4dfb3c004a1438aa3cfd2ed65f1056a867dd967860bb588dc560b5373da9328.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/2d2203c058ae2e39f7bb9e6232dbcba1bf08e6885fef1814cb6f3f74bda6025f.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -118,46 +118,46 @@ "data": "testlambdastepfunctionsStateMachine807F0A77" } ], - "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/LambdaFunctionServiceRole/Resource": [ + "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionFailedAlarm/Resource": [ { "type": "aws:cdk:logicalId", - "data": "testlambdastepfunctionsLambdaFunctionServiceRoleA33E2E9C" + "data": "testlambdastepfunctionsExecutionFailedAlarm41073C3F" } ], - "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/LambdaFunctionServiceRole/DefaultPolicy/Resource": [ + "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionThrottledAlarm/Resource": [ { "type": "aws:cdk:logicalId", - "data": "testlambdastepfunctionsLambdaFunctionServiceRoleDefaultPolicy9746E1BE" + "data": "testlambdastepfunctionsExecutionThrottledAlarm62EABDFD" } ], - "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ReplaceDefaultSecurityGroup-security-group/Resource": [ + "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionAbortedAlarm/Resource": [ { "type": "aws:cdk:logicalId", - "data": "testlambdastepfunctionsReplaceDefaultSecurityGroupsecuritygroup3E86407A" + "data": "testlambdastepfunctionsExecutionAbortedAlarmC9CB5C2D" } ], - "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/LambdaFunction/Resource": [ + "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/LambdaFunctionServiceRole/Resource": [ { "type": "aws:cdk:logicalId", - "data": "testlambdastepfunctionsLambdaFunctionFC1F0FAE" + "data": "testlambdastepfunctionsLambdaFunctionServiceRoleA33E2E9C" } ], - "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionFailedAlarm/Resource": [ + "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/LambdaFunctionServiceRole/DefaultPolicy/Resource": [ { "type": "aws:cdk:logicalId", - "data": "testlambdastepfunctionsExecutionFailedAlarm41073C3F" + "data": "testlambdastepfunctionsLambdaFunctionServiceRoleDefaultPolicy9746E1BE" } ], - "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionThrottledAlarm/Resource": [ + "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ReplaceDefaultSecurityGroup-security-group/Resource": [ { "type": "aws:cdk:logicalId", - "data": "testlambdastepfunctionsExecutionThrottledAlarm62EABDFD" + "data": "testlambdastepfunctionsReplaceDefaultSecurityGroupsecuritygroup3E86407A" } ], - "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionAbortedAlarm/Resource": [ + "/lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/LambdaFunction/Resource": [ { "type": "aws:cdk:logicalId", - "data": "testlambdastepfunctionsExecutionAbortedAlarmC9CB5C2D" + "data": "testlambdastepfunctionsLambdaFunctionFC1F0FAE" } ], "/lamstp-deployFunctionWithVpc/Vpc/Resource": [ @@ -244,6 +244,12 @@ "data": "LatestNodeRuntimeMap" } ], + "/lamstp-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider": [ + { + "type": "aws:cdk:is-custom-resource-handler-customResourceProvider", + "data": true + } + ], "/lamstp-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role": [ { "type": "aws:cdk:logicalId", diff --git a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/tree.json b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/tree.json index 8da942937..a5a7bc4a9 100644 --- a/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/tree.json +++ b/source/patterns/@aws-solutions-constructs/aws-lambda-stepfunctions/test/integ.lamstp-deployFunctionWithVpc.js.snapshot/tree.json @@ -21,7 +21,7 @@ "path": "lamstp-deployFunctionWithVpc/lambdalamstp-test/ServiceRole/ImportServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -60,13 +60,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -90,13 +90,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" + "version": "2.174.0" } }, "tasklamstp-test": { @@ -104,7 +104,7 @@ "path": "lamstp-deployFunctionWithVpc/tasklamstp-test", "constructInfo": { "fqn": "aws-cdk-lib.aws_stepfunctions_tasks.LambdaInvoke", - "version": "2.150.0" + "version": "2.174.0" } }, "test-lambda-stepfunctions": { @@ -146,13 +146,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "StateMachine": { @@ -168,7 +168,7 @@ "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/StateMachine/Role/ImportRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -193,7 +193,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -261,19 +261,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -326,13 +326,130 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_stepfunctions.CfnStateMachine", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_stepfunctions.StateMachine", - "version": "2.150.0" + "version": "2.174.0" + } + }, + "ExecutionFailedAlarm": { + "id": "ExecutionFailedAlarm", + "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionFailedAlarm", + "children": { + "Resource": { + "id": "Resource", + "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionFailedAlarm/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::CloudWatch::Alarm", + "aws:cdk:cloudformation:props": { + "alarmDescription": "Alarm for the number of executions that failed exceeded the threshold of 1. ", + "comparisonOperator": "GreaterThanOrEqualToThreshold", + "dimensions": [ + { + "name": "StateMachineArn", + "value": { + "Ref": "testlambdastepfunctionsStateMachine807F0A77" + } + } + ], + "evaluationPeriods": 1, + "metricName": "ExecutionsFailed", + "namespace": "AWS/States", + "period": 300, + "statistic": "Sum", + "threshold": 1 + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", + "version": "2.174.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", + "version": "2.174.0" + } + }, + "ExecutionThrottledAlarm": { + "id": "ExecutionThrottledAlarm", + "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionThrottledAlarm", + "children": { + "Resource": { + "id": "Resource", + "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionThrottledAlarm/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::CloudWatch::Alarm", + "aws:cdk:cloudformation:props": { + "alarmDescription": "Alarm for the number of executions that throttled exceeded the threshold of 1. ", + "comparisonOperator": "GreaterThanOrEqualToThreshold", + "dimensions": [ + { + "name": "StateMachineArn", + "value": { + "Ref": "testlambdastepfunctionsStateMachine807F0A77" + } + } + ], + "evaluationPeriods": 1, + "metricName": "ExecutionThrottled", + "namespace": "AWS/States", + "period": 300, + "statistic": "Sum", + "threshold": 1 + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", + "version": "2.174.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", + "version": "2.174.0" + } + }, + "ExecutionAbortedAlarm": { + "id": "ExecutionAbortedAlarm", + "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionAbortedAlarm", + "children": { + "Resource": { + "id": "Resource", + "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionAbortedAlarm/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::CloudWatch::Alarm", + "aws:cdk:cloudformation:props": { + "alarmDescription": "Alarm for the number of executions that aborted exceeded the threshold of 1. ", + "comparisonOperator": "GreaterThanOrEqualToThreshold", + "dimensions": [ + { + "name": "StateMachineArn", + "value": { + "Ref": "testlambdastepfunctionsStateMachine807F0A77" + } + } + ], + "evaluationPeriods": 1, + "metricName": "ExecutionsAborted", + "namespace": "AWS/States", + "period": 300, + "statistic": "Maximum", + "threshold": 1 + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", + "version": "2.174.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", + "version": "2.174.0" } }, "LambdaFunctionServiceRole": { @@ -344,7 +461,7 @@ "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/LambdaFunctionServiceRole/ImportLambdaFunctionServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -407,7 +524,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -455,19 +572,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "ReplaceDefaultSecurityGroup-security-group": { @@ -495,13 +612,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "LambdaFunction": { @@ -517,7 +634,7 @@ "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/LambdaFunction/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "AssetBucket": { @@ -525,13 +642,13 @@ "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/LambdaFunction/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -544,7 +661,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "fd7a741674eeef7951675d2a57f0459376e046d88e5bee9aab601d8f5a704c93.zip" + "s3Key": "013657bdb16018cbdc3923aad71a2273f9175e48c3a74e732d41248f0028fbc5.zip" }, "environment": { "variables": { @@ -587,136 +704,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "2.150.0" - } - }, - "ExecutionFailedAlarm": { - "id": "ExecutionFailedAlarm", - "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionFailedAlarm", - "children": { - "Resource": { - "id": "Resource", - "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionFailedAlarm/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::CloudWatch::Alarm", - "aws:cdk:cloudformation:props": { - "alarmDescription": "Alarm for the number of executions that failed exceeded the threshold of 1. ", - "comparisonOperator": "GreaterThanOrEqualToThreshold", - "dimensions": [ - { - "name": "StateMachineArn", - "value": { - "Ref": "testlambdastepfunctionsStateMachine807F0A77" - } - } - ], - "evaluationPeriods": 1, - "metricName": "ExecutionsFailed", - "namespace": "AWS/States", - "period": 300, - "statistic": "Sum", - "threshold": 1 - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" - } - }, - "ExecutionThrottledAlarm": { - "id": "ExecutionThrottledAlarm", - "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionThrottledAlarm", - "children": { - "Resource": { - "id": "Resource", - "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionThrottledAlarm/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::CloudWatch::Alarm", - "aws:cdk:cloudformation:props": { - "alarmDescription": "Alarm for the number of executions that throttled exceeded the threshold of 1. ", - "comparisonOperator": "GreaterThanOrEqualToThreshold", - "dimensions": [ - { - "name": "StateMachineArn", - "value": { - "Ref": "testlambdastepfunctionsStateMachine807F0A77" - } - } - ], - "evaluationPeriods": 1, - "metricName": "ExecutionThrottled", - "namespace": "AWS/States", - "period": 300, - "statistic": "Sum", - "threshold": 1 - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" - } - }, - "ExecutionAbortedAlarm": { - "id": "ExecutionAbortedAlarm", - "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionAbortedAlarm", - "children": { - "Resource": { - "id": "Resource", - "path": "lamstp-deployFunctionWithVpc/test-lambda-stepfunctions/ExecutionAbortedAlarm/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::CloudWatch::Alarm", - "aws:cdk:cloudformation:props": { - "alarmDescription": "Alarm for the number of executions that aborted exceeded the threshold of 1. ", - "comparisonOperator": "GreaterThanOrEqualToThreshold", - "dimensions": [ - { - "name": "StateMachineArn", - "value": { - "Ref": "testlambdastepfunctionsStateMachine807F0A77" - } - } - ], - "evaluationPeriods": 1, - "metricName": "ExecutionsAborted", - "namespace": "AWS/States", - "period": 300, - "statistic": "Maximum", - "threshold": 1 - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_cloudwatch.CfnAlarm", - "version": "2.150.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_cloudwatch.Alarm", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-solutions-constructs/aws-lambda-stepfunctions.LambdaToStepfunctions", - "version": "2.63.0" + "version": "2.76.0" } }, "Vpc": { @@ -743,7 +743,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPC", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet1": { @@ -787,7 +787,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -795,7 +795,7 @@ "path": "lamstp-deployFunctionWithVpc/Vpc/isolatedSubnet1/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -817,7 +817,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -836,13 +836,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "isolatedSubnet2": { @@ -886,7 +886,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "Acl": { @@ -894,7 +894,7 @@ "path": "lamstp-deployFunctionWithVpc/Vpc/isolatedSubnet2/Acl", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTable": { @@ -916,7 +916,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnRouteTable", - "version": "2.150.0" + "version": "2.174.0" } }, "RouteTableAssociation": { @@ -935,13 +935,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSubnetRouteTableAssociation", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.PrivateSubnet", - "version": "2.150.0" + "version": "2.174.0" } }, "RestrictDefaultSecurityGroupCustomResource": { @@ -953,13 +953,13 @@ "path": "lamstp-deployFunctionWithVpc/Vpc/RestrictDefaultSecurityGroupCustomResource/Default", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResource", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -975,7 +975,7 @@ "path": "lamstp-deployFunctionWithVpc/Vpc/FlowLog/IAMRole/ImportIAMRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", - "version": "2.150.0" + "version": "2.174.0" } }, "Resource": { @@ -1006,7 +1006,7 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "2.150.0" + "version": "2.174.0" } }, "DefaultPolicy": { @@ -1058,19 +1058,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "2.150.0" + "version": "2.174.0" } }, "LogGroup": { @@ -1094,13 +1094,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "FlowLog": { @@ -1134,13 +1134,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnFlowLog", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.FlowLog", - "version": "2.150.0" + "version": "2.174.0" } }, "STEP_FUNCTIONS": { @@ -1153,6 +1153,12 @@ "attributes": { "aws:cdk:cloudformation:type": "AWS::EC2::VPCEndpoint", "aws:cdk:cloudformation:props": { + "tags": [ + { + "key": "Name", + "value": "lamstp-deployFunctionWithVpc/Vpc" + } + ], "privateDnsEnabled": true, "securityGroupIds": [ { @@ -1190,19 +1196,19 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnVPCEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.InterfaceVpcEndpoint", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.Vpc", - "version": "2.150.0" + "version": "2.174.0" } }, "LatestNodeRuntimeMap": { @@ -1210,7 +1216,7 @@ "path": "lamstp-deployFunctionWithVpc/LatestNodeRuntimeMap", "constructInfo": { "fqn": "aws-cdk-lib.CfnMapping", - "version": "2.150.0" + "version": "2.174.0" } }, "Custom::VpcRestrictDefaultSGCustomResourceProvider": { @@ -1222,7 +1228,7 @@ "path": "lamstp-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Staging", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", - "version": "2.150.0" + "version": "2.174.0" } }, "Role": { @@ -1230,7 +1236,7 @@ "path": "lamstp-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Role", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } }, "Handler": { @@ -1238,13 +1244,13 @@ "path": "lamstp-deployFunctionWithVpc/Custom::VpcRestrictDefaultSGCustomResourceProvider/Handler", "constructInfo": { "fqn": "aws-cdk-lib.CfnResource", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.CustomResourceProviderBase", - "version": "2.150.0" + "version": "2.174.0" } }, "lamstp-deployFunctionWithVpc-STEP_FUNCTIONS-security-group": { @@ -1300,13 +1306,13 @@ }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.aws_ec2.SecurityGroup", - "version": "2.150.0" + "version": "2.174.0" } }, "Integ": { @@ -1322,7 +1328,7 @@ "path": "lamstp-deployFunctionWithVpc/Integ/DefaultTest/Default", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } }, "DeployAssert": { @@ -1334,7 +1340,7 @@ "path": "lamstp-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1342,25 +1348,25 @@ "path": "lamstp-deployFunctionWithVpc/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } } }, "constructInfo": { "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "2.150.0-alpha.0" + "version": "2.174.0-alpha.0" } }, "BootstrapVersion": { @@ -1368,7 +1374,7 @@ "path": "lamstp-deployFunctionWithVpc/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.150.0" + "version": "2.174.0" } }, "CheckBootstrapVersion": { @@ -1376,13 +1382,13 @@ "path": "lamstp-deployFunctionWithVpc/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", - "version": "2.150.0" + "version": "2.174.0" } } }, "constructInfo": { "fqn": "aws-cdk-lib.Stack", - "version": "2.150.0" + "version": "2.174.0" } }, "Tree": { @@ -1390,13 +1396,13 @@ "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.3.0" + "version": "10.4.2" } } }, "constructInfo": { "fqn": "aws-cdk-lib.App", - "version": "2.150.0" + "version": "2.174.0" } } } \ No newline at end of file diff --git a/source/patterns/@aws-solutions-constructs/aws-openapigateway-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-openapigateway-lambda/package.json index 1454cd546..f160e68a8 100644 --- a/source/patterns/@aws-solutions-constructs/aws-openapigateway-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-openapigateway-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-route53-alb/package.json b/source/patterns/@aws-solutions-constructs/aws-route53-alb/package.json index bdea8ffad..f1d0c5022 100644 --- a/source/patterns/@aws-solutions-constructs/aws-route53-alb/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-route53-alb/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-route53-apigateway/package.json b/source/patterns/@aws-solutions-constructs/aws-route53-apigateway/package.json index 6700ac06f..192e3966f 100755 --- a/source/patterns/@aws-solutions-constructs/aws-route53-apigateway/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-route53-apigateway/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-s3-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-s3-lambda/package.json index 4bbcbb9ba..19a313ee6 100644 --- a/source/patterns/@aws-solutions-constructs/aws-s3-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-s3-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-s3-sns/package.json b/source/patterns/@aws-solutions-constructs/aws-s3-sns/package.json index b813b6e2a..d2a5bba46 100644 --- a/source/patterns/@aws-solutions-constructs/aws-s3-sns/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-s3-sns/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-s3-sqs/package.json b/source/patterns/@aws-solutions-constructs/aws-s3-sqs/package.json index 479f17a65..c39996056 100644 --- a/source/patterns/@aws-solutions-constructs/aws-s3-sqs/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-s3-sqs/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-s3-stepfunctions/package.json b/source/patterns/@aws-solutions-constructs/aws-s3-stepfunctions/package.json index 11eead5ef..53934a92b 100644 --- a/source/patterns/@aws-solutions-constructs/aws-s3-stepfunctions/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-s3-stepfunctions/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-sns-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-sns-lambda/package.json index 100f9fa4d..4aac65c58 100644 --- a/source/patterns/@aws-solutions-constructs/aws-sns-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-sns-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-sns-sqs/package.json b/source/patterns/@aws-solutions-constructs/aws-sns-sqs/package.json index ab5f90282..08c35cf30 100644 --- a/source/patterns/@aws-solutions-constructs/aws-sns-sqs/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-sns-sqs/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-sqs-lambda/package.json b/source/patterns/@aws-solutions-constructs/aws-sqs-lambda/package.json index 3eb8a96e5..7c2d84d25 100644 --- a/source/patterns/@aws-solutions-constructs/aws-sqs-lambda/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-sqs-lambda/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-sqs-pipes-stepfunctions/package.json b/source/patterns/@aws-solutions-constructs/aws-sqs-pipes-stepfunctions/package.json index 93adf438d..3bd41c698 100644 --- a/source/patterns/@aws-solutions-constructs/aws-sqs-pipes-stepfunctions/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-sqs-pipes-stepfunctions/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-wafwebacl-alb/package.json b/source/patterns/@aws-solutions-constructs/aws-wafwebacl-alb/package.json index bbe2a4540..15f28ab78 100644 --- a/source/patterns/@aws-solutions-constructs/aws-wafwebacl-alb/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-wafwebacl-alb/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-wafwebacl-apigateway/package.json b/source/patterns/@aws-solutions-constructs/aws-wafwebacl-apigateway/package.json index f0eba4313..7669d9329 100644 --- a/source/patterns/@aws-solutions-constructs/aws-wafwebacl-apigateway/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-wafwebacl-apigateway/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-wafwebacl-appsync/package.json b/source/patterns/@aws-solutions-constructs/aws-wafwebacl-appsync/package.json index aabe446ed..c0503aad1 100644 --- a/source/patterns/@aws-solutions-constructs/aws-wafwebacl-appsync/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-wafwebacl-appsync/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/aws-wafwebacl-cloudfront/package.json b/source/patterns/@aws-solutions-constructs/aws-wafwebacl-cloudfront/package.json index 30e6e31ed..5261a93e2 100644 --- a/source/patterns/@aws-solutions-constructs/aws-wafwebacl-cloudfront/package.json +++ b/source/patterns/@aws-solutions-constructs/aws-wafwebacl-cloudfront/package.json @@ -28,6 +28,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm run jsii && npm test -- -u && npm run integ-assert" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/core/lib/eventbridge-helper.ts b/source/patterns/@aws-solutions-constructs/core/lib/eventbridge-helper.ts index 819ec3bfd..09116aa4b 100644 --- a/source/patterns/@aws-solutions-constructs/core/lib/eventbridge-helper.ts +++ b/source/patterns/@aws-solutions-constructs/core/lib/eventbridge-helper.ts @@ -52,8 +52,8 @@ export function buildEventBus(scope: Construct, props: BuildEventBusProps): even } export interface EventBridgeProps { - readonly existingEventBusInterface: events.IEventBus, - readonly eventBusProps: events.EventBusProps + readonly existingEventBusInterface?: events.IEventBus, + readonly eventBusProps?: events.EventBusProps } export function CheckEventBridgeProps(propsObject: EventBridgeProps | any) { diff --git a/source/patterns/@aws-solutions-constructs/core/lib/sqs-helper.ts b/source/patterns/@aws-solutions-constructs/core/lib/sqs-helper.ts index 36ccfe629..ee3757bb1 100644 --- a/source/patterns/@aws-solutions-constructs/core/lib/sqs-helper.ts +++ b/source/patterns/@aws-solutions-constructs/core/lib/sqs-helper.ts @@ -58,7 +58,7 @@ export interface BuildQueueProps { * * @default - None */ - readonly encryptionKey?: kms.Key; + readonly encryptionKey?: kms.IKey; /** * Optional user provided properties to override the default properties for the KMS encryption key used to encrypt the SQS Queue with. * diff --git a/source/patterns/@aws-solutions-constructs/core/package.json b/source/patterns/@aws-solutions-constructs/core/package.json index 8aefdf254..0e5ac1b46 100644 --- a/source/patterns/@aws-solutions-constructs/core/package.json +++ b/source/patterns/@aws-solutions-constructs/core/package.json @@ -27,6 +27,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm test -- -u" }, "jsii": { diff --git a/source/patterns/@aws-solutions-constructs/resources/package.json b/source/patterns/@aws-solutions-constructs/resources/package.json index c2e7214e9..b033570e9 100644 --- a/source/patterns/@aws-solutions-constructs/resources/package.json +++ b/source/patterns/@aws-solutions-constructs/resources/package.json @@ -27,6 +27,7 @@ "jsii": "jsii", "jsii-pacmak": "jsii-pacmak", "build+lint+test": "npm run jsii && npm run lint && npm test && npm run integ-assert", + "blt": "npm run build+lint+test", "snapshot-update": "npm test -- -u" }, "jsii": { diff --git a/source/use_cases/aws-restaurant-management-demo/lib/lambda/service-staff/create-order/package.json b/source/use_cases/aws-restaurant-management-demo/lib/lambda/service-staff/create-order/package.json index 196518a13..4a161570e 100644 --- a/source/use_cases/aws-restaurant-management-demo/lib/lambda/service-staff/create-order/package.json +++ b/source/use_cases/aws-restaurant-management-demo/lib/lambda/service-staff/create-order/package.json @@ -10,8 +10,6 @@ "dependencies": { "uuid": "^8.3.2" }, - "peerDependencies": { - }, - "devDependencies": { - } + "peerDependencies": {}, + "devDependencies": {} } \ No newline at end of file