From 36fadef348f6aa5067f2c608c1ac785e755f5f65 Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 24 Oct 2023 16:15:24 -0400 Subject: [PATCH 01/15] create integ test from ryan sample code, without assertions yet though Signed-off-by: Sumu --- ...integ.lambda-connect-disconnect-trigget.ts | 91 +++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigget.ts diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigget.ts b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigget.ts new file mode 100644 index 0000000000000..7b2b1b3ade01c --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigget.ts @@ -0,0 +1,91 @@ +import { WebSocketApi, WebSocketStage } from '@aws-cdk/aws-apigatewayv2-alpha'; +import * as cdk from 'aws-cdk-lib'; +import { IntegTest } from '@aws-cdk/integ-tests-alpha'; +import { WebSocketLambdaIntegration } from '../../lib'; +import * as lambda from 'aws-cdk-lib/aws-lambda'; +import * as path from 'path'; +import * as dynamodb from 'aws-cdk-lib/aws-dynamodb'; + +const app = new cdk.App(); + +const stack = new cdk.Stack(app, 'aws-cdk-aws-apigatewayv2-websockets'); +const webSocketTableName = 'WebSocketConnections'; + +const connectFunction = new lambda.Function(stack, 'Connect Function', { + functionName: 'process_connect_requests', + runtime: lambda.Runtime.NODEJS_14_X, + handler: 'index.handler', + code: lambda.Code.fromAsset(path.join(__dirname, 'lambdas', 'connect')), + timeout: cdk.Duration.seconds(5), + environment: { + TABLE_NAME: webSocketTableName, + }, +}); + +const disconnectFunction = new lambda.Function( + stack, + 'Disconnect Function', + { + functionName: 'process_disconnect_requests', + runtime: lambda.Runtime.NODEJS_14_X, + handler: 'index.handler', + code: lambda.Code.fromAsset( + path.join(__dirname, 'lambdas', 'disconnect'), + ), + timeout: cdk.Duration.seconds(5), + environment: { + TABLE_NAME: webSocketTableName, + }, + } +); + +const webSocketLogTable = new dynamodb.Table(stack, 'WebSocket Log Table', { + tableName: webSocketTableName, + partitionKey: { + name: 'ConnectionId', + type: dynamodb.AttributeType.STRING, + }, + removalPolicy: cdk.RemovalPolicy.DESTROY, // not recommended for production +}); +webSocketLogTable.grantReadWriteData(connectFunction); +webSocketLogTable.grantReadWriteData(disconnectFunction); + +const webSocketConnectIntegration = new WebSocketLambdaIntegration( + 'ConnectIntegration', + connectFunction, +); +const webSocketDisconnectIntegration = new WebSocketLambdaIntegration( + 'DisconnectIntegration', + disconnectFunction, +); + +const webSocketApi = new WebSocketApi(stack, 'WebSocket API', { + apiName: 'webSocket', + routeSelectionExpression: '$request.body.action', + connectRouteOptions: { integration: webSocketConnectIntegration }, + disconnectRouteOptions: { integration: webSocketDisconnectIntegration }, +}); + +// const webSocketStage = +new WebSocketStage( + stack, + 'Production Stage', + { + webSocketApi: webSocketApi, + stageName: 'prod', + autoDeploy: true, + }, +); + +// const api = new WebSocketApi(stack, 'MyWebsocketApi'); +// api.addRoute('test', { +// integration: new WebSocketMockIntegration('SendMessageIntegration'), +// returnResponse: true, +// }); + +// const integ = +new IntegTest(app, 'Integ', { testCases: [stack] }); + +// const assertion = integ. + +// app.synth(); From 4cc11160a789762008aac0ac50b6c743a25f67a3 Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 24 Oct 2023 16:29:18 -0400 Subject: [PATCH 02/15] add lambdas folder Signed-off-by: Sumu --- .../test/websocket/lambdas/connect/package.json | 11 +++++++++++ .../test/websocket/lambdas/disconnect/package.json | 11 +++++++++++ 2 files changed, 22 insertions(+) create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/lambdas/connect/package.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/lambdas/disconnect/package.json diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/lambdas/connect/package.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/lambdas/connect/package.json new file mode 100644 index 0000000000000..941efba0e8117 --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/lambdas/connect/package.json @@ -0,0 +1,11 @@ +{ + "name": "connect", + "version": "1.0.0", + "description": "connect example for WebSockets on API Gateway", + "main": "index.js", + "author": "SAM CLI", + "license": "MIT", + "dependencies": { + "aws-sdk": "^2.690.0" + } +} diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/lambdas/disconnect/package.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/lambdas/disconnect/package.json new file mode 100644 index 0000000000000..f7f07857f72ea --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/lambdas/disconnect/package.json @@ -0,0 +1,11 @@ +{ + "name": "disconnect", + "version": "1.0.0", + "description": "disconnect example for WebSockets on API Gateway", + "main": "index.js", + "author": "SAM CLI", + "license": "MIT", + "dependencies": { + "aws-sdk": "^2.690.0" + } +} From b0bf397973f5e26579bb921b742ae79703dca46b Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 24 Oct 2023 16:29:53 -0400 Subject: [PATCH 03/15] rename typo integ test file Signed-off-by: Sumu --- ...ct-trigget.ts => integ.lambda-connect-disconnect-trigger.ts} | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/{integ.lambda-connect-disconnect-trigget.ts => integ.lambda-connect-disconnect-trigger.ts} (99%) diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigget.ts b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts similarity index 99% rename from packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigget.ts rename to packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts index 7b2b1b3ade01c..99e1d837ba67f 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigget.ts +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts @@ -83,7 +83,7 @@ new WebSocketStage( // returnResponse: true, // }); -// const integ = +// const integ = new IntegTest(app, 'Integ', { testCases: [stack] }); // const assertion = integ. From 51fae3845279577d83c88aa55c07eebddc891d0e Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 24 Oct 2023 16:45:26 -0400 Subject: [PATCH 04/15] cleanup integ test case Signed-off-by: Sumu --- .../integ.lambda-connect-disconnect-trigger.ts | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts index 99e1d837ba67f..cac4a3063e870 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts @@ -8,7 +8,7 @@ import * as dynamodb from 'aws-cdk-lib/aws-dynamodb'; const app = new cdk.App(); -const stack = new cdk.Stack(app, 'aws-cdk-aws-apigatewayv2-websockets'); +const stack = new cdk.Stack(app, 'integ-apigwv2-lambda-connect-integration'); const webSocketTableName = 'WebSocketConnections'; const connectFunction = new lambda.Function(stack, 'Connect Function', { @@ -36,7 +36,7 @@ const disconnectFunction = new lambda.Function( environment: { TABLE_NAME: webSocketTableName, }, - } + }, ); const webSocketLogTable = new dynamodb.Table(stack, 'WebSocket Log Table', { @@ -66,7 +66,6 @@ const webSocketApi = new WebSocketApi(stack, 'WebSocket API', { disconnectRouteOptions: { integration: webSocketDisconnectIntegration }, }); -// const webSocketStage = new WebSocketStage( stack, 'Production Stage', @@ -77,12 +76,6 @@ new WebSocketStage( }, ); -// const api = new WebSocketApi(stack, 'MyWebsocketApi'); -// api.addRoute('test', { -// integration: new WebSocketMockIntegration('SendMessageIntegration'), -// returnResponse: true, -// }); - // const integ = new IntegTest(app, 'Integ', { testCases: [stack] }); From d04233d9ead4ed834edfcec8a4e8cf1619cf1029 Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 24 Oct 2023 17:16:06 -0400 Subject: [PATCH 05/15] add integ assertion, although it is not working yet - need to figure out how to get RouteId for apiCall Signed-off-by: Sumu --- ...integ.lambda-connect-disconnect-trigger.ts | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts index cac4a3063e870..da7068c1ff36a 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts @@ -1,6 +1,6 @@ import { WebSocketApi, WebSocketStage } from '@aws-cdk/aws-apigatewayv2-alpha'; import * as cdk from 'aws-cdk-lib'; -import { IntegTest } from '@aws-cdk/integ-tests-alpha'; +import { IntegTest, ExpectedResult } from '@aws-cdk/integ-tests-alpha'; import { WebSocketLambdaIntegration } from '../../lib'; import * as lambda from 'aws-cdk-lib/aws-lambda'; import * as path from 'path'; @@ -76,8 +76,21 @@ new WebSocketStage( }, ); -// const integ = -new IntegTest(app, 'Integ', { testCases: [stack] }); +const integ = new IntegTest(app, 'Integ', { testCases: [stack] }); + +const apiCall = integ.assertions.awsApiCall('ApiGatewayV2', 'getRoute', { + ApiId: `${webSocketApi.apiId}`, /* required */ + RouteId: '$connect-Route', /* required */ + // RouteResponseId: 'body', /* required */ +}); + +apiCall.provider.addToRolePolicy({ + Effect: 'Allow', + Action: ['apigateway:GET'], + Resource: ['*'], +}); + +apiCall.assertAtPath('Body', ExpectedResult.stringLikeRegexp('Connected.')); // const assertion = integ. From a6eb9dcf4ff828625623af8e16a7f6502d69af09 Mon Sep 17 00:00:00 2001 From: Sumu Date: Wed, 25 Oct 2023 11:56:29 -0400 Subject: [PATCH 06/15] temporarily make assertion 'getRoutes' Signed-off-by: Sumu --- .../integ.lambda-connect-disconnect-trigger.ts | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts index da7068c1ff36a..dbeb5f8b5f9f1 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts @@ -78,11 +78,14 @@ new WebSocketStage( const integ = new IntegTest(app, 'Integ', { testCases: [stack] }); -const apiCall = integ.assertions.awsApiCall('ApiGatewayV2', 'getRoute', { +const apiCall = integ.assertions.awsApiCall('ApiGatewayV2', 'getRoutes', { ApiId: `${webSocketApi.apiId}`, /* required */ - RouteId: '$connect-Route', /* required */ + // RouteId: '$connect-Route', /* required */ // RouteResponseId: 'body', /* required */ }); +// .next( +// integ.assertions.awsApiCall('Response', 'send'), +// ); apiCall.provider.addToRolePolicy({ Effect: 'Allow', @@ -90,7 +93,13 @@ apiCall.provider.addToRolePolicy({ Resource: ['*'], }); -apiCall.assertAtPath('Body', ExpectedResult.stringLikeRegexp('Connected.')); +// const nextCall = integ.assertions.awsApiCall('AWS', 'send') + +// apiCall.next( +// integ.assertions.awsApiCall('AWS', 'Request.Send'), +// ); + +apiCall.assertAtPath('AWS.Response.send()', ExpectedResult.stringLikeRegexp('Connected.')); // const assertion = integ. From 35a43f0157c135d29fe11b510f716fe56c384d1b Mon Sep 17 00:00:00 2001 From: Sumu Date: Fri, 27 Oct 2023 14:19:15 -0400 Subject: [PATCH 07/15] remove /* from lambda permission resource name Signed-off-by: Sumu --- .../aws-apigatewayv2-integrations-alpha/lib/websocket/lambda.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/lib/websocket/lambda.ts b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/lib/websocket/lambda.ts index 9306ef7dc0e7a..e57068e90e1b3 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/lib/websocket/lambda.ts +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/lib/websocket/lambda.ts @@ -33,7 +33,7 @@ export class WebSocketLambdaIntegration extends WebSocketRouteIntegration { sourceArn: Stack.of(route).formatArn({ service: 'execute-api', resource: route.webSocketApi.apiId, - resourceName: `*/*${route.routeKey}`, + resourceName: `*${route.routeKey}`, }), }); From 480ad728ec46d49f5fbf03a9c124ebae13ae1b0b Mon Sep 17 00:00:00 2001 From: Sumu Date: Fri, 27 Oct 2023 14:46:43 -0400 Subject: [PATCH 08/15] remove integ assertion, cannot find a way to test this Signed-off-by: Sumu --- ...integ.lambda-connect-disconnect-trigger.ts | 32 +------------------ 1 file changed, 1 insertion(+), 31 deletions(-) diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts index dbeb5f8b5f9f1..cf4a7ac538727 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts @@ -1,6 +1,5 @@ import { WebSocketApi, WebSocketStage } from '@aws-cdk/aws-apigatewayv2-alpha'; import * as cdk from 'aws-cdk-lib'; -import { IntegTest, ExpectedResult } from '@aws-cdk/integ-tests-alpha'; import { WebSocketLambdaIntegration } from '../../lib'; import * as lambda from 'aws-cdk-lib/aws-lambda'; import * as path from 'path'; @@ -74,33 +73,4 @@ new WebSocketStage( stageName: 'prod', autoDeploy: true, }, -); - -const integ = new IntegTest(app, 'Integ', { testCases: [stack] }); - -const apiCall = integ.assertions.awsApiCall('ApiGatewayV2', 'getRoutes', { - ApiId: `${webSocketApi.apiId}`, /* required */ - // RouteId: '$connect-Route', /* required */ - // RouteResponseId: 'body', /* required */ -}); -// .next( -// integ.assertions.awsApiCall('Response', 'send'), -// ); - -apiCall.provider.addToRolePolicy({ - Effect: 'Allow', - Action: ['apigateway:GET'], - Resource: ['*'], -}); - -// const nextCall = integ.assertions.awsApiCall('AWS', 'send') - -// apiCall.next( -// integ.assertions.awsApiCall('AWS', 'Request.Send'), -// ); - -apiCall.assertAtPath('AWS.Response.send()', ExpectedResult.stringLikeRegexp('Connected.')); - -// const assertion = integ. - -// app.synth(); +); \ No newline at end of file From cedb1a80fbcb5cd2779da16ffaf84b9406c856ef Mon Sep 17 00:00:00 2001 From: Sumu Date: Mon, 30 Oct 2023 13:35:50 -0400 Subject: [PATCH 09/15] update integ snapshots Signed-off-by: Sumu --- .../IntegApiGatewayV2Iam.assets.json | 4 +- .../IntegApiGatewayV2Iam.template.json | 2 +- .../integ.iam.js.snapshot/manifest.json | 9 +- .../websocket/integ.iam.js.snapshot/tree.json | 2 +- ...efaultTestDeployAssert4E6713E1.assets.json | 19 + ...aultTestDeployAssert4E6713E1.template.json | 36 + .../index.js | 32 + .../package.json | 11 + .../index.js | 26 + .../package.json | 11 + ...dk-aws-apigatewayv2-websockets.assets.json | 45 + ...-aws-apigatewayv2-websockets.template.json | 470 ++++++++++ .../cdk.out | 1 + .../integ.json | 12 + .../manifest.json | 205 +++++ .../tree.json | 849 ++++++++++++++++++ .../WebSocketApiInteg.assets.json | 4 +- .../WebSocketApiInteg.template.json | 8 +- .../integ.lambda.js.snapshot/manifest.json | 23 +- .../integ.lambda.js.snapshot/tree.json | 8 +- 20 files changed, 1756 insertions(+), 21 deletions(-) create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/index.js create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/package.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/index.js create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/package.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.assets.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.template.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/cdk.out create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json index acfbbfa7a6875..4ab5619801629 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "89f3eb281075e38df0df45fd2cf30f90cd7bbaabddef614ebee1040631c2a0c6": { + "0fecdddcc93cb59f37820c43eaa8030e35f0be824e2f8e7b63bde0bb0b24e264": { "source": { "path": "IntegApiGatewayV2Iam.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "89f3eb281075e38df0df45fd2cf30f90cd7bbaabddef614ebee1040631c2a0c6.json", + "objectKey": "0fecdddcc93cb59f37820c43eaa8030e35f0be824e2f8e7b63bde0bb0b24e264.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json index ec0283f3bd2bd..5e3e47d97b6cf 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json @@ -100,7 +100,7 @@ { "Ref": "WebSocketApi34BCF99B" }, - "/*/*$connect" + "/*$connect" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json index 529e868fc518c..5cd819d527b7b 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json @@ -14,10 +14,11 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "IntegApiGatewayV2Iam.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}/89f3eb281075e38df0df45fd2cf30f90cd7bbaabddef614ebee1040631c2a0c6.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/0fecdddcc93cb59f37820c43eaa8030e35f0be824e2f8e7b63bde0bb0b24e264.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -66,7 +67,10 @@ "/IntegApiGatewayV2Iam/WebSocketApi/$connect-Route/WebSocketLambdaIntegration-Permission": [ { "type": "aws:cdk:logicalId", - "data": "WebSocketApiconnectRouteWebSocketLambdaIntegrationPermission76CD86C6" + "data": "WebSocketApiconnectRouteWebSocketLambdaIntegrationPermission76CD86C6", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_REPLACE" + ] } ], "/IntegApiGatewayV2Iam/WebSocketApi/$connect-Route/WebSocketLambdaIntegration/Resource": [ @@ -133,6 +137,7 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "ApiGatewayV2WebSocketIamTestDefaultTestDeployAssert2B412D7B.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}", diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json index 3aeaca1832db8..2192187ed14af 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json @@ -205,7 +205,7 @@ { "Ref": "WebSocketApi34BCF99B" }, - "/*/*$connect" + "/*$connect" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json new file mode 100644 index 0000000000000..618513371ae9f --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json @@ -0,0 +1,19 @@ +{ + "version": "34.0.0", + "files": { + "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { + "source": { + "path": "IntegDefaultTestDeployAssert4E6713E1.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/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json new file mode 100644 index 0000000000000..ad9d0fb73d1dd --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.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/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/index.js b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/index.js new file mode 100644 index 0000000000000..9b5dbf88ff1fd --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/index.js @@ -0,0 +1,32 @@ +// https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-websocket-api-route-keys-connect-disconnect.html +// The $disconnect route is executed after the connection is closed. +// The connection can be closed by the server or by the client. As the connection is already closed when it is executed, +// $disconnect is a best-effort event. +// API Gateway will try its best to deliver the $disconnect event to your integration, but it cannot guarantee delivery. + +const AWS = require("aws-sdk"); + +const ddb = new AWS.DynamoDB.DocumentClient({ + apiVersion: "2012-08-10", + region: process.env.AWS_REGION, +}); + +exports.handler = async (event) => { + const deleteParams = { + TableName: process.env.TABLE_NAME, + Key: { + connectionId: event.requestContext.connectionId, + }, + }; + + try { + await ddb.delete(deleteParams).promise(); + } catch (err) { + return { + statusCode: 500, + body: "Failed to disconnect: " + JSON.stringify(err), + }; + } + + return { statusCode: 200, body: "Disconnected." }; +}; diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/package.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/package.json new file mode 100644 index 0000000000000..f7f07857f72ea --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/package.json @@ -0,0 +1,11 @@ +{ + "name": "disconnect", + "version": "1.0.0", + "description": "disconnect example for WebSockets on API Gateway", + "main": "index.js", + "author": "SAM CLI", + "license": "MIT", + "dependencies": { + "aws-sdk": "^2.690.0" + } +} diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/index.js b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/index.js new file mode 100644 index 0000000000000..0b30c8c3cb950 --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/index.js @@ -0,0 +1,26 @@ +const AWS = require("aws-sdk"); + +const ddb = new AWS.DynamoDB.DocumentClient({ + apiVersion: "2012-08-10", + region: process.env.AWS_REGION, +}); + +exports.handler = async (event) => { + const putParams = { + TableName: process.env.TABLE_NAME, + Item: { + connectionId: event.requestContext.connectionId, + }, + }; + + try { + await ddb.put(putParams).promise(); + } catch (err) { + return { + statusCode: 500, + body: "Failed to connect: " + JSON.stringify(err), + }; + } + + return { statusCode: 200, body: "Connected." }; +}; diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/package.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/package.json new file mode 100644 index 0000000000000..941efba0e8117 --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/package.json @@ -0,0 +1,11 @@ +{ + "name": "connect", + "version": "1.0.0", + "description": "connect example for WebSockets on API Gateway", + "main": "index.js", + "author": "SAM CLI", + "license": "MIT", + "dependencies": { + "aws-sdk": "^2.690.0" + } +} diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.assets.json new file mode 100644 index 0000000000000..207103c9ade6f --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.assets.json @@ -0,0 +1,45 @@ +{ + "version": "34.0.0", + "files": { + "f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07": { + "source": { + "path": "asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07", + "packaging": "zip" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07.zip", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + }, + "48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c": { + "source": { + "path": "asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c", + "packaging": "zip" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c.zip", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + }, + "78326e78ff76a1ed4538fd2d47129266d95b8c304857736753ec3afa4250d787": { + "source": { + "path": "aws-cdk-aws-apigatewayv2-websockets.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "78326e78ff76a1ed4538fd2d47129266d95b8c304857736753ec3afa4250d787.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/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.template.json new file mode 100644 index 0000000000000..9dfaa75f03a57 --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.template.json @@ -0,0 +1,470 @@ +{ + "Resources": { + "ConnectFunctionServiceRoleDD1EAA8C": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "lambda.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "ManagedPolicyArns": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" + ] + ] + } + ] + } + }, + "ConnectFunctionServiceRoleDefaultPolicy9C1FE0B3": { + "Type": "AWS::IAM::Policy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "dynamodb:BatchGetItem", + "dynamodb:BatchWriteItem", + "dynamodb:ConditionCheckItem", + "dynamodb:DeleteItem", + "dynamodb:DescribeTable", + "dynamodb:GetItem", + "dynamodb:GetRecords", + "dynamodb:GetShardIterator", + "dynamodb:PutItem", + "dynamodb:Query", + "dynamodb:Scan", + "dynamodb:UpdateItem" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "WebSocketLogTable7F74AAC5", + "Arn" + ] + }, + { + "Ref": "AWS::NoValue" + } + ] + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "ConnectFunctionServiceRoleDefaultPolicy9C1FE0B3", + "Roles": [ + { + "Ref": "ConnectFunctionServiceRoleDD1EAA8C" + } + ] + } + }, + "ConnectFunction4D4B4BB5": { + "Type": "AWS::Lambda::Function", + "Properties": { + "Code": { + "S3Bucket": { + "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" + }, + "S3Key": "f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07.zip" + }, + "Environment": { + "Variables": { + "TABLE_NAME": "WebSocketConnections" + } + }, + "FunctionName": "process_connect_requests", + "Handler": "index.handler", + "Role": { + "Fn::GetAtt": [ + "ConnectFunctionServiceRoleDD1EAA8C", + "Arn" + ] + }, + "Runtime": "nodejs14.x", + "Timeout": 5 + }, + "DependsOn": [ + "ConnectFunctionServiceRoleDefaultPolicy9C1FE0B3", + "ConnectFunctionServiceRoleDD1EAA8C" + ] + }, + "DisconnectFunctionServiceRole49DB60AC": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "lambda.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "ManagedPolicyArns": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" + ] + ] + } + ] + } + }, + "DisconnectFunctionServiceRoleDefaultPolicyF5348EC3": { + "Type": "AWS::IAM::Policy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "dynamodb:BatchGetItem", + "dynamodb:BatchWriteItem", + "dynamodb:ConditionCheckItem", + "dynamodb:DeleteItem", + "dynamodb:DescribeTable", + "dynamodb:GetItem", + "dynamodb:GetRecords", + "dynamodb:GetShardIterator", + "dynamodb:PutItem", + "dynamodb:Query", + "dynamodb:Scan", + "dynamodb:UpdateItem" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "WebSocketLogTable7F74AAC5", + "Arn" + ] + }, + { + "Ref": "AWS::NoValue" + } + ] + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "DisconnectFunctionServiceRoleDefaultPolicyF5348EC3", + "Roles": [ + { + "Ref": "DisconnectFunctionServiceRole49DB60AC" + } + ] + } + }, + "DisconnectFunction620A9610": { + "Type": "AWS::Lambda::Function", + "Properties": { + "Code": { + "S3Bucket": { + "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" + }, + "S3Key": "48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c.zip" + }, + "Environment": { + "Variables": { + "TABLE_NAME": "WebSocketConnections" + } + }, + "FunctionName": "process_disconnect_requests", + "Handler": "index.handler", + "Role": { + "Fn::GetAtt": [ + "DisconnectFunctionServiceRole49DB60AC", + "Arn" + ] + }, + "Runtime": "nodejs14.x", + "Timeout": 5 + }, + "DependsOn": [ + "DisconnectFunctionServiceRoleDefaultPolicyF5348EC3", + "DisconnectFunctionServiceRole49DB60AC" + ] + }, + "WebSocketLogTable7F74AAC5": { + "Type": "AWS::DynamoDB::Table", + "Properties": { + "AttributeDefinitions": [ + { + "AttributeName": "ConnectionId", + "AttributeType": "S" + } + ], + "KeySchema": [ + { + "AttributeName": "ConnectionId", + "KeyType": "HASH" + } + ], + "ProvisionedThroughput": { + "ReadCapacityUnits": 5, + "WriteCapacityUnits": 5 + }, + "TableName": "WebSocketConnections" + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "WebSocketAPIDA75128A": { + "Type": "AWS::ApiGatewayV2::Api", + "Properties": { + "Name": "webSocket", + "ProtocolType": "WEBSOCKET", + "RouteSelectionExpression": "$request.body.action" + } + }, + "WebSocketAPIconnectRouteConnectIntegrationPermission1FECDE58": { + "Type": "AWS::Lambda::Permission", + "Properties": { + "Action": "lambda:InvokeFunction", + "FunctionName": { + "Fn::GetAtt": [ + "ConnectFunction4D4B4BB5", + "Arn" + ] + }, + "Principal": "apigateway.amazonaws.com", + "SourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "WebSocketAPIDA75128A" + }, + "/*$connect" + ] + ] + } + } + }, + "WebSocketAPIconnectRouteConnectIntegration2725692A": { + "Type": "AWS::ApiGatewayV2::Integration", + "Properties": { + "ApiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "IntegrationType": "AWS_PROXY", + "IntegrationUri": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":apigateway:", + { + "Ref": "AWS::Region" + }, + ":lambda:path/2015-03-31/functions/", + { + "Fn::GetAtt": [ + "ConnectFunction4D4B4BB5", + "Arn" + ] + }, + "/invocations" + ] + ] + } + } + }, + "WebSocketAPIconnectRoute4BD84FCF": { + "Type": "AWS::ApiGatewayV2::Route", + "Properties": { + "ApiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "AuthorizationType": "NONE", + "RouteKey": "$connect", + "Target": { + "Fn::Join": [ + "", + [ + "integrations/", + { + "Ref": "WebSocketAPIconnectRouteConnectIntegration2725692A" + } + ] + ] + } + } + }, + "WebSocketAPIdisconnectRouteDisconnectIntegrationPermission909CCDD8": { + "Type": "AWS::Lambda::Permission", + "Properties": { + "Action": "lambda:InvokeFunction", + "FunctionName": { + "Fn::GetAtt": [ + "DisconnectFunction620A9610", + "Arn" + ] + }, + "Principal": "apigateway.amazonaws.com", + "SourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "WebSocketAPIDA75128A" + }, + "/*$disconnect" + ] + ] + } + } + }, + "WebSocketAPIdisconnectRouteDisconnectIntegration317B9227": { + "Type": "AWS::ApiGatewayV2::Integration", + "Properties": { + "ApiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "IntegrationType": "AWS_PROXY", + "IntegrationUri": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":apigateway:", + { + "Ref": "AWS::Region" + }, + ":lambda:path/2015-03-31/functions/", + { + "Fn::GetAtt": [ + "DisconnectFunction620A9610", + "Arn" + ] + }, + "/invocations" + ] + ] + } + } + }, + "WebSocketAPIdisconnectRouteBC1A3C36": { + "Type": "AWS::ApiGatewayV2::Route", + "Properties": { + "ApiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "AuthorizationType": "NONE", + "RouteKey": "$disconnect", + "Target": { + "Fn::Join": [ + "", + [ + "integrations/", + { + "Ref": "WebSocketAPIdisconnectRouteDisconnectIntegration317B9227" + } + ] + ] + } + } + }, + "ProductionStage7933AAB2": { + "Type": "AWS::ApiGatewayV2::Stage", + "Properties": { + "ApiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "AutoDeploy": true, + "StageName": "prod" + } + } + }, + "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/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/cdk.out b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/cdk.out new file mode 100644 index 0000000000000..2313ab5436501 --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/cdk.out @@ -0,0 +1 @@ +{"version":"34.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json new file mode 100644 index 0000000000000..fbc76a6cecbdf --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json @@ -0,0 +1,12 @@ +{ + "version": "34.0.0", + "testCases": { + "Integ/DefaultTest": { + "stacks": [ + "aws-cdk-aws-apigatewayv2-websockets" + ], + "assertionStack": "Integ/DefaultTest/DeployAssert", + "assertionStackName": "IntegDefaultTestDeployAssert4E6713E1" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json new file mode 100644 index 0000000000000..6cc579857a94b --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json @@ -0,0 +1,205 @@ +{ + "version": "34.0.0", + "artifacts": { + "aws-cdk-aws-apigatewayv2-websockets.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "aws-cdk-aws-apigatewayv2-websockets.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "aws-cdk-aws-apigatewayv2-websockets": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "aws-cdk-aws-apigatewayv2-websockets.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}/78326e78ff76a1ed4538fd2d47129266d95b8c304857736753ec3afa4250d787.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "aws-cdk-aws-apigatewayv2-websockets.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": [ + "aws-cdk-aws-apigatewayv2-websockets.assets" + ], + "metadata": { + "/aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "ConnectFunctionServiceRoleDD1EAA8C" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "ConnectFunctionServiceRoleDefaultPolicy9C1FE0B3" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/Connect Function/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "ConnectFunction4D4B4BB5" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "DisconnectFunctionServiceRole49DB60AC" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "DisconnectFunctionServiceRoleDefaultPolicyF5348EC3" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "DisconnectFunction620A9610" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table": [ + { + "type": "aws:cdk:hasPhysicalName", + "data": { + "Ref": "WebSocketLogTable7F74AAC5" + } + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "WebSocketLogTable7F74AAC5" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "WebSocketAPIDA75128A" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration-Permission": [ + { + "type": "aws:cdk:logicalId", + "data": "WebSocketAPIconnectRouteConnectIntegrationPermission1FECDE58" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "WebSocketAPIconnectRouteConnectIntegration2725692A" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "WebSocketAPIconnectRoute4BD84FCF" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration-Permission": [ + { + "type": "aws:cdk:logicalId", + "data": "WebSocketAPIdisconnectRouteDisconnectIntegrationPermission909CCDD8" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "WebSocketAPIdisconnectRouteDisconnectIntegration317B9227" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "WebSocketAPIdisconnectRouteBC1A3C36" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/Production Stage/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "ProductionStage7933AAB2" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/aws-cdk-aws-apigatewayv2-websockets/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "aws-cdk-aws-apigatewayv2-websockets" + }, + "IntegDefaultTestDeployAssert4E6713E1.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "IntegDefaultTestDeployAssert4E6713E1.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "IntegDefaultTestDeployAssert4E6713E1": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "IntegDefaultTestDeployAssert4E6713E1.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": [ + "IntegDefaultTestDeployAssert4E6713E1.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": [ + "IntegDefaultTestDeployAssert4E6713E1.assets" + ], + "metadata": { + "/Integ/DefaultTest/DeployAssert/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "Integ/DefaultTest/DeployAssert" + }, + "Tree": { + "type": "cdk:tree", + "properties": { + "file": "tree.json" + } + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json new file mode 100644 index 0000000000000..320d1439c9ab2 --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json @@ -0,0 +1,849 @@ +{ + "version": "tree-0.1", + "tree": { + "id": "App", + "path": "", + "children": { + "aws-cdk-aws-apigatewayv2-websockets": { + "id": "aws-cdk-aws-apigatewayv2-websockets", + "path": "aws-cdk-aws-apigatewayv2-websockets", + "children": { + "Connect Function": { + "id": "Connect Function", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function", + "children": { + "ServiceRole": { + "id": "ServiceRole", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole", + "children": { + "ImportServiceRole": { + "id": "ImportServiceRole", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/ImportServiceRole", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/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" + }, + "managedPolicyArns": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" + ] + ] + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" + } + }, + "DefaultPolicy": { + "id": "DefaultPolicy", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/DefaultPolicy", + "children": { + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/DefaultPolicy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Policy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "dynamodb:BatchGetItem", + "dynamodb:BatchWriteItem", + "dynamodb:ConditionCheckItem", + "dynamodb:DeleteItem", + "dynamodb:DescribeTable", + "dynamodb:GetItem", + "dynamodb:GetRecords", + "dynamodb:GetShardIterator", + "dynamodb:PutItem", + "dynamodb:Query", + "dynamodb:Scan", + "dynamodb:UpdateItem" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "WebSocketLogTable7F74AAC5", + "Arn" + ] + }, + { + "Ref": "AWS::NoValue" + } + ] + } + ], + "Version": "2012-10-17" + }, + "policyName": "ConnectFunctionServiceRoleDefaultPolicy9C1FE0B3", + "roles": [ + { + "Ref": "ConnectFunctionServiceRoleDD1EAA8C" + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Policy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" + } + }, + "Code": { + "id": "Code", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/Code", + "children": { + "Stage": { + "id": "Stage", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/Code/Stage", + "constructInfo": { + "fqn": "aws-cdk-lib.AssetStaging", + "version": "0.0.0" + } + }, + "AssetBucket": { + "id": "AssetBucket", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/Code/AssetBucket", + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.BucketBase", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3_assets.Asset", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/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": "f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07.zip" + }, + "environment": { + "variables": { + "TABLE_NAME": "WebSocketConnections" + } + }, + "functionName": "process_connect_requests", + "handler": "index.handler", + "role": { + "Fn::GetAtt": [ + "ConnectFunctionServiceRoleDD1EAA8C", + "Arn" + ] + }, + "runtime": "nodejs14.x", + "timeout": 5 + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.Function", + "version": "0.0.0" + } + }, + "Disconnect Function": { + "id": "Disconnect Function", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function", + "children": { + "ServiceRole": { + "id": "ServiceRole", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole", + "children": { + "ImportServiceRole": { + "id": "ImportServiceRole", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/ImportServiceRole", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/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" + }, + "managedPolicyArns": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" + ] + ] + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" + } + }, + "DefaultPolicy": { + "id": "DefaultPolicy", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/DefaultPolicy", + "children": { + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/DefaultPolicy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Policy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "dynamodb:BatchGetItem", + "dynamodb:BatchWriteItem", + "dynamodb:ConditionCheckItem", + "dynamodb:DeleteItem", + "dynamodb:DescribeTable", + "dynamodb:GetItem", + "dynamodb:GetRecords", + "dynamodb:GetShardIterator", + "dynamodb:PutItem", + "dynamodb:Query", + "dynamodb:Scan", + "dynamodb:UpdateItem" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "WebSocketLogTable7F74AAC5", + "Arn" + ] + }, + { + "Ref": "AWS::NoValue" + } + ] + } + ], + "Version": "2012-10-17" + }, + "policyName": "DisconnectFunctionServiceRoleDefaultPolicyF5348EC3", + "roles": [ + { + "Ref": "DisconnectFunctionServiceRole49DB60AC" + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Policy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" + } + }, + "Code": { + "id": "Code", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/Code", + "children": { + "Stage": { + "id": "Stage", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/Code/Stage", + "constructInfo": { + "fqn": "aws-cdk-lib.AssetStaging", + "version": "0.0.0" + } + }, + "AssetBucket": { + "id": "AssetBucket", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/Code/AssetBucket", + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.BucketBase", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3_assets.Asset", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/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": "48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c.zip" + }, + "environment": { + "variables": { + "TABLE_NAME": "WebSocketConnections" + } + }, + "functionName": "process_disconnect_requests", + "handler": "index.handler", + "role": { + "Fn::GetAtt": [ + "DisconnectFunctionServiceRole49DB60AC", + "Arn" + ] + }, + "runtime": "nodejs14.x", + "timeout": 5 + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.Function", + "version": "0.0.0" + } + }, + "WebSocket Log Table": { + "id": "WebSocket Log Table", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table", + "children": { + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::DynamoDB::Table", + "aws:cdk:cloudformation:props": { + "attributeDefinitions": [ + { + "attributeName": "ConnectionId", + "attributeType": "S" + } + ], + "keySchema": [ + { + "attributeName": "ConnectionId", + "keyType": "HASH" + } + ], + "provisionedThroughput": { + "readCapacityUnits": 5, + "writeCapacityUnits": 5 + }, + "tableName": "WebSocketConnections" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_dynamodb.CfnTable", + "version": "0.0.0" + } + }, + "ScalingRole": { + "id": "ScalingRole", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table/ScalingRole", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_dynamodb.Table", + "version": "0.0.0" + } + }, + "WebSocket API": { + "id": "WebSocket API", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API", + "children": { + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Api", + "aws:cdk:cloudformation:props": { + "name": "webSocket", + "protocolType": "WEBSOCKET", + "routeSelectionExpression": "$request.body.action" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnApi", + "version": "0.0.0" + } + }, + "$connect-Route": { + "id": "$connect-Route", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route", + "children": { + "ConnectIntegration-Permission": { + "id": "ConnectIntegration-Permission", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration-Permission", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", + "aws:cdk:cloudformation:props": { + "action": "lambda:InvokeFunction", + "functionName": { + "Fn::GetAtt": [ + "ConnectFunction4D4B4BB5", + "Arn" + ] + }, + "principal": "apigateway.amazonaws.com", + "sourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "WebSocketAPIDA75128A" + }, + "/*$connect" + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.CfnPermission", + "version": "0.0.0" + } + }, + "ConnectIntegration": { + "id": "ConnectIntegration", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration", + "children": { + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Integration", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "integrationType": "AWS_PROXY", + "integrationUri": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":apigateway:", + { + "Ref": "AWS::Region" + }, + ":lambda:path/2015-03-31/functions/", + { + "Fn::GetAtt": [ + "ConnectFunction4D4B4BB5", + "Arn" + ] + }, + "/invocations" + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnIntegration", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.WebSocketIntegration", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Route", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "authorizationType": "NONE", + "routeKey": "$connect", + "target": { + "Fn::Join": [ + "", + [ + "integrations/", + { + "Ref": "WebSocketAPIconnectRouteConnectIntegration2725692A" + } + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnRoute", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.WebSocketRoute", + "version": "0.0.0" + } + }, + "$disconnect-Route": { + "id": "$disconnect-Route", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route", + "children": { + "DisconnectIntegration-Permission": { + "id": "DisconnectIntegration-Permission", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration-Permission", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", + "aws:cdk:cloudformation:props": { + "action": "lambda:InvokeFunction", + "functionName": { + "Fn::GetAtt": [ + "DisconnectFunction620A9610", + "Arn" + ] + }, + "principal": "apigateway.amazonaws.com", + "sourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "WebSocketAPIDA75128A" + }, + "/*$disconnect" + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.CfnPermission", + "version": "0.0.0" + } + }, + "DisconnectIntegration": { + "id": "DisconnectIntegration", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration", + "children": { + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Integration", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "integrationType": "AWS_PROXY", + "integrationUri": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":apigateway:", + { + "Ref": "AWS::Region" + }, + ":lambda:path/2015-03-31/functions/", + { + "Fn::GetAtt": [ + "DisconnectFunction620A9610", + "Arn" + ] + }, + "/invocations" + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnIntegration", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.WebSocketIntegration", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Route", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "authorizationType": "NONE", + "routeKey": "$disconnect", + "target": { + "Fn::Join": [ + "", + [ + "integrations/", + { + "Ref": "WebSocketAPIdisconnectRouteDisconnectIntegration317B9227" + } + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnRoute", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.WebSocketRoute", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.WebSocketApi", + "version": "0.0.0" + } + }, + "Production Stage": { + "id": "Production Stage", + "path": "aws-cdk-aws-apigatewayv2-websockets/Production Stage", + "children": { + "Resource": { + "id": "Resource", + "path": "aws-cdk-aws-apigatewayv2-websockets/Production Stage/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Stage", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "WebSocketAPIDA75128A" + }, + "autoDeploy": true, + "stageName": "prod" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnStage", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.WebSocketStage", + "version": "0.0.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "aws-cdk-aws-apigatewayv2-websockets/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "aws-cdk-aws-apigatewayv2-websockets/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "0.0.0" + } + }, + "Integ": { + "id": "Integ", + "path": "Integ", + "children": { + "DefaultTest": { + "id": "DefaultTest", + "path": "Integ/DefaultTest", + "children": { + "Default": { + "id": "Default", + "path": "Integ/DefaultTest/Default", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.2.70" + } + }, + "DeployAssert": { + "id": "DeployAssert", + "path": "Integ/DefaultTest/DeployAssert", + "children": { + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "Integ/DefaultTest/DeployAssert/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", + "version": "0.0.0" + } + }, + "Tree": { + "id": "Tree", + "path": "Tree", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.2.70" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.App", + "version": "0.0.0" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json index 806e1a698a8a3..c73ed81c6cb7f 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "26e34316c6931e2609524675771603977641dab52471e7fb4c21e998529ed3fd": { + "fa386136122b6cd106460ddbdcd437d10712be61617b8d1bf2110a459aa9e233": { "source": { "path": "WebSocketApiInteg.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "26e34316c6931e2609524675771603977641dab52471e7fb4c21e998529ed3fd.json", + "objectKey": "fa386136122b6cd106460ddbdcd437d10712be61617b8d1bf2110a459aa9e233.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json index b6e930b1fa098..e50d8cfbe1645 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json @@ -239,7 +239,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$connect" + "/*$connect" ] ] } @@ -329,7 +329,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$disconnect" + "/*$disconnect" ] ] } @@ -419,7 +419,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$default" + "/*$default" ] ] } @@ -509,7 +509,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*sendmessage" + "/*sendmessage" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json index 18f03b2eb267e..1f2c3210e48af 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json @@ -14,10 +14,11 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "WebSocketApiInteg.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}/26e34316c6931e2609524675771603977641dab52471e7fb4c21e998529ed3fd.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/fa386136122b6cd106460ddbdcd437d10712be61617b8d1bf2110a459aa9e233.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -90,7 +91,10 @@ "/WebSocketApiInteg/mywsapi/$connect-Route/ConnectIntegration-Permission": [ { "type": "aws:cdk:logicalId", - "data": "mywsapiconnectRouteConnectIntegrationPermission719B6E63" + "data": "mywsapiconnectRouteConnectIntegrationPermission719B6E63", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_REPLACE" + ] } ], "/WebSocketApiInteg/mywsapi/$connect-Route/ConnectIntegration/Resource": [ @@ -108,7 +112,10 @@ "/WebSocketApiInteg/mywsapi/$disconnect-Route/DisconnectIntegration-Permission": [ { "type": "aws:cdk:logicalId", - "data": "mywsapidisconnectRouteDisconnectIntegrationPermissionA8197C41" + "data": "mywsapidisconnectRouteDisconnectIntegrationPermissionA8197C41", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_REPLACE" + ] } ], "/WebSocketApiInteg/mywsapi/$disconnect-Route/DisconnectIntegration/Resource": [ @@ -126,7 +133,10 @@ "/WebSocketApiInteg/mywsapi/$default-Route/DefaultIntegration-Permission": [ { "type": "aws:cdk:logicalId", - "data": "mywsapidefaultRouteDefaultIntegrationPermission3B7F9CA1" + "data": "mywsapidefaultRouteDefaultIntegrationPermission3B7F9CA1", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_REPLACE" + ] } ], "/WebSocketApiInteg/mywsapi/$default-Route/DefaultIntegration/Resource": [ @@ -144,7 +154,10 @@ "/WebSocketApiInteg/mywsapi/sendmessage-Route/SendMessageIntegration-Permission": [ { "type": "aws:cdk:logicalId", - "data": "mywsapisendmessageRouteSendMessageIntegrationPermission92C9841E" + "data": "mywsapisendmessageRouteSendMessageIntegrationPermission92C9841E", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_REPLACE" + ] } ], "/WebSocketApiInteg/mywsapi/sendmessage-Route/SendMessageIntegration/Resource": [ diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json index a3eaa745e06b2..990d79acbeef9 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json @@ -430,7 +430,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$connect" + "/*$connect" ] ] } @@ -564,7 +564,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$disconnect" + "/*$disconnect" ] ] } @@ -698,7 +698,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$default" + "/*$default" ] ] } @@ -832,7 +832,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*sendmessage" + "/*sendmessage" ] ] } From 6931b86d82953f89fef0dd673989f5baa10b6c4f Mon Sep 17 00:00:00 2001 From: Sumu Date: Mon, 30 Oct 2023 15:01:29 -0400 Subject: [PATCH 10/15] update apigw snapshots Signed-off-by: Sumu --- .../AuthorizerInteg.assets.json | 4 +- .../AuthorizerInteg.template.json | 279 ++------- .../integ.lambda.js.snapshot/manifest.json | 93 +-- .../http/integ.lambda.js.snapshot/tree.json | 447 +++------------ .../AuthorizerInteg.assets.json | 4 +- .../AuthorizerInteg.template.json | 290 ++-------- .../integ.user-pool.js.snapshot/manifest.json | 106 ++-- .../integ.user-pool.js.snapshot/tree.json | 532 ++++-------------- ...efaultTestDeployAssert4E6713E1.assets.json | 19 - ...aultTestDeployAssert4E6713E1.template.json | 36 -- ...v2-lambda-connect-integration.assets.json} | 2 +- ...-lambda-connect-integration.template.json} | 0 .../integ.json | 12 +- .../manifest.json | 98 +--- .../tree.json | 138 ++--- .../aws-appconfig-environment.assets.json | 4 +- .../aws-appconfig-environment.template.json | 31 - .../manifest.json | 10 +- .../integ.environment.js.snapshot/tree.json | 57 -- .../manifest.json | 12 +- .../test-stack.assets.json | 4 +- .../test-stack.template.json | 9 - .../tree.json | 96 ++-- ...s-cdk-firehose-delivery-stream.assets.json | 4 +- ...cdk-firehose-delivery-stream.template.json | 9 - .../manifest.json | 12 +- .../tree.json | 92 +-- ...-delivery-stream-source-stream.assets.json | 4 +- ...elivery-stream-source-stream.template.json | 9 - .../manifest.json | 12 +- .../tree.json | 96 ++-- ...ivery-stream-s3-all-properties.assets.json | 4 +- ...ery-stream-s3-all-properties.template.json | 9 - .../manifest.json | 2 +- .../aws-cdk-scheduler-schedule.assets.json | 4 +- .../aws-cdk-scheduler-schedule.template.json | 45 -- .../integ.schedule.js.snapshot/manifest.json | 8 +- .../test/integ.schedule.js.snapshot/tree.json | 58 -- 38 files changed, 662 insertions(+), 1989 deletions(-) delete mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json delete mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json rename packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/{aws-cdk-aws-apigatewayv2-websockets.assets.json => integ-apigwv2-lambda-connect-integration.assets.json} (96%) rename packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/{aws-cdk-aws-apigatewayv2-websockets.template.json => integ-apigwv2-lambda-connect-integration.template.json} (100%) diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.assets.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.assets.json index 08bff1e7a6f72..b1fa6727810e1 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.assets.json @@ -27,7 +27,7 @@ } } }, - "1392f7df97b60ac420a8ba97f1d6ac2f6e984a168d85bb763108846d396c6553": { + "d494d0e4b4be2192ea2cc4c56ea29fa7d0f23e45c006cb05eedae57d8a42cf78": { "source": { "path": "AuthorizerInteg.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "1392f7df97b60ac420a8ba97f1d6ac2f6e984a168d85bb763108846d396c6553.json", + "objectKey": "d494d0e4b4be2192ea2cc4c56ea29fa7d0f23e45c006cb05eedae57d8a42cf78.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.template.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.template.json index 002fb57113411..57ae669b6f247 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.template.json @@ -1,58 +1,5 @@ { "Resources": { - "authfunctionServiceRoleFCB72198": { - "Type": "AWS::IAM::Role", - "Properties": { - "AssumeRolePolicyDocument": { - "Statement": [ - { - "Action": "sts:AssumeRole", - "Effect": "Allow", - "Principal": { - "Service": "lambda.amazonaws.com" - } - } - ], - "Version": "2012-10-17" - }, - "ManagedPolicyArns": [ - { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" - ] - ] - } - ] - } - }, - "authfunction96361832": { - "Type": "AWS::Lambda::Function", - "Properties": { - "Code": { - "S3Bucket": { - "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" - }, - "S3Key": "d7d3785243d748927f2a8d6edcecf909f96191df27a815e305aaeba98bcd2c64.zip" - }, - "Handler": "index.handler", - "Role": { - "Fn::GetAtt": [ - "authfunctionServiceRoleFCB72198", - "Arn" - ] - }, - "Runtime": "nodejs18.x" - }, - "DependsOn": [ - "authfunctionServiceRoleFCB72198" - ] - }, "MyHttpApi8AEAAC21": { "Type": "AWS::ApiGatewayV2::Api", "Properties": { @@ -226,101 +173,58 @@ } } }, - "MyHttpApiWithDefaultAuthorizerE08800A1": { - "Type": "AWS::ApiGatewayV2::Api", - "Properties": { - "Name": "MyHttpApiWithDefaultAuthorizer", - "ProtocolType": "HTTP" - } - }, - "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6": { - "Type": "AWS::ApiGatewayV2::Stage", - "Properties": { - "ApiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "AutoDeploy": true, - "StageName": "$default" - } - }, - "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65": { - "Type": "AWS::ApiGatewayV2::Authorizer", + "authfunctionServiceRoleFCB72198": { + "Type": "AWS::IAM::Role", "Properties": { - "ApiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "lambda.amazonaws.com" + } + } + ], + "Version": "2012-10-17" }, - "AuthorizerPayloadFormatVersion": "2.0", - "AuthorizerResultTtlInSeconds": 300, - "AuthorizerType": "REQUEST", - "AuthorizerUri": { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":apigateway:", - { - "Ref": "AWS::Region" - }, - ":lambda:path/2015-03-31/functions/", - { - "Fn::GetAtt": [ - "authfunction96361832", - "Arn" - ] - }, - "/invocations" + "ManagedPolicyArns": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" + ] ] - ] - }, - "EnableSimpleResponses": true, - "IdentitySource": [ - "$request.header.X-API-Key" - ], - "Name": "my-simple-authorizer" + } + ] } }, - "MyHttpApiWithDefaultAuthorizerAuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35Permission700DB59D": { - "Type": "AWS::Lambda::Permission", + "authfunction96361832": { + "Type": "AWS::Lambda::Function", "Properties": { - "Action": "lambda:InvokeFunction", - "FunctionName": { + "Code": { + "S3Bucket": { + "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" + }, + "S3Key": "d7d3785243d748927f2a8d6edcecf909f96191df27a815e305aaeba98bcd2c64.zip" + }, + "Handler": "index.handler", + "Role": { "Fn::GetAtt": [ - "authfunction96361832", + "authfunctionServiceRoleFCB72198", "Arn" ] }, - "Principal": "apigateway.amazonaws.com", - "SourceArn": { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":execute-api:", - { - "Ref": "AWS::Region" - }, - ":", - { - "Ref": "AWS::AccountId" - }, - ":", - { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "/authorizers/", - { - "Ref": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" - } - ] - ] - } - } + "Runtime": "nodejs18.x" + }, + "DependsOn": [ + "authfunctionServiceRoleFCB72198" + ] }, "lambdaServiceRole494E4CA6": { "Type": "AWS::IAM::Role", @@ -374,83 +278,6 @@ "DependsOn": [ "lambdaServiceRole494E4CA6" ] - }, - "RouteRootIntegration1CF58575": { - "Type": "AWS::ApiGatewayV2::Integration", - "Properties": { - "ApiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "IntegrationType": "AWS_PROXY", - "IntegrationUri": { - "Fn::GetAtt": [ - "lambda8B5974B5", - "Arn" - ] - }, - "PayloadFormatVersion": "2.0" - } - }, - "RouteRootIntegrationPermissionC2C15701": { - "Type": "AWS::Lambda::Permission", - "Properties": { - "Action": "lambda:InvokeFunction", - "FunctionName": { - "Fn::GetAtt": [ - "lambda8B5974B5", - "Arn" - ] - }, - "Principal": "apigateway.amazonaws.com", - "SourceArn": { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":execute-api:", - { - "Ref": "AWS::Region" - }, - ":", - { - "Ref": "AWS::AccountId" - }, - ":", - { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "/*/*/v1/mything/{proxy+}" - ] - ] - } - } - }, - "RouteA67450D2": { - "Type": "AWS::ApiGatewayV2::Route", - "Properties": { - "ApiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "AuthorizationType": "CUSTOM", - "AuthorizerId": { - "Ref": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" - }, - "RouteKey": "ANY /v1/mything/{proxy+}", - "Target": { - "Fn::Join": [ - "", - [ - "integrations/", - { - "Ref": "RouteRootIntegration1CF58575" - } - ] - ] - } - } } }, "Outputs": { @@ -475,28 +302,6 @@ ] ] } - }, - "URLWithDefaultAuthorizer": { - "Value": { - "Fn::Join": [ - "", - [ - "https://", - { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - ".execute-api.", - { - "Ref": "AWS::Region" - }, - ".", - { - "Ref": "AWS::URLSuffix" - }, - "/" - ] - ] - } } }, "Parameters": { diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/manifest.json index 9636d2c7f226b..e1e448b30404c 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/manifest.json @@ -18,7 +18,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}/1392f7df97b60ac420a8ba97f1d6ac2f6e984a168d85bb763108846d396c6553.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/d494d0e4b4be2192ea2cc4c56ea29fa7d0f23e45c006cb05eedae57d8a42cf78.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -34,18 +34,6 @@ "AuthorizerInteg.assets" ], "metadata": { - "/AuthorizerInteg/auth-function/ServiceRole/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "authfunctionServiceRoleFCB72198" - } - ], - "/AuthorizerInteg/auth-function/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "authfunction96361832" - } - ], "/AuthorizerInteg/MyHttpApi/Resource": [ { "type": "aws:cdk:logicalId", @@ -88,82 +76,109 @@ "data": "MyHttpApiAuthorizerIntegMyHttpApiLambdaAuthorizerB89228D7Permission82260331" } ], - "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/Resource": [ + "/AuthorizerInteg/auth-function/ServiceRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "authfunctionServiceRoleFCB72198" + } + ], + "/AuthorizerInteg/auth-function/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerE08800A1" + "data": "authfunction96361832" } ], - "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage/Resource": [ + "/AuthorizerInteg/lambda/ServiceRole/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6" + "data": "lambdaServiceRole494E4CA6" } ], - "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/LambdaDefaultAuthorizer/Resource": [ + "/AuthorizerInteg/lambda/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" + "data": "lambda8B5974B5" } ], - "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/AuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35-Permission": [ + "/AuthorizerInteg/URL": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerAuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35Permission700DB59D" + "data": "URL" } ], - "/AuthorizerInteg/lambda/ServiceRole/Resource": [ + "/AuthorizerInteg/BootstrapVersion": [ { "type": "aws:cdk:logicalId", - "data": "lambdaServiceRole494E4CA6" + "data": "BootstrapVersion" } ], - "/AuthorizerInteg/lambda/Resource": [ + "/AuthorizerInteg/CheckBootstrapVersion": [ { "type": "aws:cdk:logicalId", - "data": "lambda8B5974B5" + "data": "CheckBootstrapVersion" } ], - "/AuthorizerInteg/Route/RootIntegration/Resource": [ + "MyHttpApiWithDefaultAuthorizerE08800A1": [ { "type": "aws:cdk:logicalId", - "data": "RouteRootIntegration1CF58575" + "data": "MyHttpApiWithDefaultAuthorizerE08800A1", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/Route/RootIntegration-Permission": [ + "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6": [ { "type": "aws:cdk:logicalId", - "data": "RouteRootIntegrationPermissionC2C15701" + "data": "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/Route/Resource": [ + "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65": [ { "type": "aws:cdk:logicalId", - "data": "RouteA67450D2" + "data": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/URL": [ + "MyHttpApiWithDefaultAuthorizerAuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35Permission700DB59D": [ { "type": "aws:cdk:logicalId", - "data": "URL" + "data": "MyHttpApiWithDefaultAuthorizerAuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35Permission700DB59D", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/URLWithDefaultAuthorizer": [ + "RouteRootIntegration1CF58575": [ { "type": "aws:cdk:logicalId", - "data": "URLWithDefaultAuthorizer" + "data": "RouteRootIntegration1CF58575", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/BootstrapVersion": [ + "RouteRootIntegrationPermissionC2C15701": [ { "type": "aws:cdk:logicalId", - "data": "BootstrapVersion" + "data": "RouteRootIntegrationPermissionC2C15701", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/CheckBootstrapVersion": [ + "RouteA67450D2": [ { "type": "aws:cdk:logicalId", - "data": "CheckBootstrapVersion" + "data": "RouteA67450D2", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ] }, diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/tree.json index 996df67fee0c0..f1f64644ef4af 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/tree.json @@ -8,126 +8,6 @@ "id": "AuthorizerInteg", "path": "AuthorizerInteg", "children": { - "auth-function": { - "id": "auth-function", - "path": "AuthorizerInteg/auth-function", - "children": { - "ServiceRole": { - "id": "ServiceRole", - "path": "AuthorizerInteg/auth-function/ServiceRole", - "children": { - "ImportServiceRole": { - "id": "ImportServiceRole", - "path": "AuthorizerInteg/auth-function/ServiceRole/ImportServiceRole", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" - } - }, - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/auth-function/ServiceRole/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" - }, - "managedPolicyArns": [ - { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" - ] - ] - } - ] - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "0.0.0" - } - }, - "Code": { - "id": "Code", - "path": "AuthorizerInteg/auth-function/Code", - "children": { - "Stage": { - "id": "Stage", - "path": "AuthorizerInteg/auth-function/Code/Stage", - "constructInfo": { - "fqn": "aws-cdk-lib.AssetStaging", - "version": "0.0.0" - } - }, - "AssetBucket": { - "id": "AssetBucket", - "path": "AuthorizerInteg/auth-function/Code/AssetBucket", - "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3.BucketBase", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3_assets.Asset", - "version": "0.0.0" - } - }, - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/auth-function/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": "d7d3785243d748927f2a8d6edcecf909f96191df27a815e305aaeba98bcd2c64.zip" - }, - "handler": "index.handler", - "role": { - "Fn::GetAtt": [ - "authfunctionServiceRoleFCB72198", - "Arn" - ] - }, - "runtime": "nodejs18.x" - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_lambda.Function", - "version": "0.0.0" - } - }, "MyHttpApi": { "id": "MyHttpApi", "path": "AuthorizerInteg/MyHttpApi", @@ -171,7 +51,7 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.Resource", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpStage", "version": "0.0.0" } }, @@ -209,7 +89,7 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.Resource", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpIntegration", "version": "0.0.0" } }, @@ -292,7 +172,7 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.Resource", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpRoute", "version": "0.0.0" } }, @@ -349,7 +229,7 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.Resource", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpAuthorizer", "version": "0.0.0" } }, @@ -403,165 +283,127 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.Resource", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpApi", "version": "0.0.0" } }, - "MyHttpApiWithDefaultAuthorizer": { - "id": "MyHttpApiWithDefaultAuthorizer", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer", + "auth-function": { + "id": "auth-function", + "path": "AuthorizerInteg/auth-function", "children": { - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Api", - "aws:cdk:cloudformation:props": { - "name": "MyHttpApiWithDefaultAuthorizer", - "protocolType": "HTTP" - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnApi", - "version": "0.0.0" - } - }, - "DefaultStage": { - "id": "DefaultStage", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage", + "ServiceRole": { + "id": "ServiceRole", + "path": "AuthorizerInteg/auth-function/ServiceRole", "children": { + "ImportServiceRole": { + "id": "ImportServiceRole", + "path": "AuthorizerInteg/auth-function/ServiceRole/ImportServiceRole", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" + } + }, "Resource": { "id": "Resource", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage/Resource", + "path": "AuthorizerInteg/auth-function/ServiceRole/Resource", "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Stage", + "aws:cdk:cloudformation:type": "AWS::IAM::Role", "aws:cdk:cloudformation:props": { - "apiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "lambda.amazonaws.com" + } + } + ], + "Version": "2012-10-17" }, - "autoDeploy": true, - "stageName": "$default" + "managedPolicyArns": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" + ] + ] + } + ] } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnStage", + "fqn": "aws-cdk-lib.aws_iam.CfnRole", "version": "0.0.0" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.Resource", + "fqn": "aws-cdk-lib.aws_iam.Role", "version": "0.0.0" } }, - "LambdaDefaultAuthorizer": { - "id": "LambdaDefaultAuthorizer", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/LambdaDefaultAuthorizer", + "Code": { + "id": "Code", + "path": "AuthorizerInteg/auth-function/Code", "children": { - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/LambdaDefaultAuthorizer/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Authorizer", - "aws:cdk:cloudformation:props": { - "apiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "authorizerPayloadFormatVersion": "2.0", - "authorizerResultTtlInSeconds": 300, - "authorizerType": "REQUEST", - "authorizerUri": { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":apigateway:", - { - "Ref": "AWS::Region" - }, - ":lambda:path/2015-03-31/functions/", - { - "Fn::GetAtt": [ - "authfunction96361832", - "Arn" - ] - }, - "/invocations" - ] - ] - }, - "enableSimpleResponses": true, - "identitySource": [ - "$request.header.X-API-Key" - ], - "name": "my-simple-authorizer" - } - }, + "Stage": { + "id": "Stage", + "path": "AuthorizerInteg/auth-function/Code/Stage", "constructInfo": { - "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnAuthorizer", + "fqn": "aws-cdk-lib.AssetStaging", + "version": "0.0.0" + } + }, + "AssetBucket": { + "id": "AssetBucket", + "path": "AuthorizerInteg/auth-function/Code/AssetBucket", + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.BucketBase", "version": "0.0.0" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.Resource", + "fqn": "aws-cdk-lib.aws_s3_assets.Asset", "version": "0.0.0" } }, - "AuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35-Permission": { - "id": "AuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35-Permission", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/AuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35-Permission", + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/auth-function/Resource", "attributes": { - "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", + "aws:cdk:cloudformation:type": "AWS::Lambda::Function", "aws:cdk:cloudformation:props": { - "action": "lambda:InvokeFunction", - "functionName": { + "code": { + "s3Bucket": { + "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" + }, + "s3Key": "d7d3785243d748927f2a8d6edcecf909f96191df27a815e305aaeba98bcd2c64.zip" + }, + "handler": "index.handler", + "role": { "Fn::GetAtt": [ - "authfunction96361832", + "authfunctionServiceRoleFCB72198", "Arn" ] }, - "principal": "apigateway.amazonaws.com", - "sourceArn": { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":execute-api:", - { - "Ref": "AWS::Region" - }, - ":", - { - "Ref": "AWS::AccountId" - }, - ":", - { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "/authorizers/", - { - "Ref": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" - } - ] - ] - } + "runtime": "nodejs18.x" } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_lambda.CfnPermission", + "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", "version": "0.0.0" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.Resource", + "fqn": "aws-cdk-lib.aws_lambda.Function", "version": "0.0.0" } }, @@ -685,127 +527,6 @@ "version": "0.0.0" } }, - "Route": { - "id": "Route", - "path": "AuthorizerInteg/Route", - "children": { - "RootIntegration": { - "id": "RootIntegration", - "path": "AuthorizerInteg/Route/RootIntegration", - "children": { - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/Route/RootIntegration/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Integration", - "aws:cdk:cloudformation:props": { - "apiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "integrationType": "AWS_PROXY", - "integrationUri": { - "Fn::GetAtt": [ - "lambda8B5974B5", - "Arn" - ] - }, - "payloadFormatVersion": "2.0" - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnIntegration", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" - } - }, - "RootIntegration-Permission": { - "id": "RootIntegration-Permission", - "path": "AuthorizerInteg/Route/RootIntegration-Permission", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", - "aws:cdk:cloudformation:props": { - "action": "lambda:InvokeFunction", - "functionName": { - "Fn::GetAtt": [ - "lambda8B5974B5", - "Arn" - ] - }, - "principal": "apigateway.amazonaws.com", - "sourceArn": { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":execute-api:", - { - "Ref": "AWS::Region" - }, - ":", - { - "Ref": "AWS::AccountId" - }, - ":", - { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "/*/*/v1/mything/{proxy+}" - ] - ] - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_lambda.CfnPermission", - "version": "0.0.0" - } - }, - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/Route/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Route", - "aws:cdk:cloudformation:props": { - "apiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "authorizationType": "CUSTOM", - "authorizerId": { - "Ref": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" - }, - "routeKey": "ANY /v1/mything/{proxy+}", - "target": { - "Fn::Join": [ - "", - [ - "integrations/", - { - "Ref": "RouteRootIntegration1CF58575" - } - ] - ] - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnRoute", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" - } - }, "URL": { "id": "URL", "path": "AuthorizerInteg/URL", @@ -814,14 +535,6 @@ "version": "0.0.0" } }, - "URLWithDefaultAuthorizer": { - "id": "URLWithDefaultAuthorizer", - "path": "AuthorizerInteg/URLWithDefaultAuthorizer", - "constructInfo": { - "fqn": "aws-cdk-lib.CfnOutput", - "version": "0.0.0" - } - }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "AuthorizerInteg/BootstrapVersion", diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.assets.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.assets.json index 523c011b3c99d..2f81bb685edcc 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.assets.json @@ -14,7 +14,7 @@ } } }, - "8e1b12f5d12c6de951105961b92d6c971a32d4cbbc394e1542bcbedf77450978": { + "0847c0b726780e7b084297b7c2323b91c608e241e019e9d3e0bf62fcfd673c8d": { "source": { "path": "AuthorizerInteg.template.json", "packaging": "file" @@ -22,7 +22,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "8e1b12f5d12c6de951105961b92d6c971a32d4cbbc394e1542bcbedf77450978.json", + "objectKey": "0847c0b726780e7b084297b7c2323b91c608e241e019e9d3e0bf62fcfd673c8d.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.template.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.template.json index e3d22ec70cf41..10025f453c775 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.template.json @@ -1,119 +1,5 @@ { "Resources": { - "userpool0AC4AA96": { - "Type": "AWS::Cognito::UserPool", - "Properties": { - "AccountRecoverySetting": { - "RecoveryMechanisms": [ - { - "Name": "verified_phone_number", - "Priority": 1 - }, - { - "Name": "verified_email", - "Priority": 2 - } - ] - }, - "AdminCreateUserConfig": { - "AllowAdminCreateUserOnly": true - }, - "EmailVerificationMessage": "The verification code to your new account is {####}", - "EmailVerificationSubject": "Verify your new account", - "SmsVerificationMessage": "The verification code to your new account is {####}", - "VerificationMessageTemplate": { - "DefaultEmailOption": "CONFIRM_WITH_CODE", - "EmailMessage": "The verification code to your new account is {####}", - "EmailSubject": "Verify your new account", - "SmsMessage": "The verification code to your new account is {####}" - } - }, - "UpdateReplacePolicy": "Retain", - "DeletionPolicy": "Retain" - }, - "userpoolUserPoolAuthorizerClient6A7486E8": { - "Type": "AWS::Cognito::UserPoolClient", - "Properties": { - "AllowedOAuthFlows": [ - "implicit", - "code" - ], - "AllowedOAuthFlowsUserPoolClient": true, - "AllowedOAuthScopes": [ - "profile", - "phone", - "email", - "openid", - "aws.cognito.signin.user.admin" - ], - "CallbackURLs": [ - "https://example.com" - ], - "SupportedIdentityProviders": [ - "COGNITO" - ], - "UserPoolId": { - "Ref": "userpool0AC4AA96" - } - } - }, - "userpoolForDefaultAuthorizerDFBE8E74": { - "Type": "AWS::Cognito::UserPool", - "Properties": { - "AccountRecoverySetting": { - "RecoveryMechanisms": [ - { - "Name": "verified_phone_number", - "Priority": 1 - }, - { - "Name": "verified_email", - "Priority": 2 - } - ] - }, - "AdminCreateUserConfig": { - "AllowAdminCreateUserOnly": true - }, - "EmailVerificationMessage": "The verification code to your new account is {####}", - "EmailVerificationSubject": "Verify your new account", - "SmsVerificationMessage": "The verification code to your new account is {####}", - "VerificationMessageTemplate": { - "DefaultEmailOption": "CONFIRM_WITH_CODE", - "EmailMessage": "The verification code to your new account is {####}", - "EmailSubject": "Verify your new account", - "SmsMessage": "The verification code to your new account is {####}" - } - }, - "UpdateReplacePolicy": "Retain", - "DeletionPolicy": "Retain" - }, - "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7": { - "Type": "AWS::Cognito::UserPoolClient", - "Properties": { - "AllowedOAuthFlows": [ - "implicit", - "code" - ], - "AllowedOAuthFlowsUserPoolClient": true, - "AllowedOAuthScopes": [ - "profile", - "phone", - "email", - "openid", - "aws.cognito.signin.user.admin" - ], - "CallbackURLs": [ - "https://example.com" - ], - "SupportedIdentityProviders": [ - "COGNITO" - ], - "UserPoolId": { - "Ref": "userpoolForDefaultAuthorizerDFBE8E74" - } - } - }, "MyHttpApi8AEAAC21": { "Type": "AWS::ApiGatewayV2::Api", "Properties": { @@ -243,56 +129,61 @@ "Name": "UserPoolAuthorizer" } }, - "MyHttpApiWithDefaultAuthorizerE08800A1": { - "Type": "AWS::ApiGatewayV2::Api", - "Properties": { - "Name": "MyHttpApiWithDefaultAuthorizer", - "ProtocolType": "HTTP" - } - }, - "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6": { - "Type": "AWS::ApiGatewayV2::Stage", + "userpool0AC4AA96": { + "Type": "AWS::Cognito::UserPool", "Properties": { - "ApiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + "AccountRecoverySetting": { + "RecoveryMechanisms": [ + { + "Name": "verified_phone_number", + "Priority": 1 + }, + { + "Name": "verified_email", + "Priority": 2 + } + ] }, - "AutoDeploy": true, - "StageName": "$default" - } + "AdminCreateUserConfig": { + "AllowAdminCreateUserOnly": true + }, + "EmailVerificationMessage": "The verification code to your new account is {####}", + "EmailVerificationSubject": "Verify your new account", + "SmsVerificationMessage": "The verification code to your new account is {####}", + "VerificationMessageTemplate": { + "DefaultEmailOption": "CONFIRM_WITH_CODE", + "EmailMessage": "The verification code to your new account is {####}", + "EmailSubject": "Verify your new account", + "SmsMessage": "The verification code to your new account is {####}" + } + }, + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" }, - "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF": { - "Type": "AWS::ApiGatewayV2::Authorizer", + "userpoolUserPoolAuthorizerClient6A7486E8": { + "Type": "AWS::Cognito::UserPoolClient", "Properties": { - "ApiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "AuthorizerType": "JWT", - "IdentitySource": [ - "$request.header.Authorization" + "AllowedOAuthFlows": [ + "implicit", + "code" ], - "JwtConfiguration": { - "Audience": [ - { - "Ref": "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7" - } - ], - "Issuer": { - "Fn::Join": [ - "", - [ - "https://cognito-idp.", - { - "Ref": "AWS::Region" - }, - ".amazonaws.com/", - { - "Ref": "userpoolForDefaultAuthorizerDFBE8E74" - } - ] - ] - } - }, - "Name": "UserPoolDefaultAuthorizer" + "AllowedOAuthFlowsUserPoolClient": true, + "AllowedOAuthScopes": [ + "profile", + "phone", + "email", + "openid", + "aws.cognito.signin.user.admin" + ], + "CallbackURLs": [ + "https://example.com" + ], + "SupportedIdentityProviders": [ + "COGNITO" + ], + "UserPoolId": { + "Ref": "userpool0AC4AA96" + } } }, "lambdaServiceRole494E4CA6": { @@ -347,87 +238,6 @@ "DependsOn": [ "lambdaServiceRole494E4CA6" ] - }, - "RouteRootIntegration1CF58575": { - "Type": "AWS::ApiGatewayV2::Integration", - "Properties": { - "ApiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "IntegrationType": "AWS_PROXY", - "IntegrationUri": { - "Fn::GetAtt": [ - "lambda8B5974B5", - "Arn" - ] - }, - "PayloadFormatVersion": "2.0" - } - }, - "RouteRootIntegrationPermissionC2C15701": { - "Type": "AWS::Lambda::Permission", - "Properties": { - "Action": "lambda:InvokeFunction", - "FunctionName": { - "Fn::GetAtt": [ - "lambda8B5974B5", - "Arn" - ] - }, - "Principal": "apigateway.amazonaws.com", - "SourceArn": { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":execute-api:", - { - "Ref": "AWS::Region" - }, - ":", - { - "Ref": "AWS::AccountId" - }, - ":", - { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "/*/*/v1/mything/{proxy+}" - ] - ] - } - } - }, - "RouteA67450D2": { - "Type": "AWS::ApiGatewayV2::Route", - "Properties": { - "ApiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "AuthorizationScopes": [ - "scope1", - "scope2" - ], - "AuthorizationType": "JWT", - "AuthorizerId": { - "Ref": "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF" - }, - "RouteKey": "ANY /v1/mything/{proxy+}", - "Target": { - "Fn::Join": [ - "", - [ - "integrations/", - { - "Ref": "RouteRootIntegration1CF58575" - } - ] - ] - } - } } }, "Parameters": { diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/manifest.json index 85761c96e101e..d46d951d4f47a 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/manifest.json @@ -18,7 +18,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}/8e1b12f5d12c6de951105961b92d6c971a32d4cbbc394e1542bcbedf77450978.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/0847c0b726780e7b084297b7c2323b91c608e241e019e9d3e0bf62fcfd673c8d.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -34,124 +34,148 @@ "AuthorizerInteg.assets" ], "metadata": { - "/AuthorizerInteg/userpool/Resource": [ + "/AuthorizerInteg/MyHttpApi/Resource": [ { "type": "aws:cdk:logicalId", - "data": "userpool0AC4AA96" + "data": "MyHttpApi8AEAAC21" } ], - "/AuthorizerInteg/userpool/UserPoolAuthorizerClient/Resource": [ + "/AuthorizerInteg/MyHttpApi/DefaultStage/Resource": [ { "type": "aws:cdk:logicalId", - "data": "userpoolUserPoolAuthorizerClient6A7486E8" + "data": "MyHttpApiDefaultStageDCB9BC49" } ], - "/AuthorizerInteg/userpoolForDefaultAuthorizer/Resource": [ + "/AuthorizerInteg/MyHttpApi/GET--/RootIntegratin/Resource": [ { "type": "aws:cdk:logicalId", - "data": "userpoolForDefaultAuthorizerDFBE8E74" + "data": "MyHttpApiGETRootIntegratin93150A89" } ], - "/AuthorizerInteg/userpoolForDefaultAuthorizer/UserPoolAuthorizerClient/Resource": [ + "/AuthorizerInteg/MyHttpApi/GET--/RootIntegratin-Permission": [ { "type": "aws:cdk:logicalId", - "data": "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7" + "data": "MyHttpApiGETRootIntegratinPermissionCEEEB498" } ], - "/AuthorizerInteg/MyHttpApi/Resource": [ + "/AuthorizerInteg/MyHttpApi/GET--/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApi8AEAAC21" + "data": "MyHttpApiGETE0EFC6F8" } ], - "/AuthorizerInteg/MyHttpApi/DefaultStage/Resource": [ + "/AuthorizerInteg/MyHttpApi/UserPoolAuthorizer/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiDefaultStageDCB9BC49" + "data": "MyHttpApiUserPoolAuthorizer8754262B" } ], - "/AuthorizerInteg/MyHttpApi/GET--/RootIntegratin/Resource": [ + "/AuthorizerInteg/userpool/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiGETRootIntegratin93150A89" + "data": "userpool0AC4AA96" } ], - "/AuthorizerInteg/MyHttpApi/GET--/RootIntegratin-Permission": [ + "/AuthorizerInteg/userpool/UserPoolAuthorizerClient/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiGETRootIntegratinPermissionCEEEB498" + "data": "userpoolUserPoolAuthorizerClient6A7486E8" } ], - "/AuthorizerInteg/MyHttpApi/GET--/Resource": [ + "/AuthorizerInteg/lambda/ServiceRole/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiGETE0EFC6F8" + "data": "lambdaServiceRole494E4CA6" } ], - "/AuthorizerInteg/MyHttpApi/UserPoolAuthorizer/Resource": [ + "/AuthorizerInteg/lambda/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiUserPoolAuthorizer8754262B" + "data": "lambda8B5974B5" } ], - "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/Resource": [ + "/AuthorizerInteg/BootstrapVersion": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerE08800A1" + "data": "BootstrapVersion" } ], - "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage/Resource": [ + "/AuthorizerInteg/CheckBootstrapVersion": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6" + "data": "CheckBootstrapVersion" } ], - "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/UserPoolDefaultAuthorizer/Resource": [ + "userpoolForDefaultAuthorizerDFBE8E74": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF" + "data": "userpoolForDefaultAuthorizerDFBE8E74", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/lambda/ServiceRole/Resource": [ + "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7": [ { "type": "aws:cdk:logicalId", - "data": "lambdaServiceRole494E4CA6" + "data": "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/lambda/Resource": [ + "MyHttpApiWithDefaultAuthorizerE08800A1": [ { "type": "aws:cdk:logicalId", - "data": "lambda8B5974B5" + "data": "MyHttpApiWithDefaultAuthorizerE08800A1", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/Route/RootIntegration/Resource": [ + "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6": [ { "type": "aws:cdk:logicalId", - "data": "RouteRootIntegration1CF58575" + "data": "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/Route/RootIntegration-Permission": [ + "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF": [ { "type": "aws:cdk:logicalId", - "data": "RouteRootIntegrationPermissionC2C15701" + "data": "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/Route/Resource": [ + "RouteRootIntegration1CF58575": [ { "type": "aws:cdk:logicalId", - "data": "RouteA67450D2" + "data": "RouteRootIntegration1CF58575", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/BootstrapVersion": [ + "RouteRootIntegrationPermissionC2C15701": [ { "type": "aws:cdk:logicalId", - "data": "BootstrapVersion" + "data": "RouteRootIntegrationPermissionC2C15701", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ], - "/AuthorizerInteg/CheckBootstrapVersion": [ + "RouteA67450D2": [ { "type": "aws:cdk:logicalId", - "data": "CheckBootstrapVersion" + "data": "RouteA67450D2", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] } ] }, diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/tree.json index 7dd213178bc9c..dbcc561a94515 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/tree.json @@ -8,188 +8,6 @@ "id": "AuthorizerInteg", "path": "AuthorizerInteg", "children": { - "userpool": { - "id": "userpool", - "path": "AuthorizerInteg/userpool", - "children": { - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/userpool/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::Cognito::UserPool", - "aws:cdk:cloudformation:props": { - "accountRecoverySetting": { - "recoveryMechanisms": [ - { - "name": "verified_phone_number", - "priority": 1 - }, - { - "name": "verified_email", - "priority": 2 - } - ] - }, - "adminCreateUserConfig": { - "allowAdminCreateUserOnly": true - }, - "emailVerificationMessage": "The verification code to your new account is {####}", - "emailVerificationSubject": "Verify your new account", - "smsVerificationMessage": "The verification code to your new account is {####}", - "verificationMessageTemplate": { - "defaultEmailOption": "CONFIRM_WITH_CODE", - "emailMessage": "The verification code to your new account is {####}", - "emailSubject": "Verify your new account", - "smsMessage": "The verification code to your new account is {####}" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, - "UserPoolAuthorizerClient": { - "id": "UserPoolAuthorizerClient", - "path": "AuthorizerInteg/userpool/UserPoolAuthorizerClient", - "children": { - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/userpool/UserPoolAuthorizerClient/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::Cognito::UserPoolClient", - "aws:cdk:cloudformation:props": { - "allowedOAuthFlows": [ - "implicit", - "code" - ], - "allowedOAuthFlowsUserPoolClient": true, - "allowedOAuthScopes": [ - "profile", - "phone", - "email", - "openid", - "aws.cognito.signin.user.admin" - ], - "callbackUrLs": [ - "https://example.com" - ], - "supportedIdentityProviders": [ - "COGNITO" - ], - "userPoolId": { - "Ref": "userpool0AC4AA96" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, - "userpoolForDefaultAuthorizer": { - "id": "userpoolForDefaultAuthorizer", - "path": "AuthorizerInteg/userpoolForDefaultAuthorizer", - "children": { - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/userpoolForDefaultAuthorizer/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::Cognito::UserPool", - "aws:cdk:cloudformation:props": { - "accountRecoverySetting": { - "recoveryMechanisms": [ - { - "name": "verified_phone_number", - "priority": 1 - }, - { - "name": "verified_email", - "priority": 2 - } - ] - }, - "adminCreateUserConfig": { - "allowAdminCreateUserOnly": true - }, - "emailVerificationMessage": "The verification code to your new account is {####}", - "emailVerificationSubject": "Verify your new account", - "smsVerificationMessage": "The verification code to your new account is {####}", - "verificationMessageTemplate": { - "defaultEmailOption": "CONFIRM_WITH_CODE", - "emailMessage": "The verification code to your new account is {####}", - "emailSubject": "Verify your new account", - "smsMessage": "The verification code to your new account is {####}" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, - "UserPoolAuthorizerClient": { - "id": "UserPoolAuthorizerClient", - "path": "AuthorizerInteg/userpoolForDefaultAuthorizer/UserPoolAuthorizerClient", - "children": { - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/userpoolForDefaultAuthorizer/UserPoolAuthorizerClient/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::Cognito::UserPoolClient", - "aws:cdk:cloudformation:props": { - "allowedOAuthFlows": [ - "implicit", - "code" - ], - "allowedOAuthFlowsUserPoolClient": true, - "allowedOAuthScopes": [ - "profile", - "phone", - "email", - "openid", - "aws.cognito.signin.user.admin" - ], - "callbackUrLs": [ - "https://example.com" - ], - "supportedIdentityProviders": [ - "COGNITO" - ], - "userPoolId": { - "Ref": "userpoolForDefaultAuthorizerDFBE8E74" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, "MyHttpApi": { "id": "MyHttpApi", "path": "AuthorizerInteg/MyHttpApi", @@ -205,8 +23,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnApi", + "version": "0.0.0" } }, "DefaultStage": { @@ -227,14 +45,14 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnStage", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpStage", + "version": "0.0.0" } }, "GET--": { @@ -265,14 +83,14 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnIntegration", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpIntegration", + "version": "0.0.0" } }, "RootIntegratin-Permission": { @@ -316,8 +134,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_lambda.CfnPermission", + "version": "0.0.0" } }, "Resource": { @@ -348,14 +166,14 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnRoute", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpRoute", + "version": "0.0.0" } }, "UserPoolAuthorizer": { @@ -401,126 +219,111 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnAuthorizer", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpAuthorizer", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpApi", + "version": "0.0.0" } }, - "MyHttpApiWithDefaultAuthorizer": { - "id": "MyHttpApiWithDefaultAuthorizer", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer", + "userpool": { + "id": "userpool", + "path": "AuthorizerInteg/userpool", "children": { "Resource": { "id": "Resource", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/Resource", + "path": "AuthorizerInteg/userpool/Resource", "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Api", + "aws:cdk:cloudformation:type": "AWS::Cognito::UserPool", "aws:cdk:cloudformation:props": { - "name": "MyHttpApiWithDefaultAuthorizer", - "protocolType": "HTTP" - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, - "DefaultStage": { - "id": "DefaultStage", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage", - "children": { - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Stage", - "aws:cdk:cloudformation:props": { - "apiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + "accountRecoverySetting": { + "recoveryMechanisms": [ + { + "name": "verified_phone_number", + "priority": 1 }, - "autoDeploy": true, - "stageName": "$default" - } + { + "name": "verified_email", + "priority": 2 + } + ] }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "adminCreateUserConfig": { + "allowAdminCreateUserOnly": true + }, + "emailVerificationMessage": "The verification code to your new account is {####}", + "emailVerificationSubject": "Verify your new account", + "smsVerificationMessage": "The verification code to your new account is {####}", + "verificationMessageTemplate": { + "defaultEmailOption": "CONFIRM_WITH_CODE", + "emailMessage": "The verification code to your new account is {####}", + "emailSubject": "Verify your new account", + "smsMessage": "The verification code to your new account is {####}" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_cognito.CfnUserPool", + "version": "0.0.0" } }, - "UserPoolDefaultAuthorizer": { - "id": "UserPoolDefaultAuthorizer", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/UserPoolDefaultAuthorizer", + "UserPoolAuthorizerClient": { + "id": "UserPoolAuthorizerClient", + "path": "AuthorizerInteg/userpool/UserPoolAuthorizerClient", "children": { "Resource": { "id": "Resource", - "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/UserPoolDefaultAuthorizer/Resource", + "path": "AuthorizerInteg/userpool/UserPoolAuthorizerClient/Resource", "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Authorizer", + "aws:cdk:cloudformation:type": "AWS::Cognito::UserPoolClient", "aws:cdk:cloudformation:props": { - "apiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "authorizerType": "JWT", - "identitySource": [ - "$request.header.Authorization" + "allowedOAuthFlows": [ + "implicit", + "code" ], - "jwtConfiguration": { - "audience": [ - { - "Ref": "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7" - } - ], - "issuer": { - "Fn::Join": [ - "", - [ - "https://cognito-idp.", - { - "Ref": "AWS::Region" - }, - ".amazonaws.com/", - { - "Ref": "userpoolForDefaultAuthorizerDFBE8E74" - } - ] - ] - } - }, - "name": "UserPoolDefaultAuthorizer" + "allowedOAuthFlowsUserPoolClient": true, + "allowedOAuthScopes": [ + "profile", + "phone", + "email", + "openid", + "aws.cognito.signin.user.admin" + ], + "callbackUrLs": [ + "https://example.com" + ], + "supportedIdentityProviders": [ + "COGNITO" + ], + "userPoolId": { + "Ref": "userpool0AC4AA96" + } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_cognito.CfnUserPoolClient", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_cognito.UserPoolClient", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_cognito.UserPool", + "version": "0.0.0" } }, "lambda": { @@ -535,8 +338,8 @@ "id": "ImportServiceRole", "path": "AuthorizerInteg/lambda/ServiceRole/ImportServiceRole", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" } }, "Resource": { @@ -574,14 +377,14 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" } }, "Code": { @@ -592,22 +395,22 @@ "id": "Stage", "path": "AuthorizerInteg/lambda/Code/Stage", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.AssetStaging", + "version": "0.0.0" } }, "AssetBucket": { "id": "AssetBucket", "path": "AuthorizerInteg/lambda/Code/AssetBucket", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_s3.BucketBase", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_s3_assets.Asset", + "version": "0.0.0" } }, "Resource": { @@ -633,161 +436,36 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, - "Route": { - "id": "Route", - "path": "AuthorizerInteg/Route", - "children": { - "RootIntegration": { - "id": "RootIntegration", - "path": "AuthorizerInteg/Route/RootIntegration", - "children": { - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/Route/RootIntegration/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Integration", - "aws:cdk:cloudformation:props": { - "apiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "integrationType": "AWS_PROXY", - "integrationUri": { - "Fn::GetAtt": [ - "lambda8B5974B5", - "Arn" - ] - }, - "payloadFormatVersion": "2.0" - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, - "RootIntegration-Permission": { - "id": "RootIntegration-Permission", - "path": "AuthorizerInteg/Route/RootIntegration-Permission", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", - "aws:cdk:cloudformation:props": { - "action": "lambda:InvokeFunction", - "functionName": { - "Fn::GetAtt": [ - "lambda8B5974B5", - "Arn" - ] - }, - "principal": "apigateway.amazonaws.com", - "sourceArn": { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":execute-api:", - { - "Ref": "AWS::Region" - }, - ":", - { - "Ref": "AWS::AccountId" - }, - ":", - { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "/*/*/v1/mything/{proxy+}" - ] - ] - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/Route/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Route", - "aws:cdk:cloudformation:props": { - "apiId": { - "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" - }, - "authorizationScopes": [ - "scope1", - "scope2" - ], - "authorizationType": "JWT", - "authorizerId": { - "Ref": "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF" - }, - "routeKey": "ANY /v1/mything/{proxy+}", - "target": { - "Fn::Join": [ - "", - [ - "integrations/", - { - "Ref": "RouteRootIntegration1CF58575" - } - ] - ] - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_lambda.Function", + "version": "0.0.0" } }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "AuthorizerInteg/BootstrapVersion", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnParameter", + "version": "0.0.0" } }, "CheckBootstrapVersion": { "id": "CheckBootstrapVersion", "path": "AuthorizerInteg/CheckBootstrapVersion", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnRule", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Stack", + "version": "0.0.0" } }, "Tree": { @@ -800,8 +478,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.App", + "version": "0.0.0" } } } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json deleted file mode 100644 index 618513371ae9f..0000000000000 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "version": "34.0.0", - "files": { - "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { - "source": { - "path": "IntegDefaultTestDeployAssert4E6713E1.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/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json deleted file mode 100644 index ad9d0fb73d1dd..0000000000000 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json +++ /dev/null @@ -1,36 +0,0 @@ -{ - "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/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json similarity index 96% rename from packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.assets.json rename to packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json index 207103c9ade6f..a48286b811188 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json @@ -29,7 +29,7 @@ }, "78326e78ff76a1ed4538fd2d47129266d95b8c304857736753ec3afa4250d787": { "source": { - "path": "aws-cdk-aws-apigatewayv2-websockets.template.json", + "path": "integ-apigwv2-lambda-connect-integration.template.json", "packaging": "file" }, "destinations": { diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json similarity index 100% rename from packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/aws-cdk-aws-apigatewayv2-websockets.template.json rename to packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json index fbc76a6cecbdf..e68b02918b8f2 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json @@ -1,12 +1,14 @@ { "version": "34.0.0", "testCases": { - "Integ/DefaultTest": { + "integ.lambda-connect-disconnect-trigger": { "stacks": [ - "aws-cdk-aws-apigatewayv2-websockets" + "integ-apigwv2-lambda-connect-integration" ], - "assertionStack": "Integ/DefaultTest/DeployAssert", - "assertionStackName": "IntegDefaultTestDeployAssert4E6713E1" + "diffAssets": false, + "stackUpdateWorkflow": true } - } + }, + "synthContext": {}, + "enableLookups": false } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json index 6cc579857a94b..c3afd38261081 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json @@ -1,19 +1,19 @@ { "version": "34.0.0", "artifacts": { - "aws-cdk-aws-apigatewayv2-websockets.assets": { + "integ-apigwv2-lambda-connect-integration.assets": { "type": "cdk:asset-manifest", "properties": { - "file": "aws-cdk-aws-apigatewayv2-websockets.assets.json", + "file": "integ-apigwv2-lambda-connect-integration.assets.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" } }, - "aws-cdk-aws-apigatewayv2-websockets": { + "integ-apigwv2-lambda-connect-integration": { "type": "aws:cloudformation:stack", "environment": "aws://unknown-account/unknown-region", "properties": { - "templateFile": "aws-cdk-aws-apigatewayv2-websockets.template.json", + "templateFile": "integ-apigwv2-lambda-connect-integration.template.json", "terminationProtection": false, "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", @@ -22,7 +22,7 @@ "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ - "aws-cdk-aws-apigatewayv2-websockets.assets" + "integ-apigwv2-lambda-connect-integration.assets" ], "lookupRole": { "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", @@ -31,46 +31,46 @@ } }, "dependencies": [ - "aws-cdk-aws-apigatewayv2-websockets.assets" + "integ-apigwv2-lambda-connect-integration.assets" ], "metadata": { - "/aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/Resource": [ + "/integ-apigwv2-lambda-connect-integration/Connect Function/ServiceRole/Resource": [ { "type": "aws:cdk:logicalId", "data": "ConnectFunctionServiceRoleDD1EAA8C" } ], - "/aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/DefaultPolicy/Resource": [ + "/integ-apigwv2-lambda-connect-integration/Connect Function/ServiceRole/DefaultPolicy/Resource": [ { "type": "aws:cdk:logicalId", "data": "ConnectFunctionServiceRoleDefaultPolicy9C1FE0B3" } ], - "/aws-cdk-aws-apigatewayv2-websockets/Connect Function/Resource": [ + "/integ-apigwv2-lambda-connect-integration/Connect Function/Resource": [ { "type": "aws:cdk:logicalId", "data": "ConnectFunction4D4B4BB5" } ], - "/aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/Resource": [ + "/integ-apigwv2-lambda-connect-integration/Disconnect Function/ServiceRole/Resource": [ { "type": "aws:cdk:logicalId", "data": "DisconnectFunctionServiceRole49DB60AC" } ], - "/aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/DefaultPolicy/Resource": [ + "/integ-apigwv2-lambda-connect-integration/Disconnect Function/ServiceRole/DefaultPolicy/Resource": [ { "type": "aws:cdk:logicalId", "data": "DisconnectFunctionServiceRoleDefaultPolicyF5348EC3" } ], - "/aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/Resource": [ + "/integ-apigwv2-lambda-connect-integration/Disconnect Function/Resource": [ { "type": "aws:cdk:logicalId", "data": "DisconnectFunction620A9610" } ], - "/aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table": [ + "/integ-apigwv2-lambda-connect-integration/WebSocket Log Table": [ { "type": "aws:cdk:hasPhysicalName", "data": { @@ -78,122 +78,74 @@ } } ], - "/aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table/Resource": [ + "/integ-apigwv2-lambda-connect-integration/WebSocket Log Table/Resource": [ { "type": "aws:cdk:logicalId", "data": "WebSocketLogTable7F74AAC5" } ], - "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/Resource": [ + "/integ-apigwv2-lambda-connect-integration/WebSocket API/Resource": [ { "type": "aws:cdk:logicalId", "data": "WebSocketAPIDA75128A" } ], - "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration-Permission": [ + "/integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route/ConnectIntegration-Permission": [ { "type": "aws:cdk:logicalId", "data": "WebSocketAPIconnectRouteConnectIntegrationPermission1FECDE58" } ], - "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration/Resource": [ + "/integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route/ConnectIntegration/Resource": [ { "type": "aws:cdk:logicalId", "data": "WebSocketAPIconnectRouteConnectIntegration2725692A" } ], - "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/Resource": [ + "/integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route/Resource": [ { "type": "aws:cdk:logicalId", "data": "WebSocketAPIconnectRoute4BD84FCF" } ], - "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration-Permission": [ + "/integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route/DisconnectIntegration-Permission": [ { "type": "aws:cdk:logicalId", "data": "WebSocketAPIdisconnectRouteDisconnectIntegrationPermission909CCDD8" } ], - "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration/Resource": [ + "/integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route/DisconnectIntegration/Resource": [ { "type": "aws:cdk:logicalId", "data": "WebSocketAPIdisconnectRouteDisconnectIntegration317B9227" } ], - "/aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/Resource": [ + "/integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route/Resource": [ { "type": "aws:cdk:logicalId", "data": "WebSocketAPIdisconnectRouteBC1A3C36" } ], - "/aws-cdk-aws-apigatewayv2-websockets/Production Stage/Resource": [ + "/integ-apigwv2-lambda-connect-integration/Production Stage/Resource": [ { "type": "aws:cdk:logicalId", "data": "ProductionStage7933AAB2" } ], - "/aws-cdk-aws-apigatewayv2-websockets/BootstrapVersion": [ + "/integ-apigwv2-lambda-connect-integration/BootstrapVersion": [ { "type": "aws:cdk:logicalId", "data": "BootstrapVersion" } ], - "/aws-cdk-aws-apigatewayv2-websockets/CheckBootstrapVersion": [ + "/integ-apigwv2-lambda-connect-integration/CheckBootstrapVersion": [ { "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } ] }, - "displayName": "aws-cdk-aws-apigatewayv2-websockets" - }, - "IntegDefaultTestDeployAssert4E6713E1.assets": { - "type": "cdk:asset-manifest", - "properties": { - "file": "IntegDefaultTestDeployAssert4E6713E1.assets.json", - "requiresBootstrapStackVersion": 6, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" - } - }, - "IntegDefaultTestDeployAssert4E6713E1": { - "type": "aws:cloudformation:stack", - "environment": "aws://unknown-account/unknown-region", - "properties": { - "templateFile": "IntegDefaultTestDeployAssert4E6713E1.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": [ - "IntegDefaultTestDeployAssert4E6713E1.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": [ - "IntegDefaultTestDeployAssert4E6713E1.assets" - ], - "metadata": { - "/Integ/DefaultTest/DeployAssert/BootstrapVersion": [ - { - "type": "aws:cdk:logicalId", - "data": "BootstrapVersion" - } - ], - "/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion": [ - { - "type": "aws:cdk:logicalId", - "data": "CheckBootstrapVersion" - } - ] - }, - "displayName": "Integ/DefaultTest/DeployAssert" + "displayName": "integ-apigwv2-lambda-connect-integration" }, "Tree": { "type": "cdk:tree", diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json index 320d1439c9ab2..4972c8ceba984 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json @@ -4,21 +4,21 @@ "id": "App", "path": "", "children": { - "aws-cdk-aws-apigatewayv2-websockets": { - "id": "aws-cdk-aws-apigatewayv2-websockets", - "path": "aws-cdk-aws-apigatewayv2-websockets", + "integ-apigwv2-lambda-connect-integration": { + "id": "integ-apigwv2-lambda-connect-integration", + "path": "integ-apigwv2-lambda-connect-integration", "children": { "Connect Function": { "id": "Connect Function", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function", "children": { "ServiceRole": { "id": "ServiceRole", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function/ServiceRole", "children": { "ImportServiceRole": { "id": "ImportServiceRole", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/ImportServiceRole", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function/ServiceRole/ImportServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", "version": "0.0.0" @@ -26,7 +26,7 @@ }, "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/Resource", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function/ServiceRole/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::IAM::Role", "aws:cdk:cloudformation:props": { @@ -65,11 +65,11 @@ }, "DefaultPolicy": { "id": "DefaultPolicy", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/DefaultPolicy", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function/ServiceRole/DefaultPolicy", "children": { "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/ServiceRole/DefaultPolicy/Resource", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function/ServiceRole/DefaultPolicy/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::IAM::Policy", "aws:cdk:cloudformation:props": { @@ -133,11 +133,11 @@ }, "Code": { "id": "Code", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/Code", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function/Code", "children": { "Stage": { "id": "Stage", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/Code/Stage", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", "version": "0.0.0" @@ -145,7 +145,7 @@ }, "AssetBucket": { "id": "AssetBucket", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/Code/AssetBucket", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", "version": "0.0.0" @@ -159,7 +159,7 @@ }, "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/Connect Function/Resource", + "path": "integ-apigwv2-lambda-connect-integration/Connect Function/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::Lambda::Function", "aws:cdk:cloudformation:props": { @@ -199,15 +199,15 @@ }, "Disconnect Function": { "id": "Disconnect Function", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function", "children": { "ServiceRole": { "id": "ServiceRole", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function/ServiceRole", "children": { "ImportServiceRole": { "id": "ImportServiceRole", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/ImportServiceRole", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function/ServiceRole/ImportServiceRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", "version": "0.0.0" @@ -215,7 +215,7 @@ }, "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/Resource", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function/ServiceRole/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::IAM::Role", "aws:cdk:cloudformation:props": { @@ -254,11 +254,11 @@ }, "DefaultPolicy": { "id": "DefaultPolicy", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/DefaultPolicy", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function/ServiceRole/DefaultPolicy", "children": { "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/ServiceRole/DefaultPolicy/Resource", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function/ServiceRole/DefaultPolicy/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::IAM::Policy", "aws:cdk:cloudformation:props": { @@ -322,11 +322,11 @@ }, "Code": { "id": "Code", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/Code", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function/Code", "children": { "Stage": { "id": "Stage", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/Code/Stage", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function/Code/Stage", "constructInfo": { "fqn": "aws-cdk-lib.AssetStaging", "version": "0.0.0" @@ -334,7 +334,7 @@ }, "AssetBucket": { "id": "AssetBucket", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/Code/AssetBucket", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function/Code/AssetBucket", "constructInfo": { "fqn": "aws-cdk-lib.aws_s3.BucketBase", "version": "0.0.0" @@ -348,7 +348,7 @@ }, "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/Disconnect Function/Resource", + "path": "integ-apigwv2-lambda-connect-integration/Disconnect Function/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::Lambda::Function", "aws:cdk:cloudformation:props": { @@ -388,11 +388,11 @@ }, "WebSocket Log Table": { "id": "WebSocket Log Table", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket Log Table", "children": { "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table/Resource", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket Log Table/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::DynamoDB::Table", "aws:cdk:cloudformation:props": { @@ -422,7 +422,7 @@ }, "ScalingRole": { "id": "ScalingRole", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket Log Table/ScalingRole", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket Log Table/ScalingRole", "constructInfo": { "fqn": "aws-cdk-lib.Resource", "version": "0.0.0" @@ -436,11 +436,11 @@ }, "WebSocket API": { "id": "WebSocket API", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API", "children": { "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/Resource", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Api", "aws:cdk:cloudformation:props": { @@ -456,11 +456,11 @@ }, "$connect-Route": { "id": "$connect-Route", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route", "children": { "ConnectIntegration-Permission": { "id": "ConnectIntegration-Permission", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration-Permission", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route/ConnectIntegration-Permission", "attributes": { "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", "aws:cdk:cloudformation:props": { @@ -505,11 +505,11 @@ }, "ConnectIntegration": { "id": "ConnectIntegration", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route/ConnectIntegration", "children": { "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/ConnectIntegration/Resource", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route/ConnectIntegration/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Integration", "aws:cdk:cloudformation:props": { @@ -555,7 +555,7 @@ }, "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$connect-Route/Resource", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Route", "aws:cdk:cloudformation:props": { @@ -590,11 +590,11 @@ }, "$disconnect-Route": { "id": "$disconnect-Route", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route", "children": { "DisconnectIntegration-Permission": { "id": "DisconnectIntegration-Permission", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration-Permission", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route/DisconnectIntegration-Permission", "attributes": { "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", "aws:cdk:cloudformation:props": { @@ -639,11 +639,11 @@ }, "DisconnectIntegration": { "id": "DisconnectIntegration", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route/DisconnectIntegration", "children": { "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/DisconnectIntegration/Resource", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route/DisconnectIntegration/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Integration", "aws:cdk:cloudformation:props": { @@ -689,7 +689,7 @@ }, "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/WebSocket API/$disconnect-Route/Resource", + "path": "integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Route", "aws:cdk:cloudformation:props": { @@ -730,11 +730,11 @@ }, "Production Stage": { "id": "Production Stage", - "path": "aws-cdk-aws-apigatewayv2-websockets/Production Stage", + "path": "integ-apigwv2-lambda-connect-integration/Production Stage", "children": { "Resource": { "id": "Resource", - "path": "aws-cdk-aws-apigatewayv2-websockets/Production Stage/Resource", + "path": "integ-apigwv2-lambda-connect-integration/Production Stage/Resource", "attributes": { "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Stage", "aws:cdk:cloudformation:props": { @@ -758,7 +758,7 @@ }, "BootstrapVersion": { "id": "BootstrapVersion", - "path": "aws-cdk-aws-apigatewayv2-websockets/BootstrapVersion", + "path": "integ-apigwv2-lambda-connect-integration/BootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnParameter", "version": "0.0.0" @@ -766,7 +766,7 @@ }, "CheckBootstrapVersion": { "id": "CheckBootstrapVersion", - "path": "aws-cdk-aws-apigatewayv2-websockets/CheckBootstrapVersion", + "path": "integ-apigwv2-lambda-connect-integration/CheckBootstrapVersion", "constructInfo": { "fqn": "aws-cdk-lib.CfnRule", "version": "0.0.0" @@ -778,60 +778,6 @@ "version": "0.0.0" } }, - "Integ": { - "id": "Integ", - "path": "Integ", - "children": { - "DefaultTest": { - "id": "DefaultTest", - "path": "Integ/DefaultTest", - "children": { - "Default": { - "id": "Default", - "path": "Integ/DefaultTest/Default", - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, - "DeployAssert": { - "id": "DeployAssert", - "path": "Integ/DefaultTest/DeployAssert", - "children": { - "BootstrapVersion": { - "id": "BootstrapVersion", - "path": "Integ/DefaultTest/DeployAssert/BootstrapVersion", - "constructInfo": { - "fqn": "aws-cdk-lib.CfnParameter", - "version": "0.0.0" - } - }, - "CheckBootstrapVersion": { - "id": "CheckBootstrapVersion", - "path": "Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", - "constructInfo": { - "fqn": "aws-cdk-lib.CfnRule", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.Stack", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", - "version": "0.0.0" - } - }, "Tree": { "id": "Tree", "path": "Tree", diff --git a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.assets.json b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.assets.json index 89f92e7bd5dc4..8a91333b6e2d2 100644 --- a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.assets.json +++ b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "ea755ac1ccc8e2c8816cf7e0a2b3789e472a166174037cb50eb45ec4ed621ba4": { + "c5abc7ef2e341477218fc19664c82ee2ea13e9509f2deaae6fc6200a619a5d1c": { "source": { "path": "aws-appconfig-environment.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ea755ac1ccc8e2c8816cf7e0a2b3789e472a166174037cb50eb45ec4ed621ba4.json", + "objectKey": "c5abc7ef2e341477218fc19664c82ee2ea13e9509f2deaae6fc6200a619a5d1c.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.template.json b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.template.json index c3951447345b9..e120019dcabe1 100644 --- a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.template.json +++ b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.template.json @@ -18,23 +18,6 @@ "Threshold": 10 } }, - "MyRoleF48FFE04": { - "Type": "AWS::IAM::Role", - "Properties": { - "AssumeRolePolicyDocument": { - "Statement": [ - { - "Action": "sts:AssumeRole", - "Effect": "Allow", - "Principal": { - "Service": "appconfig.amazonaws.com" - } - } - ], - "Version": "2012-10-17" - } - } - }, "MyEnvironmentRole01C8C013F": { "Type": "AWS::IAM::Role", "Properties": { @@ -93,20 +76,6 @@ "Arn" ] } - }, - { - "AlarmArn": { - "Fn::GetAtt": [ - "MyAlarm696658B6", - "Arn" - ] - }, - "AlarmRoleArn": { - "Fn::GetAtt": [ - "MyRoleF48FFE04", - "Arn" - ] - } } ], "Name": "awsappconfigenvironment-MyEnvironment-C8813182" diff --git a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/manifest.json b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/manifest.json index 4c038cd5bcd81..6f758fc4db657 100644 --- a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/manifest.json @@ -14,11 +14,10 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "aws-appconfig-environment.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}/ea755ac1ccc8e2c8816cf7e0a2b3789e472a166174037cb50eb45ec4ed621ba4.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c5abc7ef2e341477218fc19664c82ee2ea13e9509f2deaae6fc6200a619a5d1c.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -46,12 +45,6 @@ "data": "MyAlarm696658B6" } ], - "/aws-appconfig-environment/MyRole/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "MyRoleF48FFE04" - } - ], "/aws-appconfig-environment/MyEnvironment/Role0/Resource": [ { "type": "aws:cdk:logicalId", @@ -92,7 +85,6 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "appconfigenvironmentDefaultTestDeployAssert75BD28E7.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}", diff --git a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/tree.json b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/tree.json index 9b1d723134bbf..730c4e7fb0302 100644 --- a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/tree.json @@ -62,49 +62,6 @@ "version": "0.0.0" } }, - "MyRole": { - "id": "MyRole", - "path": "aws-appconfig-environment/MyRole", - "children": { - "ImportMyRole": { - "id": "ImportMyRole", - "path": "aws-appconfig-environment/MyRole/ImportMyRole", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" - } - }, - "Resource": { - "id": "Resource", - "path": "aws-appconfig-environment/MyRole/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::IAM::Role", - "aws:cdk:cloudformation:props": { - "assumeRolePolicyDocument": { - "Statement": [ - { - "Action": "sts:AssumeRole", - "Effect": "Allow", - "Principal": { - "Service": "appconfig.amazonaws.com" - } - } - ], - "Version": "2012-10-17" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "0.0.0" - } - }, "MyEnvironment": { "id": "MyEnvironment", "path": "aws-appconfig-environment/MyEnvironment", @@ -196,20 +153,6 @@ "Arn" ] } - }, - { - "alarmArn": { - "Fn::GetAtt": [ - "MyAlarm696658B6", - "Arn" - ] - }, - "alarmRoleArn": { - "Fn::GetAtt": [ - "MyRoleF48FFE04", - "Arn" - ] - } } ], "name": "awsappconfigenvironment-MyEnvironment-C8813182" diff --git a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/manifest.json b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/manifest.json index 4cf37e981ad32..769e8e43f6a09 100644 --- a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/manifest.json @@ -14,11 +14,10 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "test-stack.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}/3a62ef659d4a9f7e50c7478aef6b276f52807f55412288d80cd1bd930ad07421.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/f75ab8f9b4f9b4569a43902e069684cc217226d66b42e025930c87f6f6dd1cb4.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -105,6 +104,15 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } + ], + "MyStreamServiceRole8C50608A": [ + { + "type": "aws:cdk:logicalId", + "data": "MyStreamServiceRole8C50608A", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } ] }, "displayName": "test-stack" diff --git a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.assets.json b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.assets.json index 21160bad2321b..889e2678b517e 100644 --- a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.assets.json +++ b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "3a62ef659d4a9f7e50c7478aef6b276f52807f55412288d80cd1bd930ad07421": { + "f75ab8f9b4f9b4569a43902e069684cc217226d66b42e025930c87f6f6dd1cb4": { "source": { "path": "test-stack.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "3a62ef659d4a9f7e50c7478aef6b276f52807f55412288d80cd1bd930ad07421.json", + "objectKey": "f75ab8f9b4f9b4569a43902e069684cc217226d66b42e025930c87f6f6dd1cb4.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.template.json b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.template.json index 8baaeeefaad35..0b0c7bce3882d 100644 --- a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.template.json +++ b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.template.json @@ -231,9 +231,6 @@ "ap-south-1": { "FirehoseCidrBlock": "13.232.67.32/27" }, - "ap-south-2": { - "FirehoseCidrBlock": "18.60.192.128/27" - }, "ap-southeast-1": { "FirehoseCidrBlock": "13.228.64.192/27" }, @@ -258,18 +255,12 @@ "eu-central-1": { "FirehoseCidrBlock": "35.158.127.160/27" }, - "eu-central-2": { - "FirehoseCidrBlock": "16.62.183.32/27" - }, "eu-north-1": { "FirehoseCidrBlock": "13.53.63.224/27" }, "eu-south-1": { "FirehoseCidrBlock": "15.161.135.128/27" }, - "eu-south-2": { - "FirehoseCidrBlock": "18.100.71.96/27" - }, "eu-west-1": { "FirehoseCidrBlock": "52.19.239.192/27" }, diff --git a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/tree.json b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/tree.json index 1a859518058a2..5ad56f532fb0c 100644 --- a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/tree.json @@ -42,8 +42,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iot.CfnTopicRule", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "TopicRuleActionRole": { @@ -54,8 +54,8 @@ "id": "ImportTopicRuleActionRole", "path": "test-stack/TopicRule/TopicRuleActionRole/ImportTopicRuleActionRole", "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Resource": { @@ -79,8 +79,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "DefaultPolicy": { @@ -120,20 +120,20 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, @@ -154,14 +154,14 @@ "aws:cdk:cloudformation:props": {} }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "MyStream": { @@ -176,8 +176,8 @@ "id": "ImportS3 Destination Role", "path": "test-stack/MyStream/S3 Destination Role/ImportS3 Destination Role", "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Resource": { @@ -201,8 +201,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "DefaultPolicy": { @@ -279,20 +279,20 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "LogGroup": { @@ -309,8 +309,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "S3Destination": { @@ -329,20 +329,20 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_logs.CfnLogStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_logs.LogStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_logs.LogGroup", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Resource": { @@ -378,44 +378,44 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "@aws-cdk--aws-kinesisfirehose.CidrBlocks": { "id": "@aws-cdk--aws-kinesisfirehose.CidrBlocks", "path": "test-stack/@aws-cdk--aws-kinesisfirehose.CidrBlocks", "constructInfo": { - "fqn": "aws-cdk-lib.CfnMapping", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "test-stack/BootstrapVersion", "constructInfo": { - "fqn": "aws-cdk-lib.CfnParameter", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "CheckBootstrapVersion": { "id": "CheckBootstrapVersion", "path": "test-stack/CheckBootstrapVersion", "constructInfo": { - "fqn": "aws-cdk-lib.CfnRule", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.Stack", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Tree": { @@ -428,8 +428,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.App", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.assets.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.assets.json index 8fc5583353e4c..bc3086aee09a9 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.assets.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "ccf02c806a025965e36fd920f6dd59f906cb43b81176e2f847cce172076212b7": { + "f08cb1eab080f1654e59530816541dc69a75d3a1248eac16524a832b8a62a463": { "source": { "path": "aws-cdk-firehose-delivery-stream.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ccf02c806a025965e36fd920f6dd59f906cb43b81176e2f847cce172076212b7.json", + "objectKey": "f08cb1eab080f1654e59530816541dc69a75d3a1248eac16524a832b8a62a463.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.template.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.template.json index 93977e3ebd39e..224216bc4fb4c 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.template.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.template.json @@ -234,9 +234,6 @@ "ap-south-1": { "FirehoseCidrBlock": "13.232.67.32/27" }, - "ap-south-2": { - "FirehoseCidrBlock": "18.60.192.128/27" - }, "ap-southeast-1": { "FirehoseCidrBlock": "13.228.64.192/27" }, @@ -261,18 +258,12 @@ "eu-central-1": { "FirehoseCidrBlock": "35.158.127.160/27" }, - "eu-central-2": { - "FirehoseCidrBlock": "16.62.183.32/27" - }, "eu-north-1": { "FirehoseCidrBlock": "13.53.63.224/27" }, "eu-south-1": { "FirehoseCidrBlock": "15.161.135.128/27" }, - "eu-south-2": { - "FirehoseCidrBlock": "18.100.71.96/27" - }, "eu-west-1": { "FirehoseCidrBlock": "52.19.239.192/27" }, diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/manifest.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/manifest.json index a58abbc8bc737..87f0eb72a23d2 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/manifest.json @@ -14,11 +14,10 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "aws-cdk-firehose-delivery-stream.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}/ccf02c806a025965e36fd920f6dd59f906cb43b81176e2f847cce172076212b7.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/f08cb1eab080f1654e59530816541dc69a75d3a1248eac16524a832b8a62a463.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -99,6 +98,15 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } + ], + "DeliveryStreamNoSourceorEncryptionKey49457027": [ + { + "type": "aws:cdk:logicalId", + "data": "DeliveryStreamNoSourceorEncryptionKey49457027", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } ] }, "displayName": "aws-cdk-firehose-delivery-stream" diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/tree.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/tree.json index c31352a0b4ec8..5343e9edb5617 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/tree.json @@ -20,14 +20,14 @@ "aws:cdk:cloudformation:props": {} }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Role": { @@ -38,8 +38,8 @@ "id": "ImportRole", "path": "aws-cdk-firehose-delivery-stream/Role/ImportRole", "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Resource": { @@ -63,8 +63,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "DefaultPolicy": { @@ -128,20 +128,20 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Key": { @@ -185,14 +185,14 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_kms.CfnKey", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_kms.Key", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Delivery Stream": { @@ -207,8 +207,8 @@ "id": "ImportService Role", "path": "aws-cdk-firehose-delivery-stream/Delivery Stream/Service Role/ImportService Role", "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Resource": { @@ -232,8 +232,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "DefaultPolicy": { @@ -275,20 +275,20 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Resource": { @@ -324,22 +324,22 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "@aws-cdk--aws-kinesisfirehose.CidrBlocks": { "id": "@aws-cdk--aws-kinesisfirehose.CidrBlocks", "path": "aws-cdk-firehose-delivery-stream/@aws-cdk--aws-kinesisfirehose.CidrBlocks", "constructInfo": { - "fqn": "aws-cdk-lib.CfnMapping", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Delivery Stream No Source Or Encryption Key": { @@ -370,36 +370,36 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "aws-cdk-firehose-delivery-stream/BootstrapVersion", "constructInfo": { - "fqn": "aws-cdk-lib.CfnParameter", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "CheckBootstrapVersion": { "id": "CheckBootstrapVersion", "path": "aws-cdk-firehose-delivery-stream/CheckBootstrapVersion", "constructInfo": { - "fqn": "aws-cdk-lib.CfnRule", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.Stack", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Tree": { @@ -412,8 +412,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.App", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.assets.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.assets.json index 532ba9af438ca..d539b8c1f38c4 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.assets.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "0b8a49e0b01e92c6b238e6d77538735e5b7a45a5bd1b32808ce9fe81fccc7c2e": { + "64eae3903c3ecdce5113c92844e63dfd0056464ecf7d1351e86180364d20c1c0": { "source": { "path": "aws-cdk-firehose-delivery-stream-source-stream.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0b8a49e0b01e92c6b238e6d77538735e5b7a45a5bd1b32808ce9fe81fccc7c2e.json", + "objectKey": "64eae3903c3ecdce5113c92844e63dfd0056464ecf7d1351e86180364d20c1c0.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.template.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.template.json index ec035f738f940..cbf990668d7bf 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.template.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.template.json @@ -250,9 +250,6 @@ "ap-south-1": { "FirehoseCidrBlock": "13.232.67.32/27" }, - "ap-south-2": { - "FirehoseCidrBlock": "18.60.192.128/27" - }, "ap-southeast-1": { "FirehoseCidrBlock": "13.228.64.192/27" }, @@ -277,18 +274,12 @@ "eu-central-1": { "FirehoseCidrBlock": "35.158.127.160/27" }, - "eu-central-2": { - "FirehoseCidrBlock": "16.62.183.32/27" - }, "eu-north-1": { "FirehoseCidrBlock": "13.53.63.224/27" }, "eu-south-1": { "FirehoseCidrBlock": "15.161.135.128/27" }, - "eu-south-2": { - "FirehoseCidrBlock": "18.100.71.96/27" - }, "eu-west-1": { "FirehoseCidrBlock": "52.19.239.192/27" }, diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/manifest.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/manifest.json index 384d8d7856b19..0a7108ae6b432 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/manifest.json @@ -14,11 +14,10 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "aws-cdk-firehose-delivery-stream-source-stream.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}/0b8a49e0b01e92c6b238e6d77538735e5b7a45a5bd1b32808ce9fe81fccc7c2e.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/64eae3903c3ecdce5113c92844e63dfd0056464ecf7d1351e86180364d20c1c0.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -105,6 +104,15 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } + ], + "DeliveryStreamNoSourceorEncryptionKey49457027": [ + { + "type": "aws:cdk:logicalId", + "data": "DeliveryStreamNoSourceorEncryptionKey49457027", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" + ] + } ] }, "displayName": "aws-cdk-firehose-delivery-stream-source-stream" diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/tree.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/tree.json index b4a43bb9ac2cd..f097397ad370a 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/tree.json @@ -20,14 +20,14 @@ "aws:cdk:cloudformation:props": {} }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3.CfnBucket", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3.Bucket", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Role": { @@ -38,8 +38,8 @@ "id": "ImportRole", "path": "aws-cdk-firehose-delivery-stream-source-stream/Role/ImportRole", "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Resource": { @@ -63,8 +63,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "DefaultPolicy": { @@ -128,20 +128,20 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Source Stream": { @@ -171,22 +171,22 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_kinesis.Stream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "AwsCdkKinesisEncryptedStreamsUnsupportedRegions": { "id": "AwsCdkKinesisEncryptedStreamsUnsupportedRegions", "path": "aws-cdk-firehose-delivery-stream-source-stream/AwsCdkKinesisEncryptedStreamsUnsupportedRegions", "constructInfo": { - "fqn": "aws-cdk-lib.CfnCondition", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Delivery Stream": { @@ -201,8 +201,8 @@ "id": "ImportService Role", "path": "aws-cdk-firehose-delivery-stream-source-stream/Delivery Stream/Service Role/ImportService Role", "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Resource": { @@ -226,8 +226,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnRole", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "DefaultPolicy": { @@ -273,20 +273,20 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Policy", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Role", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Resource": { @@ -327,22 +327,22 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "@aws-cdk--aws-kinesisfirehose.CidrBlocks": { "id": "@aws-cdk--aws-kinesisfirehose.CidrBlocks", "path": "aws-cdk-firehose-delivery-stream-source-stream/@aws-cdk--aws-kinesisfirehose.CidrBlocks", "constructInfo": { - "fqn": "aws-cdk-lib.CfnMapping", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Delivery Stream No Source Or Encryption Key": { @@ -373,36 +373,36 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "aws-cdk-firehose-delivery-stream-source-stream/BootstrapVersion", "constructInfo": { - "fqn": "aws-cdk-lib.CfnParameter", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "CheckBootstrapVersion": { "id": "CheckBootstrapVersion", "path": "aws-cdk-firehose-delivery-stream-source-stream/CheckBootstrapVersion", "constructInfo": { - "fqn": "aws-cdk-lib.CfnRule", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.Stack", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } }, "Tree": { @@ -415,8 +415,8 @@ } }, "constructInfo": { - "fqn": "aws-cdk-lib.App", - "version": "0.0.0" + "fqn": "constructs.Construct", + "version": "10.2.70" } } } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.assets.json b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.assets.json index 488de330f9d78..f425131be7a56 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.assets.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.assets.json @@ -27,7 +27,7 @@ } } }, - "a05127e41968d710aab4219add6693dd03376b7bae654f9ffe291a21f2aa7c68": { + "97e34fe63eef055d8f840edf2516da35e7a8f0f440303c76d3cde0daa3393f44": { "source": { "path": "aws-cdk-firehose-delivery-stream-s3-all-properties.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "a05127e41968d710aab4219add6693dd03376b7bae654f9ffe291a21f2aa7c68.json", + "objectKey": "97e34fe63eef055d8f840edf2516da35e7a8f0f440303c76d3cde0daa3393f44.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.template.json b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.template.json index c3180c9549c1a..bcb74d8545e22 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.template.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.template.json @@ -702,9 +702,6 @@ "ap-south-1": { "FirehoseCidrBlock": "13.232.67.32/27" }, - "ap-south-2": { - "FirehoseCidrBlock": "18.60.192.128/27" - }, "ap-southeast-1": { "FirehoseCidrBlock": "13.228.64.192/27" }, @@ -729,18 +726,12 @@ "eu-central-1": { "FirehoseCidrBlock": "35.158.127.160/27" }, - "eu-central-2": { - "FirehoseCidrBlock": "16.62.183.32/27" - }, "eu-north-1": { "FirehoseCidrBlock": "13.53.63.224/27" }, "eu-south-1": { "FirehoseCidrBlock": "15.161.135.128/27" }, - "eu-south-2": { - "FirehoseCidrBlock": "18.100.71.96/27" - }, "eu-west-1": { "FirehoseCidrBlock": "52.19.239.192/27" }, diff --git a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/manifest.json b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/manifest.json index d1e730609d35e..89ac63fbec554 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/manifest.json @@ -18,7 +18,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}/a05127e41968d710aab4219add6693dd03376b7bae654f9ffe291a21f2aa7c68.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/97e34fe63eef055d8f840edf2516da35e7a8f0f440303c76d3cde0daa3393f44.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.assets.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.assets.json index 9c12eb7d9b585..7d8aaf4c06d21 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.assets.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.assets.json @@ -1,7 +1,7 @@ { "version": "33.0.0", "files": { - "70a4ff6207a6b7ce2e7a4354be513e0143bb5f5c671d6826cfb30c010875e4bd": { + "99b9aff7b7d42e6c47dd13d7034964f12b93cbe638fde0815e636313a0e7c9b0": { "source": { "path": "aws-cdk-scheduler-schedule.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "70a4ff6207a6b7ce2e7a4354be513e0143bb5f5c671d6826cfb30c010875e4bd.json", + "objectKey": "99b9aff7b7d42e6c47dd13d7034964f12b93cbe638fde0815e636313a0e7c9b0.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.template.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.template.json index e27219e674e1d..69f6f034ea5c6 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.template.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.template.json @@ -114,11 +114,6 @@ "Arn" ] }, - "Input": "\"Input Text\"", - "RetryPolicy": { - "MaximumEventAgeInSeconds": 180, - "MaximumRetryAttempts": 3 - }, "RoleArn": { "Fn::GetAtt": [ "Role1ABCC5F0", @@ -144,41 +139,6 @@ "Arn" ] }, - "Input": "\"Input Text\"", - "RetryPolicy": { - "MaximumEventAgeInSeconds": 180, - "MaximumRetryAttempts": 3 - }, - "RoleArn": { - "Fn::GetAtt": [ - "Role1ABCC5F0", - "Arn" - ] - } - } - } - }, - "TargetOverrideScheduleFF8CB184": { - "Type": "AWS::Scheduler::Schedule", - "Properties": { - "FlexibleTimeWindow": { - "Mode": "OFF" - }, - "ScheduleExpression": "rate(12 hours)", - "ScheduleExpressionTimezone": "Etc/UTC", - "State": "ENABLED", - "Target": { - "Arn": { - "Fn::GetAtt": [ - "Function76856677", - "Arn" - ] - }, - "Input": "\"Changed Text\"", - "RetryPolicy": { - "MaximumEventAgeInSeconds": 360, - "MaximumRetryAttempts": 5 - }, "RoleArn": { "Fn::GetAtt": [ "Role1ABCC5F0", @@ -257,11 +217,6 @@ "Arn" ] }, - "Input": "\"Input Text\"", - "RetryPolicy": { - "MaximumEventAgeInSeconds": 180, - "MaximumRetryAttempts": 3 - }, "RoleArn": { "Fn::GetAtt": [ "Role1ABCC5F0", diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/manifest.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/manifest.json index 9e6c88e76c10e..89f544c6f0432 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/manifest.json @@ -18,7 +18,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}/70a4ff6207a6b7ce2e7a4354be513e0143bb5f5c671d6826cfb30c010875e4bd.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/99b9aff7b7d42e6c47dd13d7034964f12b93cbe638fde0815e636313a0e7c9b0.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -70,12 +70,6 @@ "data": "DisabledScheduleA1DF7F0F" } ], - "/aws-cdk-scheduler-schedule/TargetOverrideSchedule/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "TargetOverrideScheduleFF8CB184" - } - ], "/aws-cdk-scheduler-schedule/AllSchedulerErrorsAlarm/Resource": [ { "type": "aws:cdk:logicalId", diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/tree.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/tree.json index 3f5cd77076180..a16dc5b4a296f 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/tree.json @@ -219,11 +219,6 @@ "Role1ABCC5F0", "Arn" ] - }, - "input": "\"Input Text\"", - "retryPolicy": { - "maximumEventAgeInSeconds": 180, - "maximumRetryAttempts": 3 } } } @@ -267,59 +262,6 @@ "Role1ABCC5F0", "Arn" ] - }, - "input": "\"Input Text\"", - "retryPolicy": { - "maximumEventAgeInSeconds": 180, - "maximumRetryAttempts": 3 - } - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_scheduler.CfnSchedule", - "version": "0.0.0" - } - } - }, - "constructInfo": { - "fqn": "@aws-cdk/aws-scheduler-alpha.Schedule", - "version": "0.0.0" - } - }, - "TargetOverrideSchedule": { - "id": "TargetOverrideSchedule", - "path": "aws-cdk-scheduler-schedule/TargetOverrideSchedule", - "children": { - "Resource": { - "id": "Resource", - "path": "aws-cdk-scheduler-schedule/TargetOverrideSchedule/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::Scheduler::Schedule", - "aws:cdk:cloudformation:props": { - "flexibleTimeWindow": { - "mode": "OFF" - }, - "scheduleExpression": "rate(12 hours)", - "scheduleExpressionTimezone": "Etc/UTC", - "state": "ENABLED", - "target": { - "arn": { - "Fn::GetAtt": [ - "Function76856677", - "Arn" - ] - }, - "roleArn": { - "Fn::GetAtt": [ - "Role1ABCC5F0", - "Arn" - ] - }, - "input": "\"Changed Text\"", - "retryPolicy": { - "maximumEventAgeInSeconds": 360, - "maximumRetryAttempts": 5 } } } From bdc692bd7d363533f7a48ff90f9c9ae9dd6cacb8 Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 31 Oct 2023 11:34:56 -0400 Subject: [PATCH 11/15] use integ test construct Signed-off-by: Sumu --- .../websocket/integ.lambda-connect-disconnect-trigger.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts index cf4a7ac538727..5509c4e321fbc 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts @@ -1,5 +1,6 @@ import { WebSocketApi, WebSocketStage } from '@aws-cdk/aws-apigatewayv2-alpha'; import * as cdk from 'aws-cdk-lib'; +import { IntegTest } from '@aws-cdk/integ-tests-alpha'; import { WebSocketLambdaIntegration } from '../../lib'; import * as lambda from 'aws-cdk-lib/aws-lambda'; import * as path from 'path'; @@ -73,4 +74,6 @@ new WebSocketStage( stageName: 'prod', autoDeploy: true, }, -); \ No newline at end of file +); + +new IntegTest(app, 'Integ', { testCases: [stack] }); \ No newline at end of file From 5769e249a1458b96255a63ebce4546912d52abbc Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 31 Oct 2023 12:14:02 -0400 Subject: [PATCH 12/15] update snapshots again, trying to get build to succeed Signed-off-by: Sumu --- .../AuthorizerInteg.assets.json | 4 +- .../AuthorizerInteg.template.json | 279 +++++++++-- .../integ.lambda.js.snapshot/manifest.json | 93 ++-- .../http/integ.lambda.js.snapshot/tree.json | 437 +++++++++++++++--- .../AuthorizerInteg.assets.json | 4 +- .../AuthorizerInteg.template.json | 290 ++++++++++-- .../integ.user-pool.js.snapshot/manifest.json | 106 ++--- .../integ.user-pool.js.snapshot/tree.json | 432 ++++++++++++++--- .../IntegApiGatewayV2Iam.assets.json | 4 +- .../IntegApiGatewayV2Iam.template.json | 2 +- .../integ.iam.js.snapshot/manifest.json | 2 +- .../websocket/integ.iam.js.snapshot/tree.json | 2 +- ...efaultTestDeployAssert4E6713E1.assets.json | 19 + ...aultTestDeployAssert4E6713E1.template.json | 36 ++ .../package.json | 0 .../index.js | 32 -- .../package.json | 0 .../index.js | 26 -- ...wv2-lambda-connect-integration.assets.json | 16 +- ...2-lambda-connect-integration.template.json | 8 +- .../integ.json | 10 +- .../manifest.json | 60 ++- .../tree.json | 62 ++- .../WebSocketApiInteg.assets.json | 4 +- .../WebSocketApiInteg.template.json | 8 +- .../integ.lambda.js.snapshot/manifest.json | 2 +- .../integ.lambda.js.snapshot/tree.json | 8 +- .../aws-appconfig-environment.assets.json | 4 +- .../aws-appconfig-environment.template.json | 31 ++ .../manifest.json | 10 +- .../integ.environment.js.snapshot/tree.json | 57 +++ .../manifest.json | 12 +- .../test-stack.assets.json | 4 +- .../test-stack.template.json | 9 + .../tree.json | 96 ++-- ...s-cdk-firehose-delivery-stream.assets.json | 4 +- ...cdk-firehose-delivery-stream.template.json | 9 + .../manifest.json | 12 +- .../tree.json | 92 ++-- ...-delivery-stream-source-stream.assets.json | 4 +- ...elivery-stream-source-stream.template.json | 9 + .../manifest.json | 12 +- .../tree.json | 96 ++-- ...ivery-stream-s3-all-properties.assets.json | 4 +- ...ery-stream-s3-all-properties.template.json | 9 + .../manifest.json | 2 +- .../aws-cdk-scheduler-schedule.assets.json | 6 +- .../aws-cdk-scheduler-schedule.template.json | 45 ++ .../test/integ.schedule.js.snapshot/cdk.out | 2 +- .../integ.schedule.js.snapshot/integ.json | 2 +- ...efaultTestDeployAssert24CB3896.assets.json | 2 +- .../integ.schedule.js.snapshot/manifest.json | 10 +- .../test/integ.schedule.js.snapshot/tree.json | 63 +++ 53 files changed, 1916 insertions(+), 636 deletions(-) create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json create mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json rename packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/{asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07 => asset.2748a200bf25c8ee2c2898271226a9f7bdc386b8ce9669528731eb36c5ed9e28}/package.json (100%) delete mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/index.js rename packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/{asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c => asset.e593848af17fee558eece2cd2719347804c0c141cff4f8ea1fb8556cf986b5a0}/package.json (100%) delete mode 100644 packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/index.js diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.assets.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.assets.json index b1fa6727810e1..08bff1e7a6f72 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.assets.json @@ -27,7 +27,7 @@ } } }, - "d494d0e4b4be2192ea2cc4c56ea29fa7d0f23e45c006cb05eedae57d8a42cf78": { + "1392f7df97b60ac420a8ba97f1d6ac2f6e984a168d85bb763108846d396c6553": { "source": { "path": "AuthorizerInteg.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "d494d0e4b4be2192ea2cc4c56ea29fa7d0f23e45c006cb05eedae57d8a42cf78.json", + "objectKey": "1392f7df97b60ac420a8ba97f1d6ac2f6e984a168d85bb763108846d396c6553.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.template.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.template.json index 57ae669b6f247..002fb57113411 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/AuthorizerInteg.template.json @@ -1,5 +1,58 @@ { "Resources": { + "authfunctionServiceRoleFCB72198": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "lambda.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "ManagedPolicyArns": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" + ] + ] + } + ] + } + }, + "authfunction96361832": { + "Type": "AWS::Lambda::Function", + "Properties": { + "Code": { + "S3Bucket": { + "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" + }, + "S3Key": "d7d3785243d748927f2a8d6edcecf909f96191df27a815e305aaeba98bcd2c64.zip" + }, + "Handler": "index.handler", + "Role": { + "Fn::GetAtt": [ + "authfunctionServiceRoleFCB72198", + "Arn" + ] + }, + "Runtime": "nodejs18.x" + }, + "DependsOn": [ + "authfunctionServiceRoleFCB72198" + ] + }, "MyHttpApi8AEAAC21": { "Type": "AWS::ApiGatewayV2::Api", "Properties": { @@ -173,58 +226,101 @@ } } }, - "authfunctionServiceRoleFCB72198": { - "Type": "AWS::IAM::Role", + "MyHttpApiWithDefaultAuthorizerE08800A1": { + "Type": "AWS::ApiGatewayV2::Api", "Properties": { - "AssumeRolePolicyDocument": { - "Statement": [ - { - "Action": "sts:AssumeRole", - "Effect": "Allow", - "Principal": { - "Service": "lambda.amazonaws.com" - } - } - ], - "Version": "2012-10-17" + "Name": "MyHttpApiWithDefaultAuthorizer", + "ProtocolType": "HTTP" + } + }, + "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6": { + "Type": "AWS::ApiGatewayV2::Stage", + "Properties": { + "ApiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" }, - "ManagedPolicyArns": [ - { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" - ] - ] - } - ] + "AutoDeploy": true, + "StageName": "$default" } }, - "authfunction96361832": { - "Type": "AWS::Lambda::Function", + "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65": { + "Type": "AWS::ApiGatewayV2::Authorizer", "Properties": { - "Code": { - "S3Bucket": { - "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" - }, - "S3Key": "d7d3785243d748927f2a8d6edcecf909f96191df27a815e305aaeba98bcd2c64.zip" + "ApiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" }, - "Handler": "index.handler", - "Role": { + "AuthorizerPayloadFormatVersion": "2.0", + "AuthorizerResultTtlInSeconds": 300, + "AuthorizerType": "REQUEST", + "AuthorizerUri": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":apigateway:", + { + "Ref": "AWS::Region" + }, + ":lambda:path/2015-03-31/functions/", + { + "Fn::GetAtt": [ + "authfunction96361832", + "Arn" + ] + }, + "/invocations" + ] + ] + }, + "EnableSimpleResponses": true, + "IdentitySource": [ + "$request.header.X-API-Key" + ], + "Name": "my-simple-authorizer" + } + }, + "MyHttpApiWithDefaultAuthorizerAuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35Permission700DB59D": { + "Type": "AWS::Lambda::Permission", + "Properties": { + "Action": "lambda:InvokeFunction", + "FunctionName": { "Fn::GetAtt": [ - "authfunctionServiceRoleFCB72198", + "authfunction96361832", "Arn" ] }, - "Runtime": "nodejs18.x" - }, - "DependsOn": [ - "authfunctionServiceRoleFCB72198" - ] + "Principal": "apigateway.amazonaws.com", + "SourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "/authorizers/", + { + "Ref": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" + } + ] + ] + } + } }, "lambdaServiceRole494E4CA6": { "Type": "AWS::IAM::Role", @@ -278,6 +374,83 @@ "DependsOn": [ "lambdaServiceRole494E4CA6" ] + }, + "RouteRootIntegration1CF58575": { + "Type": "AWS::ApiGatewayV2::Integration", + "Properties": { + "ApiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "IntegrationType": "AWS_PROXY", + "IntegrationUri": { + "Fn::GetAtt": [ + "lambda8B5974B5", + "Arn" + ] + }, + "PayloadFormatVersion": "2.0" + } + }, + "RouteRootIntegrationPermissionC2C15701": { + "Type": "AWS::Lambda::Permission", + "Properties": { + "Action": "lambda:InvokeFunction", + "FunctionName": { + "Fn::GetAtt": [ + "lambda8B5974B5", + "Arn" + ] + }, + "Principal": "apigateway.amazonaws.com", + "SourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "/*/*/v1/mything/{proxy+}" + ] + ] + } + } + }, + "RouteA67450D2": { + "Type": "AWS::ApiGatewayV2::Route", + "Properties": { + "ApiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "AuthorizationType": "CUSTOM", + "AuthorizerId": { + "Ref": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" + }, + "RouteKey": "ANY /v1/mything/{proxy+}", + "Target": { + "Fn::Join": [ + "", + [ + "integrations/", + { + "Ref": "RouteRootIntegration1CF58575" + } + ] + ] + } + } } }, "Outputs": { @@ -302,6 +475,28 @@ ] ] } + }, + "URLWithDefaultAuthorizer": { + "Value": { + "Fn::Join": [ + "", + [ + "https://", + { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + ".execute-api.", + { + "Ref": "AWS::Region" + }, + ".", + { + "Ref": "AWS::URLSuffix" + }, + "/" + ] + ] + } } }, "Parameters": { diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/manifest.json index e1e448b30404c..9636d2c7f226b 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/manifest.json @@ -18,7 +18,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}/d494d0e4b4be2192ea2cc4c56ea29fa7d0f23e45c006cb05eedae57d8a42cf78.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/1392f7df97b60ac420a8ba97f1d6ac2f6e984a168d85bb763108846d396c6553.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -34,6 +34,18 @@ "AuthorizerInteg.assets" ], "metadata": { + "/AuthorizerInteg/auth-function/ServiceRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "authfunctionServiceRoleFCB72198" + } + ], + "/AuthorizerInteg/auth-function/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "authfunction96361832" + } + ], "/AuthorizerInteg/MyHttpApi/Resource": [ { "type": "aws:cdk:logicalId", @@ -76,109 +88,82 @@ "data": "MyHttpApiAuthorizerIntegMyHttpApiLambdaAuthorizerB89228D7Permission82260331" } ], - "/AuthorizerInteg/auth-function/ServiceRole/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "authfunctionServiceRoleFCB72198" - } - ], - "/AuthorizerInteg/auth-function/Resource": [ + "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/Resource": [ { "type": "aws:cdk:logicalId", - "data": "authfunction96361832" + "data": "MyHttpApiWithDefaultAuthorizerE08800A1" } ], - "/AuthorizerInteg/lambda/ServiceRole/Resource": [ + "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage/Resource": [ { "type": "aws:cdk:logicalId", - "data": "lambdaServiceRole494E4CA6" + "data": "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6" } ], - "/AuthorizerInteg/lambda/Resource": [ + "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/LambdaDefaultAuthorizer/Resource": [ { "type": "aws:cdk:logicalId", - "data": "lambda8B5974B5" + "data": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" } ], - "/AuthorizerInteg/URL": [ + "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/AuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35-Permission": [ { "type": "aws:cdk:logicalId", - "data": "URL" + "data": "MyHttpApiWithDefaultAuthorizerAuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35Permission700DB59D" } ], - "/AuthorizerInteg/BootstrapVersion": [ + "/AuthorizerInteg/lambda/ServiceRole/Resource": [ { "type": "aws:cdk:logicalId", - "data": "BootstrapVersion" + "data": "lambdaServiceRole494E4CA6" } ], - "/AuthorizerInteg/CheckBootstrapVersion": [ + "/AuthorizerInteg/lambda/Resource": [ { "type": "aws:cdk:logicalId", - "data": "CheckBootstrapVersion" + "data": "lambda8B5974B5" } ], - "MyHttpApiWithDefaultAuthorizerE08800A1": [ + "/AuthorizerInteg/Route/RootIntegration/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerE08800A1", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "RouteRootIntegration1CF58575" } ], - "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6": [ + "/AuthorizerInteg/Route/RootIntegration-Permission": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "RouteRootIntegrationPermissionC2C15701" } ], - "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65": [ + "/AuthorizerInteg/Route/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "RouteA67450D2" } ], - "MyHttpApiWithDefaultAuthorizerAuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35Permission700DB59D": [ + "/AuthorizerInteg/URL": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerAuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35Permission700DB59D", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "URL" } ], - "RouteRootIntegration1CF58575": [ + "/AuthorizerInteg/URLWithDefaultAuthorizer": [ { "type": "aws:cdk:logicalId", - "data": "RouteRootIntegration1CF58575", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "URLWithDefaultAuthorizer" } ], - "RouteRootIntegrationPermissionC2C15701": [ + "/AuthorizerInteg/BootstrapVersion": [ { "type": "aws:cdk:logicalId", - "data": "RouteRootIntegrationPermissionC2C15701", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "BootstrapVersion" } ], - "RouteA67450D2": [ + "/AuthorizerInteg/CheckBootstrapVersion": [ { "type": "aws:cdk:logicalId", - "data": "RouteA67450D2", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "CheckBootstrapVersion" } ] }, diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/tree.json index f1f64644ef4af..08ec1606edb94 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.lambda.js.snapshot/tree.json @@ -8,6 +8,126 @@ "id": "AuthorizerInteg", "path": "AuthorizerInteg", "children": { + "auth-function": { + "id": "auth-function", + "path": "AuthorizerInteg/auth-function", + "children": { + "ServiceRole": { + "id": "ServiceRole", + "path": "AuthorizerInteg/auth-function/ServiceRole", + "children": { + "ImportServiceRole": { + "id": "ImportServiceRole", + "path": "AuthorizerInteg/auth-function/ServiceRole/ImportServiceRole", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/auth-function/ServiceRole/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" + }, + "managedPolicyArns": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" + ] + ] + } + ] + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" + } + }, + "Code": { + "id": "Code", + "path": "AuthorizerInteg/auth-function/Code", + "children": { + "Stage": { + "id": "Stage", + "path": "AuthorizerInteg/auth-function/Code/Stage", + "constructInfo": { + "fqn": "aws-cdk-lib.AssetStaging", + "version": "0.0.0" + } + }, + "AssetBucket": { + "id": "AssetBucket", + "path": "AuthorizerInteg/auth-function/Code/AssetBucket", + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3.BucketBase", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_s3_assets.Asset", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/auth-function/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": "d7d3785243d748927f2a8d6edcecf909f96191df27a815e305aaeba98bcd2c64.zip" + }, + "handler": "index.handler", + "role": { + "Fn::GetAtt": [ + "authfunctionServiceRoleFCB72198", + "Arn" + ] + }, + "runtime": "nodejs18.x" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.Function", + "version": "0.0.0" + } + }, "MyHttpApi": { "id": "MyHttpApi", "path": "AuthorizerInteg/MyHttpApi", @@ -287,123 +407,161 @@ "version": "0.0.0" } }, - "auth-function": { - "id": "auth-function", - "path": "AuthorizerInteg/auth-function", + "MyHttpApiWithDefaultAuthorizer": { + "id": "MyHttpApiWithDefaultAuthorizer", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer", "children": { - "ServiceRole": { - "id": "ServiceRole", - "path": "AuthorizerInteg/auth-function/ServiceRole", + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Api", + "aws:cdk:cloudformation:props": { + "name": "MyHttpApiWithDefaultAuthorizer", + "protocolType": "HTTP" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnApi", + "version": "0.0.0" + } + }, + "DefaultStage": { + "id": "DefaultStage", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage", "children": { - "ImportServiceRole": { - "id": "ImportServiceRole", - "path": "AuthorizerInteg/auth-function/ServiceRole/ImportServiceRole", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "0.0.0" - } - }, "Resource": { "id": "Resource", - "path": "AuthorizerInteg/auth-function/ServiceRole/Resource", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage/Resource", "attributes": { - "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Stage", "aws:cdk:cloudformation:props": { - "assumeRolePolicyDocument": { - "Statement": [ - { - "Action": "sts:AssumeRole", - "Effect": "Allow", - "Principal": { - "Service": "lambda.amazonaws.com" - } - } - ], - "Version": "2012-10-17" + "apiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" }, - "managedPolicyArns": [ - { - "Fn::Join": [ - "", - [ - "arn:", - { - "Ref": "AWS::Partition" - }, - ":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" - ] - ] - } - ] + "autoDeploy": true, + "stageName": "$default" } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnStage", "version": "0.0.0" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_iam.Role", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpStage", "version": "0.0.0" } }, - "Code": { - "id": "Code", - "path": "AuthorizerInteg/auth-function/Code", + "LambdaDefaultAuthorizer": { + "id": "LambdaDefaultAuthorizer", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/LambdaDefaultAuthorizer", "children": { - "Stage": { - "id": "Stage", - "path": "AuthorizerInteg/auth-function/Code/Stage", - "constructInfo": { - "fqn": "aws-cdk-lib.AssetStaging", - "version": "0.0.0" - } - }, - "AssetBucket": { - "id": "AssetBucket", - "path": "AuthorizerInteg/auth-function/Code/AssetBucket", + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/LambdaDefaultAuthorizer/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Authorizer", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "authorizerPayloadFormatVersion": "2.0", + "authorizerResultTtlInSeconds": 300, + "authorizerType": "REQUEST", + "authorizerUri": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":apigateway:", + { + "Ref": "AWS::Region" + }, + ":lambda:path/2015-03-31/functions/", + { + "Fn::GetAtt": [ + "authfunction96361832", + "Arn" + ] + }, + "/invocations" + ] + ] + }, + "enableSimpleResponses": true, + "identitySource": [ + "$request.header.X-API-Key" + ], + "name": "my-simple-authorizer" + } + }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3.BucketBase", + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnAuthorizer", "version": "0.0.0" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_s3_assets.Asset", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpAuthorizer", "version": "0.0.0" } }, - "Resource": { - "id": "Resource", - "path": "AuthorizerInteg/auth-function/Resource", + "AuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35-Permission": { + "id": "AuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35-Permission", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/AuthorizerIntegMyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer1BC6EA35-Permission", "attributes": { - "aws:cdk:cloudformation:type": "AWS::Lambda::Function", + "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", "aws:cdk:cloudformation:props": { - "code": { - "s3Bucket": { - "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" - }, - "s3Key": "d7d3785243d748927f2a8d6edcecf909f96191df27a815e305aaeba98bcd2c64.zip" - }, - "handler": "index.handler", - "role": { + "action": "lambda:InvokeFunction", + "functionName": { "Fn::GetAtt": [ - "authfunctionServiceRoleFCB72198", + "authfunction96361832", "Arn" ] }, - "runtime": "nodejs18.x" + "principal": "apigateway.amazonaws.com", + "sourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "/authorizers/", + { + "Ref": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" + } + ] + ] + } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_lambda.CfnFunction", + "fqn": "aws-cdk-lib.aws_lambda.CfnPermission", "version": "0.0.0" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_lambda.Function", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpApi", "version": "0.0.0" } }, @@ -527,6 +685,127 @@ "version": "0.0.0" } }, + "Route": { + "id": "Route", + "path": "AuthorizerInteg/Route", + "children": { + "RootIntegration": { + "id": "RootIntegration", + "path": "AuthorizerInteg/Route/RootIntegration", + "children": { + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/Route/RootIntegration/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Integration", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "integrationType": "AWS_PROXY", + "integrationUri": { + "Fn::GetAtt": [ + "lambda8B5974B5", + "Arn" + ] + }, + "payloadFormatVersion": "2.0" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnIntegration", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpIntegration", + "version": "0.0.0" + } + }, + "RootIntegration-Permission": { + "id": "RootIntegration-Permission", + "path": "AuthorizerInteg/Route/RootIntegration-Permission", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", + "aws:cdk:cloudformation:props": { + "action": "lambda:InvokeFunction", + "functionName": { + "Fn::GetAtt": [ + "lambda8B5974B5", + "Arn" + ] + }, + "principal": "apigateway.amazonaws.com", + "sourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "/*/*/v1/mything/{proxy+}" + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.CfnPermission", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/Route/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Route", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "authorizationType": "CUSTOM", + "authorizerId": { + "Ref": "MyHttpApiWithDefaultAuthorizerLambdaDefaultAuthorizer9D407E65" + }, + "routeKey": "ANY /v1/mything/{proxy+}", + "target": { + "Fn::Join": [ + "", + [ + "integrations/", + { + "Ref": "RouteRootIntegration1CF58575" + } + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnRoute", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpRoute", + "version": "0.0.0" + } + }, "URL": { "id": "URL", "path": "AuthorizerInteg/URL", @@ -535,6 +814,14 @@ "version": "0.0.0" } }, + "URLWithDefaultAuthorizer": { + "id": "URLWithDefaultAuthorizer", + "path": "AuthorizerInteg/URLWithDefaultAuthorizer", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnOutput", + "version": "0.0.0" + } + }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "AuthorizerInteg/BootstrapVersion", diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.assets.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.assets.json index 2f81bb685edcc..523c011b3c99d 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.assets.json @@ -14,7 +14,7 @@ } } }, - "0847c0b726780e7b084297b7c2323b91c608e241e019e9d3e0bf62fcfd673c8d": { + "8e1b12f5d12c6de951105961b92d6c971a32d4cbbc394e1542bcbedf77450978": { "source": { "path": "AuthorizerInteg.template.json", "packaging": "file" @@ -22,7 +22,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0847c0b726780e7b084297b7c2323b91c608e241e019e9d3e0bf62fcfd673c8d.json", + "objectKey": "8e1b12f5d12c6de951105961b92d6c971a32d4cbbc394e1542bcbedf77450978.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.template.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.template.json index 10025f453c775..e3d22ec70cf41 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/AuthorizerInteg.template.json @@ -1,5 +1,119 @@ { "Resources": { + "userpool0AC4AA96": { + "Type": "AWS::Cognito::UserPool", + "Properties": { + "AccountRecoverySetting": { + "RecoveryMechanisms": [ + { + "Name": "verified_phone_number", + "Priority": 1 + }, + { + "Name": "verified_email", + "Priority": 2 + } + ] + }, + "AdminCreateUserConfig": { + "AllowAdminCreateUserOnly": true + }, + "EmailVerificationMessage": "The verification code to your new account is {####}", + "EmailVerificationSubject": "Verify your new account", + "SmsVerificationMessage": "The verification code to your new account is {####}", + "VerificationMessageTemplate": { + "DefaultEmailOption": "CONFIRM_WITH_CODE", + "EmailMessage": "The verification code to your new account is {####}", + "EmailSubject": "Verify your new account", + "SmsMessage": "The verification code to your new account is {####}" + } + }, + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" + }, + "userpoolUserPoolAuthorizerClient6A7486E8": { + "Type": "AWS::Cognito::UserPoolClient", + "Properties": { + "AllowedOAuthFlows": [ + "implicit", + "code" + ], + "AllowedOAuthFlowsUserPoolClient": true, + "AllowedOAuthScopes": [ + "profile", + "phone", + "email", + "openid", + "aws.cognito.signin.user.admin" + ], + "CallbackURLs": [ + "https://example.com" + ], + "SupportedIdentityProviders": [ + "COGNITO" + ], + "UserPoolId": { + "Ref": "userpool0AC4AA96" + } + } + }, + "userpoolForDefaultAuthorizerDFBE8E74": { + "Type": "AWS::Cognito::UserPool", + "Properties": { + "AccountRecoverySetting": { + "RecoveryMechanisms": [ + { + "Name": "verified_phone_number", + "Priority": 1 + }, + { + "Name": "verified_email", + "Priority": 2 + } + ] + }, + "AdminCreateUserConfig": { + "AllowAdminCreateUserOnly": true + }, + "EmailVerificationMessage": "The verification code to your new account is {####}", + "EmailVerificationSubject": "Verify your new account", + "SmsVerificationMessage": "The verification code to your new account is {####}", + "VerificationMessageTemplate": { + "DefaultEmailOption": "CONFIRM_WITH_CODE", + "EmailMessage": "The verification code to your new account is {####}", + "EmailSubject": "Verify your new account", + "SmsMessage": "The verification code to your new account is {####}" + } + }, + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" + }, + "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7": { + "Type": "AWS::Cognito::UserPoolClient", + "Properties": { + "AllowedOAuthFlows": [ + "implicit", + "code" + ], + "AllowedOAuthFlowsUserPoolClient": true, + "AllowedOAuthScopes": [ + "profile", + "phone", + "email", + "openid", + "aws.cognito.signin.user.admin" + ], + "CallbackURLs": [ + "https://example.com" + ], + "SupportedIdentityProviders": [ + "COGNITO" + ], + "UserPoolId": { + "Ref": "userpoolForDefaultAuthorizerDFBE8E74" + } + } + }, "MyHttpApi8AEAAC21": { "Type": "AWS::ApiGatewayV2::Api", "Properties": { @@ -129,61 +243,56 @@ "Name": "UserPoolAuthorizer" } }, - "userpool0AC4AA96": { - "Type": "AWS::Cognito::UserPool", + "MyHttpApiWithDefaultAuthorizerE08800A1": { + "Type": "AWS::ApiGatewayV2::Api", "Properties": { - "AccountRecoverySetting": { - "RecoveryMechanisms": [ - { - "Name": "verified_phone_number", - "Priority": 1 - }, - { - "Name": "verified_email", - "Priority": 2 - } - ] - }, - "AdminCreateUserConfig": { - "AllowAdminCreateUserOnly": true + "Name": "MyHttpApiWithDefaultAuthorizer", + "ProtocolType": "HTTP" + } + }, + "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6": { + "Type": "AWS::ApiGatewayV2::Stage", + "Properties": { + "ApiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" }, - "EmailVerificationMessage": "The verification code to your new account is {####}", - "EmailVerificationSubject": "Verify your new account", - "SmsVerificationMessage": "The verification code to your new account is {####}", - "VerificationMessageTemplate": { - "DefaultEmailOption": "CONFIRM_WITH_CODE", - "EmailMessage": "The verification code to your new account is {####}", - "EmailSubject": "Verify your new account", - "SmsMessage": "The verification code to your new account is {####}" - } - }, - "UpdateReplacePolicy": "Retain", - "DeletionPolicy": "Retain" + "AutoDeploy": true, + "StageName": "$default" + } }, - "userpoolUserPoolAuthorizerClient6A7486E8": { - "Type": "AWS::Cognito::UserPoolClient", + "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF": { + "Type": "AWS::ApiGatewayV2::Authorizer", "Properties": { - "AllowedOAuthFlows": [ - "implicit", - "code" - ], - "AllowedOAuthFlowsUserPoolClient": true, - "AllowedOAuthScopes": [ - "profile", - "phone", - "email", - "openid", - "aws.cognito.signin.user.admin" - ], - "CallbackURLs": [ - "https://example.com" - ], - "SupportedIdentityProviders": [ - "COGNITO" + "ApiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "AuthorizerType": "JWT", + "IdentitySource": [ + "$request.header.Authorization" ], - "UserPoolId": { - "Ref": "userpool0AC4AA96" - } + "JwtConfiguration": { + "Audience": [ + { + "Ref": "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7" + } + ], + "Issuer": { + "Fn::Join": [ + "", + [ + "https://cognito-idp.", + { + "Ref": "AWS::Region" + }, + ".amazonaws.com/", + { + "Ref": "userpoolForDefaultAuthorizerDFBE8E74" + } + ] + ] + } + }, + "Name": "UserPoolDefaultAuthorizer" } }, "lambdaServiceRole494E4CA6": { @@ -238,6 +347,87 @@ "DependsOn": [ "lambdaServiceRole494E4CA6" ] + }, + "RouteRootIntegration1CF58575": { + "Type": "AWS::ApiGatewayV2::Integration", + "Properties": { + "ApiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "IntegrationType": "AWS_PROXY", + "IntegrationUri": { + "Fn::GetAtt": [ + "lambda8B5974B5", + "Arn" + ] + }, + "PayloadFormatVersion": "2.0" + } + }, + "RouteRootIntegrationPermissionC2C15701": { + "Type": "AWS::Lambda::Permission", + "Properties": { + "Action": "lambda:InvokeFunction", + "FunctionName": { + "Fn::GetAtt": [ + "lambda8B5974B5", + "Arn" + ] + }, + "Principal": "apigateway.amazonaws.com", + "SourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "/*/*/v1/mything/{proxy+}" + ] + ] + } + } + }, + "RouteA67450D2": { + "Type": "AWS::ApiGatewayV2::Route", + "Properties": { + "ApiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "AuthorizationScopes": [ + "scope1", + "scope2" + ], + "AuthorizationType": "JWT", + "AuthorizerId": { + "Ref": "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF" + }, + "RouteKey": "ANY /v1/mything/{proxy+}", + "Target": { + "Fn::Join": [ + "", + [ + "integrations/", + { + "Ref": "RouteRootIntegration1CF58575" + } + ] + ] + } + } } }, "Parameters": { diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/manifest.json index d46d951d4f47a..85761c96e101e 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/manifest.json @@ -18,7 +18,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}/0847c0b726780e7b084297b7c2323b91c608e241e019e9d3e0bf62fcfd673c8d.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/8e1b12f5d12c6de951105961b92d6c971a32d4cbbc394e1542bcbedf77450978.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -34,148 +34,124 @@ "AuthorizerInteg.assets" ], "metadata": { - "/AuthorizerInteg/MyHttpApi/Resource": [ + "/AuthorizerInteg/userpool/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApi8AEAAC21" + "data": "userpool0AC4AA96" } ], - "/AuthorizerInteg/MyHttpApi/DefaultStage/Resource": [ + "/AuthorizerInteg/userpool/UserPoolAuthorizerClient/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiDefaultStageDCB9BC49" + "data": "userpoolUserPoolAuthorizerClient6A7486E8" } ], - "/AuthorizerInteg/MyHttpApi/GET--/RootIntegratin/Resource": [ + "/AuthorizerInteg/userpoolForDefaultAuthorizer/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiGETRootIntegratin93150A89" + "data": "userpoolForDefaultAuthorizerDFBE8E74" } ], - "/AuthorizerInteg/MyHttpApi/GET--/RootIntegratin-Permission": [ + "/AuthorizerInteg/userpoolForDefaultAuthorizer/UserPoolAuthorizerClient/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiGETRootIntegratinPermissionCEEEB498" + "data": "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7" } ], - "/AuthorizerInteg/MyHttpApi/GET--/Resource": [ + "/AuthorizerInteg/MyHttpApi/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiGETE0EFC6F8" + "data": "MyHttpApi8AEAAC21" } ], - "/AuthorizerInteg/MyHttpApi/UserPoolAuthorizer/Resource": [ + "/AuthorizerInteg/MyHttpApi/DefaultStage/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiUserPoolAuthorizer8754262B" + "data": "MyHttpApiDefaultStageDCB9BC49" } ], - "/AuthorizerInteg/userpool/Resource": [ + "/AuthorizerInteg/MyHttpApi/GET--/RootIntegratin/Resource": [ { "type": "aws:cdk:logicalId", - "data": "userpool0AC4AA96" + "data": "MyHttpApiGETRootIntegratin93150A89" } ], - "/AuthorizerInteg/userpool/UserPoolAuthorizerClient/Resource": [ + "/AuthorizerInteg/MyHttpApi/GET--/RootIntegratin-Permission": [ { "type": "aws:cdk:logicalId", - "data": "userpoolUserPoolAuthorizerClient6A7486E8" + "data": "MyHttpApiGETRootIntegratinPermissionCEEEB498" } ], - "/AuthorizerInteg/lambda/ServiceRole/Resource": [ + "/AuthorizerInteg/MyHttpApi/GET--/Resource": [ { "type": "aws:cdk:logicalId", - "data": "lambdaServiceRole494E4CA6" + "data": "MyHttpApiGETE0EFC6F8" } ], - "/AuthorizerInteg/lambda/Resource": [ + "/AuthorizerInteg/MyHttpApi/UserPoolAuthorizer/Resource": [ { "type": "aws:cdk:logicalId", - "data": "lambda8B5974B5" + "data": "MyHttpApiUserPoolAuthorizer8754262B" } ], - "/AuthorizerInteg/BootstrapVersion": [ + "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/Resource": [ { "type": "aws:cdk:logicalId", - "data": "BootstrapVersion" + "data": "MyHttpApiWithDefaultAuthorizerE08800A1" } ], - "/AuthorizerInteg/CheckBootstrapVersion": [ + "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage/Resource": [ { "type": "aws:cdk:logicalId", - "data": "CheckBootstrapVersion" + "data": "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6" } ], - "userpoolForDefaultAuthorizerDFBE8E74": [ + "/AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/UserPoolDefaultAuthorizer/Resource": [ { "type": "aws:cdk:logicalId", - "data": "userpoolForDefaultAuthorizerDFBE8E74", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF" } ], - "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7": [ + "/AuthorizerInteg/lambda/ServiceRole/Resource": [ { "type": "aws:cdk:logicalId", - "data": "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "lambdaServiceRole494E4CA6" } ], - "MyHttpApiWithDefaultAuthorizerE08800A1": [ + "/AuthorizerInteg/lambda/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerE08800A1", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "lambda8B5974B5" } ], - "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6": [ + "/AuthorizerInteg/Route/RootIntegration/Resource": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerDefaultStage7A9EE9B6", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "RouteRootIntegration1CF58575" } ], - "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF": [ + "/AuthorizerInteg/Route/RootIntegration-Permission": [ { "type": "aws:cdk:logicalId", - "data": "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "RouteRootIntegrationPermissionC2C15701" } ], - "RouteRootIntegration1CF58575": [ + "/AuthorizerInteg/Route/Resource": [ { "type": "aws:cdk:logicalId", - "data": "RouteRootIntegration1CF58575", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "RouteA67450D2" } ], - "RouteRootIntegrationPermissionC2C15701": [ + "/AuthorizerInteg/BootstrapVersion": [ { "type": "aws:cdk:logicalId", - "data": "RouteRootIntegrationPermissionC2C15701", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "BootstrapVersion" } ], - "RouteA67450D2": [ + "/AuthorizerInteg/CheckBootstrapVersion": [ { "type": "aws:cdk:logicalId", - "data": "RouteA67450D2", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "CheckBootstrapVersion" } ] }, diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/tree.json index dbcc561a94515..23f942bfe3fdc 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/http/integ.user-pool.js.snapshot/tree.json @@ -8,6 +8,188 @@ "id": "AuthorizerInteg", "path": "AuthorizerInteg", "children": { + "userpool": { + "id": "userpool", + "path": "AuthorizerInteg/userpool", + "children": { + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/userpool/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Cognito::UserPool", + "aws:cdk:cloudformation:props": { + "accountRecoverySetting": { + "recoveryMechanisms": [ + { + "name": "verified_phone_number", + "priority": 1 + }, + { + "name": "verified_email", + "priority": 2 + } + ] + }, + "adminCreateUserConfig": { + "allowAdminCreateUserOnly": true + }, + "emailVerificationMessage": "The verification code to your new account is {####}", + "emailVerificationSubject": "Verify your new account", + "smsVerificationMessage": "The verification code to your new account is {####}", + "verificationMessageTemplate": { + "defaultEmailOption": "CONFIRM_WITH_CODE", + "emailMessage": "The verification code to your new account is {####}", + "emailSubject": "Verify your new account", + "smsMessage": "The verification code to your new account is {####}" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cognito.CfnUserPool", + "version": "0.0.0" + } + }, + "UserPoolAuthorizerClient": { + "id": "UserPoolAuthorizerClient", + "path": "AuthorizerInteg/userpool/UserPoolAuthorizerClient", + "children": { + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/userpool/UserPoolAuthorizerClient/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Cognito::UserPoolClient", + "aws:cdk:cloudformation:props": { + "allowedOAuthFlows": [ + "implicit", + "code" + ], + "allowedOAuthFlowsUserPoolClient": true, + "allowedOAuthScopes": [ + "profile", + "phone", + "email", + "openid", + "aws.cognito.signin.user.admin" + ], + "callbackUrLs": [ + "https://example.com" + ], + "supportedIdentityProviders": [ + "COGNITO" + ], + "userPoolId": { + "Ref": "userpool0AC4AA96" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cognito.CfnUserPoolClient", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cognito.UserPoolClient", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cognito.UserPool", + "version": "0.0.0" + } + }, + "userpoolForDefaultAuthorizer": { + "id": "userpoolForDefaultAuthorizer", + "path": "AuthorizerInteg/userpoolForDefaultAuthorizer", + "children": { + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/userpoolForDefaultAuthorizer/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Cognito::UserPool", + "aws:cdk:cloudformation:props": { + "accountRecoverySetting": { + "recoveryMechanisms": [ + { + "name": "verified_phone_number", + "priority": 1 + }, + { + "name": "verified_email", + "priority": 2 + } + ] + }, + "adminCreateUserConfig": { + "allowAdminCreateUserOnly": true + }, + "emailVerificationMessage": "The verification code to your new account is {####}", + "emailVerificationSubject": "Verify your new account", + "smsVerificationMessage": "The verification code to your new account is {####}", + "verificationMessageTemplate": { + "defaultEmailOption": "CONFIRM_WITH_CODE", + "emailMessage": "The verification code to your new account is {####}", + "emailSubject": "Verify your new account", + "smsMessage": "The verification code to your new account is {####}" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cognito.CfnUserPool", + "version": "0.0.0" + } + }, + "UserPoolAuthorizerClient": { + "id": "UserPoolAuthorizerClient", + "path": "AuthorizerInteg/userpoolForDefaultAuthorizer/UserPoolAuthorizerClient", + "children": { + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/userpoolForDefaultAuthorizer/UserPoolAuthorizerClient/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Cognito::UserPoolClient", + "aws:cdk:cloudformation:props": { + "allowedOAuthFlows": [ + "implicit", + "code" + ], + "allowedOAuthFlowsUserPoolClient": true, + "allowedOAuthScopes": [ + "profile", + "phone", + "email", + "openid", + "aws.cognito.signin.user.admin" + ], + "callbackUrLs": [ + "https://example.com" + ], + "supportedIdentityProviders": [ + "COGNITO" + ], + "userPoolId": { + "Ref": "userpoolForDefaultAuthorizerDFBE8E74" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cognito.CfnUserPoolClient", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cognito.UserPoolClient", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_cognito.UserPool", + "version": "0.0.0" + } + }, "MyHttpApi": { "id": "MyHttpApi", "path": "AuthorizerInteg/MyHttpApi", @@ -235,94 +417,109 @@ "version": "0.0.0" } }, - "userpool": { - "id": "userpool", - "path": "AuthorizerInteg/userpool", + "MyHttpApiWithDefaultAuthorizer": { + "id": "MyHttpApiWithDefaultAuthorizer", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer", "children": { "Resource": { "id": "Resource", - "path": "AuthorizerInteg/userpool/Resource", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/Resource", "attributes": { - "aws:cdk:cloudformation:type": "AWS::Cognito::UserPool", + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Api", "aws:cdk:cloudformation:props": { - "accountRecoverySetting": { - "recoveryMechanisms": [ - { - "name": "verified_phone_number", - "priority": 1 + "name": "MyHttpApiWithDefaultAuthorizer", + "protocolType": "HTTP" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnApi", + "version": "0.0.0" + } + }, + "DefaultStage": { + "id": "DefaultStage", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage", + "children": { + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/DefaultStage/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Stage", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" }, - { - "name": "verified_email", - "priority": 2 - } - ] - }, - "adminCreateUserConfig": { - "allowAdminCreateUserOnly": true + "autoDeploy": true, + "stageName": "$default" + } }, - "emailVerificationMessage": "The verification code to your new account is {####}", - "emailVerificationSubject": "Verify your new account", - "smsVerificationMessage": "The verification code to your new account is {####}", - "verificationMessageTemplate": { - "defaultEmailOption": "CONFIRM_WITH_CODE", - "emailMessage": "The verification code to your new account is {####}", - "emailSubject": "Verify your new account", - "smsMessage": "The verification code to your new account is {####}" + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnStage", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_cognito.CfnUserPool", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpStage", "version": "0.0.0" } }, - "UserPoolAuthorizerClient": { - "id": "UserPoolAuthorizerClient", - "path": "AuthorizerInteg/userpool/UserPoolAuthorizerClient", + "UserPoolDefaultAuthorizer": { + "id": "UserPoolDefaultAuthorizer", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/UserPoolDefaultAuthorizer", "children": { "Resource": { "id": "Resource", - "path": "AuthorizerInteg/userpool/UserPoolAuthorizerClient/Resource", + "path": "AuthorizerInteg/MyHttpApiWithDefaultAuthorizer/UserPoolDefaultAuthorizer/Resource", "attributes": { - "aws:cdk:cloudformation:type": "AWS::Cognito::UserPoolClient", + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Authorizer", "aws:cdk:cloudformation:props": { - "allowedOAuthFlows": [ - "implicit", - "code" - ], - "allowedOAuthFlowsUserPoolClient": true, - "allowedOAuthScopes": [ - "profile", - "phone", - "email", - "openid", - "aws.cognito.signin.user.admin" - ], - "callbackUrLs": [ - "https://example.com" - ], - "supportedIdentityProviders": [ - "COGNITO" + "apiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "authorizerType": "JWT", + "identitySource": [ + "$request.header.Authorization" ], - "userPoolId": { - "Ref": "userpool0AC4AA96" - } + "jwtConfiguration": { + "audience": [ + { + "Ref": "userpoolForDefaultAuthorizerUserPoolAuthorizerClient3AA110E7" + } + ], + "issuer": { + "Fn::Join": [ + "", + [ + "https://cognito-idp.", + { + "Ref": "AWS::Region" + }, + ".amazonaws.com/", + { + "Ref": "userpoolForDefaultAuthorizerDFBE8E74" + } + ] + ] + } + }, + "name": "UserPoolDefaultAuthorizer" } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_cognito.CfnUserPoolClient", + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnAuthorizer", "version": "0.0.0" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_cognito.UserPoolClient", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpAuthorizer", "version": "0.0.0" } } }, "constructInfo": { - "fqn": "aws-cdk-lib.aws_cognito.UserPool", + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpApi", "version": "0.0.0" } }, @@ -446,6 +643,131 @@ "version": "0.0.0" } }, + "Route": { + "id": "Route", + "path": "AuthorizerInteg/Route", + "children": { + "RootIntegration": { + "id": "RootIntegration", + "path": "AuthorizerInteg/Route/RootIntegration", + "children": { + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/Route/RootIntegration/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Integration", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "integrationType": "AWS_PROXY", + "integrationUri": { + "Fn::GetAtt": [ + "lambda8B5974B5", + "Arn" + ] + }, + "payloadFormatVersion": "2.0" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnIntegration", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpIntegration", + "version": "0.0.0" + } + }, + "RootIntegration-Permission": { + "id": "RootIntegration-Permission", + "path": "AuthorizerInteg/Route/RootIntegration-Permission", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Lambda::Permission", + "aws:cdk:cloudformation:props": { + "action": "lambda:InvokeFunction", + "functionName": { + "Fn::GetAtt": [ + "lambda8B5974B5", + "Arn" + ] + }, + "principal": "apigateway.amazonaws.com", + "sourceArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":execute-api:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":", + { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "/*/*/v1/mything/{proxy+}" + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_lambda.CfnPermission", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "AuthorizerInteg/Route/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ApiGatewayV2::Route", + "aws:cdk:cloudformation:props": { + "apiId": { + "Ref": "MyHttpApiWithDefaultAuthorizerE08800A1" + }, + "authorizationScopes": [ + "scope1", + "scope2" + ], + "authorizationType": "JWT", + "authorizerId": { + "Ref": "MyHttpApiWithDefaultAuthorizerUserPoolDefaultAuthorizerF10D4FFF" + }, + "routeKey": "ANY /v1/mything/{proxy+}", + "target": { + "Fn::Join": [ + "", + [ + "integrations/", + { + "Ref": "RouteRootIntegration1CF58575" + } + ] + ] + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_apigatewayv2.CfnRoute", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-apigatewayv2-alpha.HttpRoute", + "version": "0.0.0" + } + }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "AuthorizerInteg/BootstrapVersion", diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json index 4ab5619801629..acfbbfa7a6875 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "0fecdddcc93cb59f37820c43eaa8030e35f0be824e2f8e7b63bde0bb0b24e264": { + "89f3eb281075e38df0df45fd2cf30f90cd7bbaabddef614ebee1040631c2a0c6": { "source": { "path": "IntegApiGatewayV2Iam.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "0fecdddcc93cb59f37820c43eaa8030e35f0be824e2f8e7b63bde0bb0b24e264.json", + "objectKey": "89f3eb281075e38df0df45fd2cf30f90cd7bbaabddef614ebee1040631c2a0c6.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json index 5e3e47d97b6cf..ec0283f3bd2bd 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json @@ -100,7 +100,7 @@ { "Ref": "WebSocketApi34BCF99B" }, - "/*$connect" + "/*/*$connect" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json index 5cd819d527b7b..1168578c0a740 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json @@ -18,7 +18,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}/0fecdddcc93cb59f37820c43eaa8030e35f0be824e2f8e7b63bde0bb0b24e264.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/89f3eb281075e38df0df45fd2cf30f90cd7bbaabddef614ebee1040631c2a0c6.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json index 2192187ed14af..3aeaca1832db8 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json @@ -205,7 +205,7 @@ { "Ref": "WebSocketApi34BCF99B" }, - "/*$connect" + "/*/*$connect" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json new file mode 100644 index 0000000000000..618513371ae9f --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.assets.json @@ -0,0 +1,19 @@ +{ + "version": "34.0.0", + "files": { + "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { + "source": { + "path": "IntegDefaultTestDeployAssert4E6713E1.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/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.template.json new file mode 100644 index 0000000000000..ad9d0fb73d1dd --- /dev/null +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/IntegDefaultTestDeployAssert4E6713E1.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/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/package.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.2748a200bf25c8ee2c2898271226a9f7bdc386b8ce9669528731eb36c5ed9e28/package.json similarity index 100% rename from packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/package.json rename to packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.2748a200bf25c8ee2c2898271226a9f7bdc386b8ce9669528731eb36c5ed9e28/package.json diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/index.js b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/index.js deleted file mode 100644 index 9b5dbf88ff1fd..0000000000000 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/index.js +++ /dev/null @@ -1,32 +0,0 @@ -// https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-websocket-api-route-keys-connect-disconnect.html -// The $disconnect route is executed after the connection is closed. -// The connection can be closed by the server or by the client. As the connection is already closed when it is executed, -// $disconnect is a best-effort event. -// API Gateway will try its best to deliver the $disconnect event to your integration, but it cannot guarantee delivery. - -const AWS = require("aws-sdk"); - -const ddb = new AWS.DynamoDB.DocumentClient({ - apiVersion: "2012-08-10", - region: process.env.AWS_REGION, -}); - -exports.handler = async (event) => { - const deleteParams = { - TableName: process.env.TABLE_NAME, - Key: { - connectionId: event.requestContext.connectionId, - }, - }; - - try { - await ddb.delete(deleteParams).promise(); - } catch (err) { - return { - statusCode: 500, - body: "Failed to disconnect: " + JSON.stringify(err), - }; - } - - return { statusCode: 200, body: "Disconnected." }; -}; diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/package.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.e593848af17fee558eece2cd2719347804c0c141cff4f8ea1fb8556cf986b5a0/package.json similarity index 100% rename from packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c/package.json rename to packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.e593848af17fee558eece2cd2719347804c0c141cff4f8ea1fb8556cf986b5a0/package.json diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/index.js b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/index.js deleted file mode 100644 index 0b30c8c3cb950..0000000000000 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07/index.js +++ /dev/null @@ -1,26 +0,0 @@ -const AWS = require("aws-sdk"); - -const ddb = new AWS.DynamoDB.DocumentClient({ - apiVersion: "2012-08-10", - region: process.env.AWS_REGION, -}); - -exports.handler = async (event) => { - const putParams = { - TableName: process.env.TABLE_NAME, - Item: { - connectionId: event.requestContext.connectionId, - }, - }; - - try { - await ddb.put(putParams).promise(); - } catch (err) { - return { - statusCode: 500, - body: "Failed to connect: " + JSON.stringify(err), - }; - } - - return { statusCode: 200, body: "Connected." }; -}; diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json index a48286b811188..a2417bccec02d 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json @@ -1,33 +1,33 @@ { "version": "34.0.0", "files": { - "f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07": { + "2748a200bf25c8ee2c2898271226a9f7bdc386b8ce9669528731eb36c5ed9e28": { "source": { - "path": "asset.f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07", + "path": "asset.2748a200bf25c8ee2c2898271226a9f7bdc386b8ce9669528731eb36c5ed9e28", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07.zip", + "objectKey": "2748a200bf25c8ee2c2898271226a9f7bdc386b8ce9669528731eb36c5ed9e28.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c": { + "e593848af17fee558eece2cd2719347804c0c141cff4f8ea1fb8556cf986b5a0": { "source": { - "path": "asset.48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c", + "path": "asset.e593848af17fee558eece2cd2719347804c0c141cff4f8ea1fb8556cf986b5a0", "packaging": "zip" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c.zip", + "objectKey": "e593848af17fee558eece2cd2719347804c0c141cff4f8ea1fb8556cf986b5a0.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "78326e78ff76a1ed4538fd2d47129266d95b8c304857736753ec3afa4250d787": { + "ed272b6c4a8aae3814d65d7420d862636797bf81af22c06e22a29abbaac44ca8": { "source": { "path": "integ-apigwv2-lambda-connect-integration.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "78326e78ff76a1ed4538fd2d47129266d95b8c304857736753ec3afa4250d787.json", + "objectKey": "ed272b6c4a8aae3814d65d7420d862636797bf81af22c06e22a29abbaac44ca8.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json index 9dfaa75f03a57..b5e8c4f4e2400 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json @@ -82,7 +82,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07.zip" + "S3Key": "2748a200bf25c8ee2c2898271226a9f7bdc386b8ce9669528731eb36c5ed9e28.zip" }, "Environment": { "Variables": { @@ -187,7 +187,7 @@ "S3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "S3Key": "48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c.zip" + "S3Key": "e593848af17fee558eece2cd2719347804c0c141cff4f8ea1fb8556cf986b5a0.zip" }, "Environment": { "Variables": { @@ -273,7 +273,7 @@ { "Ref": "WebSocketAPIDA75128A" }, - "/*$connect" + "/*/*$connect" ] ] } @@ -363,7 +363,7 @@ { "Ref": "WebSocketAPIDA75128A" }, - "/*$disconnect" + "/*/*$disconnect" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json index e68b02918b8f2..f122cfe8f44e1 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ.json @@ -1,14 +1,12 @@ { "version": "34.0.0", "testCases": { - "integ.lambda-connect-disconnect-trigger": { + "Integ/DefaultTest": { "stacks": [ "integ-apigwv2-lambda-connect-integration" ], - "diffAssets": false, - "stackUpdateWorkflow": true + "assertionStack": "Integ/DefaultTest/DeployAssert", + "assertionStackName": "IntegDefaultTestDeployAssert4E6713E1" } - }, - "synthContext": {}, - "enableLookups": false + } } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json index c3afd38261081..2c9e86a811e32 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json @@ -18,7 +18,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}/78326e78ff76a1ed4538fd2d47129266d95b8c304857736753ec3afa4250d787.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/ed272b6c4a8aae3814d65d7420d862636797bf81af22c06e22a29abbaac44ca8.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -93,7 +93,10 @@ "/integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route/ConnectIntegration-Permission": [ { "type": "aws:cdk:logicalId", - "data": "WebSocketAPIconnectRouteConnectIntegrationPermission1FECDE58" + "data": "WebSocketAPIconnectRouteConnectIntegrationPermission1FECDE58", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_REPLACE" + ] } ], "/integ-apigwv2-lambda-connect-integration/WebSocket API/$connect-Route/ConnectIntegration/Resource": [ @@ -111,7 +114,10 @@ "/integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route/DisconnectIntegration-Permission": [ { "type": "aws:cdk:logicalId", - "data": "WebSocketAPIdisconnectRouteDisconnectIntegrationPermission909CCDD8" + "data": "WebSocketAPIdisconnectRouteDisconnectIntegrationPermission909CCDD8", + "trace": [ + "!!DESTRUCTIVE_CHANGES: WILL_REPLACE" + ] } ], "/integ-apigwv2-lambda-connect-integration/WebSocket API/$disconnect-Route/DisconnectIntegration/Resource": [ @@ -147,6 +153,54 @@ }, "displayName": "integ-apigwv2-lambda-connect-integration" }, + "IntegDefaultTestDeployAssert4E6713E1.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "IntegDefaultTestDeployAssert4E6713E1.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "IntegDefaultTestDeployAssert4E6713E1": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "IntegDefaultTestDeployAssert4E6713E1.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": [ + "IntegDefaultTestDeployAssert4E6713E1.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": [ + "IntegDefaultTestDeployAssert4E6713E1.assets" + ], + "metadata": { + "/Integ/DefaultTest/DeployAssert/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/Integ/DefaultTest/DeployAssert/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "Integ/DefaultTest/DeployAssert" + }, "Tree": { "type": "cdk:tree", "properties": { diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json index 4972c8ceba984..b168b11a163f1 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json @@ -167,7 +167,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "f00343ba062ce1a3797e6d7daefcc4e0b3e379be9a5c55df797a2a854733cf07.zip" + "s3Key": "2748a200bf25c8ee2c2898271226a9f7bdc386b8ce9669528731eb36c5ed9e28.zip" }, "environment": { "variables": { @@ -356,7 +356,7 @@ "s3Bucket": { "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}" }, - "s3Key": "48ec310d5a24f214ab5100b4abd94d98450fac6398f4888be0485370e071e99c.zip" + "s3Key": "e593848af17fee558eece2cd2719347804c0c141cff4f8ea1fb8556cf986b5a0.zip" }, "environment": { "variables": { @@ -492,7 +492,7 @@ { "Ref": "WebSocketAPIDA75128A" }, - "/*$connect" + "/*/*$connect" ] ] } @@ -626,7 +626,7 @@ { "Ref": "WebSocketAPIDA75128A" }, - "/*$disconnect" + "/*/*$disconnect" ] ] } @@ -778,6 +778,60 @@ "version": "0.0.0" } }, + "Integ": { + "id": "Integ", + "path": "Integ", + "children": { + "DefaultTest": { + "id": "DefaultTest", + "path": "Integ/DefaultTest", + "children": { + "Default": { + "id": "Default", + "path": "Integ/DefaultTest/Default", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.2.70" + } + }, + "DeployAssert": { + "id": "DeployAssert", + "path": "Integ/DefaultTest/DeployAssert", + "children": { + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "Integ/DefaultTest/DeployAssert/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "Integ/DefaultTest/DeployAssert/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTestCase", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests-alpha.IntegTest", + "version": "0.0.0" + } + }, "Tree": { "id": "Tree", "path": "Tree", diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json index c73ed81c6cb7f..806e1a698a8a3 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "fa386136122b6cd106460ddbdcd437d10712be61617b8d1bf2110a459aa9e233": { + "26e34316c6931e2609524675771603977641dab52471e7fb4c21e998529ed3fd": { "source": { "path": "WebSocketApiInteg.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "fa386136122b6cd106460ddbdcd437d10712be61617b8d1bf2110a459aa9e233.json", + "objectKey": "26e34316c6931e2609524675771603977641dab52471e7fb4c21e998529ed3fd.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json index e50d8cfbe1645..b6e930b1fa098 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json @@ -239,7 +239,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*$connect" + "/*/*$connect" ] ] } @@ -329,7 +329,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*$disconnect" + "/*/*$disconnect" ] ] } @@ -419,7 +419,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*$default" + "/*/*$default" ] ] } @@ -509,7 +509,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*sendmessage" + "/*/*sendmessage" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json index 1f2c3210e48af..f38f0b09434e2 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json @@ -18,7 +18,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}/fa386136122b6cd106460ddbdcd437d10712be61617b8d1bf2110a459aa9e233.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/26e34316c6931e2609524675771603977641dab52471e7fb4c21e998529ed3fd.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json index 990d79acbeef9..a3eaa745e06b2 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json @@ -430,7 +430,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*$connect" + "/*/*$connect" ] ] } @@ -564,7 +564,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*$disconnect" + "/*/*$disconnect" ] ] } @@ -698,7 +698,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*$default" + "/*/*$default" ] ] } @@ -832,7 +832,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*sendmessage" + "/*/*sendmessage" ] ] } diff --git a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.assets.json b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.assets.json index 8a91333b6e2d2..89f92e7bd5dc4 100644 --- a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.assets.json +++ b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "c5abc7ef2e341477218fc19664c82ee2ea13e9509f2deaae6fc6200a619a5d1c": { + "ea755ac1ccc8e2c8816cf7e0a2b3789e472a166174037cb50eb45ec4ed621ba4": { "source": { "path": "aws-appconfig-environment.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "c5abc7ef2e341477218fc19664c82ee2ea13e9509f2deaae6fc6200a619a5d1c.json", + "objectKey": "ea755ac1ccc8e2c8816cf7e0a2b3789e472a166174037cb50eb45ec4ed621ba4.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.template.json b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.template.json index e120019dcabe1..c3951447345b9 100644 --- a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.template.json +++ b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/aws-appconfig-environment.template.json @@ -18,6 +18,23 @@ "Threshold": 10 } }, + "MyRoleF48FFE04": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "appconfig.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + } + } + }, "MyEnvironmentRole01C8C013F": { "Type": "AWS::IAM::Role", "Properties": { @@ -76,6 +93,20 @@ "Arn" ] } + }, + { + "AlarmArn": { + "Fn::GetAtt": [ + "MyAlarm696658B6", + "Arn" + ] + }, + "AlarmRoleArn": { + "Fn::GetAtt": [ + "MyRoleF48FFE04", + "Arn" + ] + } } ], "Name": "awsappconfigenvironment-MyEnvironment-C8813182" diff --git a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/manifest.json b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/manifest.json index 6f758fc4db657..4c038cd5bcd81 100644 --- a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/manifest.json @@ -14,10 +14,11 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "aws-appconfig-environment.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}/c5abc7ef2e341477218fc19664c82ee2ea13e9509f2deaae6fc6200a619a5d1c.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/ea755ac1ccc8e2c8816cf7e0a2b3789e472a166174037cb50eb45ec4ed621ba4.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -45,6 +46,12 @@ "data": "MyAlarm696658B6" } ], + "/aws-appconfig-environment/MyRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "MyRoleF48FFE04" + } + ], "/aws-appconfig-environment/MyEnvironment/Role0/Resource": [ { "type": "aws:cdk:logicalId", @@ -85,6 +92,7 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "appconfigenvironmentDefaultTestDeployAssert75BD28E7.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}", diff --git a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/tree.json b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/tree.json index 730c4e7fb0302..9b1d723134bbf 100644 --- a/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-appconfig-alpha/test/integ.environment.js.snapshot/tree.json @@ -62,6 +62,49 @@ "version": "0.0.0" } }, + "MyRole": { + "id": "MyRole", + "path": "aws-appconfig-environment/MyRole", + "children": { + "ImportMyRole": { + "id": "ImportMyRole", + "path": "aws-appconfig-environment/MyRole/ImportMyRole", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "aws-appconfig-environment/MyRole/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:props": { + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "appconfig.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" + } + }, "MyEnvironment": { "id": "MyEnvironment", "path": "aws-appconfig-environment/MyEnvironment", @@ -153,6 +196,20 @@ "Arn" ] } + }, + { + "alarmArn": { + "Fn::GetAtt": [ + "MyAlarm696658B6", + "Arn" + ] + }, + "alarmRoleArn": { + "Fn::GetAtt": [ + "MyRoleF48FFE04", + "Arn" + ] + } } ], "name": "awsappconfigenvironment-MyEnvironment-C8813182" diff --git a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/manifest.json b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/manifest.json index 769e8e43f6a09..4cf37e981ad32 100644 --- a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/manifest.json @@ -14,10 +14,11 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "test-stack.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}/f75ab8f9b4f9b4569a43902e069684cc217226d66b42e025930c87f6f6dd1cb4.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/3a62ef659d4a9f7e50c7478aef6b276f52807f55412288d80cd1bd930ad07421.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -104,15 +105,6 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } - ], - "MyStreamServiceRole8C50608A": [ - { - "type": "aws:cdk:logicalId", - "data": "MyStreamServiceRole8C50608A", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] - } ] }, "displayName": "test-stack" diff --git a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.assets.json b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.assets.json index 889e2678b517e..21160bad2321b 100644 --- a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.assets.json +++ b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "f75ab8f9b4f9b4569a43902e069684cc217226d66b42e025930c87f6f6dd1cb4": { + "3a62ef659d4a9f7e50c7478aef6b276f52807f55412288d80cd1bd930ad07421": { "source": { "path": "test-stack.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "f75ab8f9b4f9b4569a43902e069684cc217226d66b42e025930c87f6f6dd1cb4.json", + "objectKey": "3a62ef659d4a9f7e50c7478aef6b276f52807f55412288d80cd1bd930ad07421.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.template.json b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.template.json index 0b0c7bce3882d..8baaeeefaad35 100644 --- a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.template.json +++ b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/test-stack.template.json @@ -231,6 +231,9 @@ "ap-south-1": { "FirehoseCidrBlock": "13.232.67.32/27" }, + "ap-south-2": { + "FirehoseCidrBlock": "18.60.192.128/27" + }, "ap-southeast-1": { "FirehoseCidrBlock": "13.228.64.192/27" }, @@ -255,12 +258,18 @@ "eu-central-1": { "FirehoseCidrBlock": "35.158.127.160/27" }, + "eu-central-2": { + "FirehoseCidrBlock": "16.62.183.32/27" + }, "eu-north-1": { "FirehoseCidrBlock": "13.53.63.224/27" }, "eu-south-1": { "FirehoseCidrBlock": "15.161.135.128/27" }, + "eu-south-2": { + "FirehoseCidrBlock": "18.100.71.96/27" + }, "eu-west-1": { "FirehoseCidrBlock": "52.19.239.192/27" }, diff --git a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/tree.json b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/tree.json index 5ad56f532fb0c..1a859518058a2 100644 --- a/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-iot-actions-alpha/test/kinesis-firehose/integ.firehose-put-record-action.js.snapshot/tree.json @@ -42,8 +42,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iot.CfnTopicRule", + "version": "0.0.0" } }, "TopicRuleActionRole": { @@ -54,8 +54,8 @@ "id": "ImportTopicRuleActionRole", "path": "test-stack/TopicRule/TopicRuleActionRole/ImportTopicRuleActionRole", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" } }, "Resource": { @@ -79,8 +79,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" } }, "DefaultPolicy": { @@ -120,20 +120,20 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Policy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" } } }, @@ -154,14 +154,14 @@ "aws:cdk:cloudformation:props": {} }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_s3.CfnBucket", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_s3.Bucket", + "version": "0.0.0" } }, "MyStream": { @@ -176,8 +176,8 @@ "id": "ImportS3 Destination Role", "path": "test-stack/MyStream/S3 Destination Role/ImportS3 Destination Role", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" } }, "Resource": { @@ -201,8 +201,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" } }, "DefaultPolicy": { @@ -279,20 +279,20 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Policy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" } }, "LogGroup": { @@ -309,8 +309,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_logs.CfnLogGroup", + "version": "0.0.0" } }, "S3Destination": { @@ -329,20 +329,20 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_logs.CfnLogStream", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_logs.LogStream", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_logs.LogGroup", + "version": "0.0.0" } }, "Resource": { @@ -378,44 +378,44 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", + "version": "0.0.0" } }, "@aws-cdk--aws-kinesisfirehose.CidrBlocks": { "id": "@aws-cdk--aws-kinesisfirehose.CidrBlocks", "path": "test-stack/@aws-cdk--aws-kinesisfirehose.CidrBlocks", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnMapping", + "version": "0.0.0" } }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "test-stack/BootstrapVersion", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnParameter", + "version": "0.0.0" } }, "CheckBootstrapVersion": { "id": "CheckBootstrapVersion", "path": "test-stack/CheckBootstrapVersion", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnRule", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Stack", + "version": "0.0.0" } }, "Tree": { @@ -428,8 +428,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.App", + "version": "0.0.0" } } } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.assets.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.assets.json index bc3086aee09a9..8fc5583353e4c 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.assets.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "f08cb1eab080f1654e59530816541dc69a75d3a1248eac16524a832b8a62a463": { + "ccf02c806a025965e36fd920f6dd59f906cb43b81176e2f847cce172076212b7": { "source": { "path": "aws-cdk-firehose-delivery-stream.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "f08cb1eab080f1654e59530816541dc69a75d3a1248eac16524a832b8a62a463.json", + "objectKey": "ccf02c806a025965e36fd920f6dd59f906cb43b81176e2f847cce172076212b7.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.template.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.template.json index 224216bc4fb4c..93977e3ebd39e 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.template.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/aws-cdk-firehose-delivery-stream.template.json @@ -234,6 +234,9 @@ "ap-south-1": { "FirehoseCidrBlock": "13.232.67.32/27" }, + "ap-south-2": { + "FirehoseCidrBlock": "18.60.192.128/27" + }, "ap-southeast-1": { "FirehoseCidrBlock": "13.228.64.192/27" }, @@ -258,12 +261,18 @@ "eu-central-1": { "FirehoseCidrBlock": "35.158.127.160/27" }, + "eu-central-2": { + "FirehoseCidrBlock": "16.62.183.32/27" + }, "eu-north-1": { "FirehoseCidrBlock": "13.53.63.224/27" }, "eu-south-1": { "FirehoseCidrBlock": "15.161.135.128/27" }, + "eu-south-2": { + "FirehoseCidrBlock": "18.100.71.96/27" + }, "eu-west-1": { "FirehoseCidrBlock": "52.19.239.192/27" }, diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/manifest.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/manifest.json index 87f0eb72a23d2..a58abbc8bc737 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/manifest.json @@ -14,10 +14,11 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "aws-cdk-firehose-delivery-stream.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}/f08cb1eab080f1654e59530816541dc69a75d3a1248eac16524a832b8a62a463.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/ccf02c806a025965e36fd920f6dd59f906cb43b81176e2f847cce172076212b7.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -98,15 +99,6 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } - ], - "DeliveryStreamNoSourceorEncryptionKey49457027": [ - { - "type": "aws:cdk:logicalId", - "data": "DeliveryStreamNoSourceorEncryptionKey49457027", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] - } ] }, "displayName": "aws-cdk-firehose-delivery-stream" diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/tree.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/tree.json index 5343e9edb5617..c31352a0b4ec8 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.js.snapshot/tree.json @@ -20,14 +20,14 @@ "aws:cdk:cloudformation:props": {} }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_s3.CfnBucket", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_s3.Bucket", + "version": "0.0.0" } }, "Role": { @@ -38,8 +38,8 @@ "id": "ImportRole", "path": "aws-cdk-firehose-delivery-stream/Role/ImportRole", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" } }, "Resource": { @@ -63,8 +63,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" } }, "DefaultPolicy": { @@ -128,20 +128,20 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Policy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" } }, "Key": { @@ -185,14 +185,14 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_kms.CfnKey", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_kms.Key", + "version": "0.0.0" } }, "Delivery Stream": { @@ -207,8 +207,8 @@ "id": "ImportService Role", "path": "aws-cdk-firehose-delivery-stream/Delivery Stream/Service Role/ImportService Role", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" } }, "Resource": { @@ -232,8 +232,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" } }, "DefaultPolicy": { @@ -275,20 +275,20 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Policy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" } }, "Resource": { @@ -324,22 +324,22 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", + "version": "0.0.0" } }, "@aws-cdk--aws-kinesisfirehose.CidrBlocks": { "id": "@aws-cdk--aws-kinesisfirehose.CidrBlocks", "path": "aws-cdk-firehose-delivery-stream/@aws-cdk--aws-kinesisfirehose.CidrBlocks", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnMapping", + "version": "0.0.0" } }, "Delivery Stream No Source Or Encryption Key": { @@ -370,36 +370,36 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", + "version": "0.0.0" } }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "aws-cdk-firehose-delivery-stream/BootstrapVersion", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnParameter", + "version": "0.0.0" } }, "CheckBootstrapVersion": { "id": "CheckBootstrapVersion", "path": "aws-cdk-firehose-delivery-stream/CheckBootstrapVersion", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnRule", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Stack", + "version": "0.0.0" } }, "Tree": { @@ -412,8 +412,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.App", + "version": "0.0.0" } } } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.assets.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.assets.json index d539b8c1f38c4..532ba9af438ca 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.assets.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "64eae3903c3ecdce5113c92844e63dfd0056464ecf7d1351e86180364d20c1c0": { + "0b8a49e0b01e92c6b238e6d77538735e5b7a45a5bd1b32808ce9fe81fccc7c2e": { "source": { "path": "aws-cdk-firehose-delivery-stream-source-stream.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "64eae3903c3ecdce5113c92844e63dfd0056464ecf7d1351e86180364d20c1c0.json", + "objectKey": "0b8a49e0b01e92c6b238e6d77538735e5b7a45a5bd1b32808ce9fe81fccc7c2e.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.template.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.template.json index cbf990668d7bf..ec035f738f940 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.template.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/aws-cdk-firehose-delivery-stream-source-stream.template.json @@ -250,6 +250,9 @@ "ap-south-1": { "FirehoseCidrBlock": "13.232.67.32/27" }, + "ap-south-2": { + "FirehoseCidrBlock": "18.60.192.128/27" + }, "ap-southeast-1": { "FirehoseCidrBlock": "13.228.64.192/27" }, @@ -274,12 +277,18 @@ "eu-central-1": { "FirehoseCidrBlock": "35.158.127.160/27" }, + "eu-central-2": { + "FirehoseCidrBlock": "16.62.183.32/27" + }, "eu-north-1": { "FirehoseCidrBlock": "13.53.63.224/27" }, "eu-south-1": { "FirehoseCidrBlock": "15.161.135.128/27" }, + "eu-south-2": { + "FirehoseCidrBlock": "18.100.71.96/27" + }, "eu-west-1": { "FirehoseCidrBlock": "52.19.239.192/27" }, diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/manifest.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/manifest.json index 0a7108ae6b432..384d8d7856b19 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/manifest.json @@ -14,10 +14,11 @@ "environment": "aws://unknown-account/unknown-region", "properties": { "templateFile": "aws-cdk-firehose-delivery-stream-source-stream.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}/64eae3903c3ecdce5113c92844e63dfd0056464ecf7d1351e86180364d20c1c0.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/0b8a49e0b01e92c6b238e6d77538735e5b7a45a5bd1b32808ce9fe81fccc7c2e.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -104,15 +105,6 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } - ], - "DeliveryStreamNoSourceorEncryptionKey49457027": [ - { - "type": "aws:cdk:logicalId", - "data": "DeliveryStreamNoSourceorEncryptionKey49457027", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] - } ] }, "displayName": "aws-cdk-firehose-delivery-stream-source-stream" diff --git a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/tree.json b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/tree.json index f097397ad370a..b4a43bb9ac2cd 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-alpha/test/integ.delivery-stream.source-stream.js.snapshot/tree.json @@ -20,14 +20,14 @@ "aws:cdk:cloudformation:props": {} }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_s3.CfnBucket", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_s3.Bucket", + "version": "0.0.0" } }, "Role": { @@ -38,8 +38,8 @@ "id": "ImportRole", "path": "aws-cdk-firehose-delivery-stream-source-stream/Role/ImportRole", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" } }, "Resource": { @@ -63,8 +63,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" } }, "DefaultPolicy": { @@ -128,20 +128,20 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Policy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" } }, "Source Stream": { @@ -171,22 +171,22 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_kinesis.CfnStream", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_kinesis.Stream", + "version": "0.0.0" } }, "AwsCdkKinesisEncryptedStreamsUnsupportedRegions": { "id": "AwsCdkKinesisEncryptedStreamsUnsupportedRegions", "path": "aws-cdk-firehose-delivery-stream-source-stream/AwsCdkKinesisEncryptedStreamsUnsupportedRegions", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnCondition", + "version": "0.0.0" } }, "Delivery Stream": { @@ -201,8 +201,8 @@ "id": "ImportService Role", "path": "aws-cdk-firehose-delivery-stream-source-stream/Delivery Stream/Service Role/ImportService Role", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Resource", + "version": "0.0.0" } }, "Resource": { @@ -226,8 +226,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnRole", + "version": "0.0.0" } }, "DefaultPolicy": { @@ -273,20 +273,20 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.CfnPolicy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Policy", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_iam.Role", + "version": "0.0.0" } }, "Resource": { @@ -327,22 +327,22 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", + "version": "0.0.0" } }, "@aws-cdk--aws-kinesisfirehose.CidrBlocks": { "id": "@aws-cdk--aws-kinesisfirehose.CidrBlocks", "path": "aws-cdk-firehose-delivery-stream-source-stream/@aws-cdk--aws-kinesisfirehose.CidrBlocks", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnMapping", + "version": "0.0.0" } }, "Delivery Stream No Source Or Encryption Key": { @@ -373,36 +373,36 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.aws_kinesisfirehose.CfnDeliveryStream", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "@aws-cdk/aws-kinesisfirehose-alpha.DeliveryStream", + "version": "0.0.0" } }, "BootstrapVersion": { "id": "BootstrapVersion", "path": "aws-cdk-firehose-delivery-stream-source-stream/BootstrapVersion", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnParameter", + "version": "0.0.0" } }, "CheckBootstrapVersion": { "id": "CheckBootstrapVersion", "path": "aws-cdk-firehose-delivery-stream-source-stream/CheckBootstrapVersion", "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.CfnRule", + "version": "0.0.0" } } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.Stack", + "version": "0.0.0" } }, "Tree": { @@ -415,8 +415,8 @@ } }, "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" + "fqn": "aws-cdk-lib.App", + "version": "0.0.0" } } } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.assets.json b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.assets.json index f425131be7a56..488de330f9d78 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.assets.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.assets.json @@ -27,7 +27,7 @@ } } }, - "97e34fe63eef055d8f840edf2516da35e7a8f0f440303c76d3cde0daa3393f44": { + "a05127e41968d710aab4219add6693dd03376b7bae654f9ffe291a21f2aa7c68": { "source": { "path": "aws-cdk-firehose-delivery-stream-s3-all-properties.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "97e34fe63eef055d8f840edf2516da35e7a8f0f440303c76d3cde0daa3393f44.json", + "objectKey": "a05127e41968d710aab4219add6693dd03376b7bae654f9ffe291a21f2aa7c68.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.template.json b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.template.json index bcb74d8545e22..c3180c9549c1a 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.template.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/aws-cdk-firehose-delivery-stream-s3-all-properties.template.json @@ -702,6 +702,9 @@ "ap-south-1": { "FirehoseCidrBlock": "13.232.67.32/27" }, + "ap-south-2": { + "FirehoseCidrBlock": "18.60.192.128/27" + }, "ap-southeast-1": { "FirehoseCidrBlock": "13.228.64.192/27" }, @@ -726,12 +729,18 @@ "eu-central-1": { "FirehoseCidrBlock": "35.158.127.160/27" }, + "eu-central-2": { + "FirehoseCidrBlock": "16.62.183.32/27" + }, "eu-north-1": { "FirehoseCidrBlock": "13.53.63.224/27" }, "eu-south-1": { "FirehoseCidrBlock": "15.161.135.128/27" }, + "eu-south-2": { + "FirehoseCidrBlock": "18.100.71.96/27" + }, "eu-west-1": { "FirehoseCidrBlock": "52.19.239.192/27" }, diff --git a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/manifest.json b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/manifest.json index 89ac63fbec554..d1e730609d35e 100644 --- a/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-kinesisfirehose-destinations-alpha/test/integ.s3-bucket.lit.js.snapshot/manifest.json @@ -18,7 +18,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}/97e34fe63eef055d8f840edf2516da35e7a8f0f440303c76d3cde0daa3393f44.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/a05127e41968d710aab4219add6693dd03376b7bae654f9ffe291a21f2aa7c68.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.assets.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.assets.json index 7d8aaf4c06d21..a2459496af954 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.assets.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.assets.json @@ -1,7 +1,7 @@ { - "version": "33.0.0", + "version": "34.0.0", "files": { - "99b9aff7b7d42e6c47dd13d7034964f12b93cbe638fde0815e636313a0e7c9b0": { + "eac1c2181558fb8d64de1b029b3b58376b7191ef29b61b4585bdc8f7a45b3671": { "source": { "path": "aws-cdk-scheduler-schedule.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "99b9aff7b7d42e6c47dd13d7034964f12b93cbe638fde0815e636313a0e7c9b0.json", + "objectKey": "eac1c2181558fb8d64de1b029b3b58376b7191ef29b61b4585bdc8f7a45b3671.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.template.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.template.json index 69f6f034ea5c6..e27219e674e1d 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.template.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/aws-cdk-scheduler-schedule.template.json @@ -114,6 +114,11 @@ "Arn" ] }, + "Input": "\"Input Text\"", + "RetryPolicy": { + "MaximumEventAgeInSeconds": 180, + "MaximumRetryAttempts": 3 + }, "RoleArn": { "Fn::GetAtt": [ "Role1ABCC5F0", @@ -139,6 +144,41 @@ "Arn" ] }, + "Input": "\"Input Text\"", + "RetryPolicy": { + "MaximumEventAgeInSeconds": 180, + "MaximumRetryAttempts": 3 + }, + "RoleArn": { + "Fn::GetAtt": [ + "Role1ABCC5F0", + "Arn" + ] + } + } + } + }, + "TargetOverrideScheduleFF8CB184": { + "Type": "AWS::Scheduler::Schedule", + "Properties": { + "FlexibleTimeWindow": { + "Mode": "OFF" + }, + "ScheduleExpression": "rate(12 hours)", + "ScheduleExpressionTimezone": "Etc/UTC", + "State": "ENABLED", + "Target": { + "Arn": { + "Fn::GetAtt": [ + "Function76856677", + "Arn" + ] + }, + "Input": "\"Changed Text\"", + "RetryPolicy": { + "MaximumEventAgeInSeconds": 360, + "MaximumRetryAttempts": 5 + }, "RoleArn": { "Fn::GetAtt": [ "Role1ABCC5F0", @@ -217,6 +257,11 @@ "Arn" ] }, + "Input": "\"Input Text\"", + "RetryPolicy": { + "MaximumEventAgeInSeconds": 180, + "MaximumRetryAttempts": 3 + }, "RoleArn": { "Fn::GetAtt": [ "Role1ABCC5F0", diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/cdk.out b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/cdk.out index 560dae10d018f..2313ab5436501 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/cdk.out +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"33.0.0"} \ No newline at end of file +{"version":"34.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/integ.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/integ.json index 8bd3af4b50e53..c1aec1a40f53f 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/integ.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/integ.json @@ -1,5 +1,5 @@ { - "version": "33.0.0", + "version": "34.0.0", "testCases": { "integtest-schedule/DefaultTest": { "stacks": [ diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/integtestscheduleDefaultTestDeployAssert24CB3896.assets.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/integtestscheduleDefaultTestDeployAssert24CB3896.assets.json index 0ec5b6018b44a..8f8a003c1b5ba 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/integtestscheduleDefaultTestDeployAssert24CB3896.assets.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/integtestscheduleDefaultTestDeployAssert24CB3896.assets.json @@ -1,5 +1,5 @@ { - "version": "33.0.0", + "version": "34.0.0", "files": { "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { "source": { diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/manifest.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/manifest.json index 89f544c6f0432..482a334a2ce96 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "33.0.0", + "version": "34.0.0", "artifacts": { "aws-cdk-scheduler-schedule.assets": { "type": "cdk:asset-manifest", @@ -18,7 +18,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}/99b9aff7b7d42e6c47dd13d7034964f12b93cbe638fde0815e636313a0e7c9b0.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/eac1c2181558fb8d64de1b029b3b58376b7191ef29b61b4585bdc8f7a45b3671.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -70,6 +70,12 @@ "data": "DisabledScheduleA1DF7F0F" } ], + "/aws-cdk-scheduler-schedule/TargetOverrideSchedule/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "TargetOverrideScheduleFF8CB184" + } + ], "/aws-cdk-scheduler-schedule/AllSchedulerErrorsAlarm/Resource": [ { "type": "aws:cdk:logicalId", diff --git a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/tree.json b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/tree.json index a16dc5b4a296f..0255afcabc32c 100644 --- a/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-scheduler-alpha/test/integ.schedule.js.snapshot/tree.json @@ -219,6 +219,11 @@ "Role1ABCC5F0", "Arn" ] + }, + "input": "\"Input Text\"", + "retryPolicy": { + "maximumEventAgeInSeconds": 180, + "maximumRetryAttempts": 3 } } } @@ -262,6 +267,59 @@ "Role1ABCC5F0", "Arn" ] + }, + "input": "\"Input Text\"", + "retryPolicy": { + "maximumEventAgeInSeconds": 180, + "maximumRetryAttempts": 3 + } + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_scheduler.CfnSchedule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-scheduler-alpha.Schedule", + "version": "0.0.0" + } + }, + "TargetOverrideSchedule": { + "id": "TargetOverrideSchedule", + "path": "aws-cdk-scheduler-schedule/TargetOverrideSchedule", + "children": { + "Resource": { + "id": "Resource", + "path": "aws-cdk-scheduler-schedule/TargetOverrideSchedule/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Scheduler::Schedule", + "aws:cdk:cloudformation:props": { + "flexibleTimeWindow": { + "mode": "OFF" + }, + "scheduleExpression": "rate(12 hours)", + "scheduleExpressionTimezone": "Etc/UTC", + "state": "ENABLED", + "target": { + "arn": { + "Fn::GetAtt": [ + "Function76856677", + "Arn" + ] + }, + "roleArn": { + "Fn::GetAtt": [ + "Role1ABCC5F0", + "Arn" + ] + }, + "input": "\"Changed Text\"", + "retryPolicy": { + "maximumEventAgeInSeconds": 360, + "maximumRetryAttempts": 5 } } } @@ -392,6 +450,11 @@ "Role1ABCC5F0", "Arn" ] + }, + "input": "\"Input Text\"", + "retryPolicy": { + "maximumEventAgeInSeconds": 180, + "maximumRetryAttempts": 3 } } } From 23ce211af07f102e215a605cb73e136fa1fb8f71 Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 31 Oct 2023 14:06:24 -0400 Subject: [PATCH 13/15] update snapshots AGAIN Signed-off-by: Sumu --- .../integ-apigwv2-lambda-connect-integration.assets.json | 4 ++-- .../integ-apigwv2-lambda-connect-integration.template.json | 4 ++-- .../manifest.json | 2 +- .../tree.json | 4 ++-- .../test/websocket/integ.lambda-connect-disconnect-trigger.ts | 4 +++- 5 files changed, 10 insertions(+), 8 deletions(-) diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json index a2417bccec02d..b2efe2d122ad2 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.assets.json @@ -27,7 +27,7 @@ } } }, - "ed272b6c4a8aae3814d65d7420d862636797bf81af22c06e22a29abbaac44ca8": { + "8d51b7c174041dae18b57745e88660ee14de05b2ac0e42fb860dca1ff5677b71": { "source": { "path": "integ-apigwv2-lambda-connect-integration.template.json", "packaging": "file" @@ -35,7 +35,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "ed272b6c4a8aae3814d65d7420d862636797bf81af22c06e22a29abbaac44ca8.json", + "objectKey": "8d51b7c174041dae18b57745e88660ee14de05b2ac0e42fb860dca1ff5677b71.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json index b5e8c4f4e2400..c61991e3b6d33 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/integ-apigwv2-lambda-connect-integration.template.json @@ -273,7 +273,7 @@ { "Ref": "WebSocketAPIDA75128A" }, - "/*/*$connect" + "/*$connect" ] ] } @@ -363,7 +363,7 @@ { "Ref": "WebSocketAPIDA75128A" }, - "/*/*$disconnect" + "/*$disconnect" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json index 2c9e86a811e32..43f212b29e333 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/manifest.json @@ -18,7 +18,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}/ed272b6c4a8aae3814d65d7420d862636797bf81af22c06e22a29abbaac44ca8.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/8d51b7c174041dae18b57745e88660ee14de05b2ac0e42fb860dca1ff5677b71.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json index b168b11a163f1..26157d6a3c755 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.js.snapshot/tree.json @@ -492,7 +492,7 @@ { "Ref": "WebSocketAPIDA75128A" }, - "/*/*$connect" + "/*$connect" ] ] } @@ -626,7 +626,7 @@ { "Ref": "WebSocketAPIDA75128A" }, - "/*/*$disconnect" + "/*$disconnect" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts index 5509c4e321fbc..8078678f45557 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda-connect-disconnect-trigger.ts @@ -76,4 +76,6 @@ new WebSocketStage( }, ); -new IntegTest(app, 'Integ', { testCases: [stack] }); \ No newline at end of file +new IntegTest(app, 'Integ', { testCases: [stack] }); + +app.synth(); \ No newline at end of file From 273e2e0eb300c5483b48b63997dadf4210648951 Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 31 Oct 2023 14:56:48 -0400 Subject: [PATCH 14/15] update integ.lambda snapshots in websocket Signed-off-by: Sumu --- .../WebSocketApiInteg.assets.json | 4 ++-- .../WebSocketApiInteg.template.json | 8 ++++---- .../test/websocket/integ.lambda.js.snapshot/manifest.json | 2 +- .../test/websocket/integ.lambda.js.snapshot/tree.json | 8 ++++---- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json index 806e1a698a8a3..c73ed81c6cb7f 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "26e34316c6931e2609524675771603977641dab52471e7fb4c21e998529ed3fd": { + "fa386136122b6cd106460ddbdcd437d10712be61617b8d1bf2110a459aa9e233": { "source": { "path": "WebSocketApiInteg.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "26e34316c6931e2609524675771603977641dab52471e7fb4c21e998529ed3fd.json", + "objectKey": "fa386136122b6cd106460ddbdcd437d10712be61617b8d1bf2110a459aa9e233.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json index b6e930b1fa098..e50d8cfbe1645 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/WebSocketApiInteg.template.json @@ -239,7 +239,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$connect" + "/*$connect" ] ] } @@ -329,7 +329,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$disconnect" + "/*$disconnect" ] ] } @@ -419,7 +419,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$default" + "/*$default" ] ] } @@ -509,7 +509,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*sendmessage" + "/*sendmessage" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json index f38f0b09434e2..1f2c3210e48af 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/manifest.json @@ -18,7 +18,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}/26e34316c6931e2609524675771603977641dab52471e7fb4c21e998529ed3fd.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/fa386136122b6cd106460ddbdcd437d10712be61617b8d1bf2110a459aa9e233.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json index a3eaa745e06b2..990d79acbeef9 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-integrations-alpha/test/websocket/integ.lambda.js.snapshot/tree.json @@ -430,7 +430,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$connect" + "/*$connect" ] ] } @@ -564,7 +564,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$disconnect" + "/*$disconnect" ] ] } @@ -698,7 +698,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*$default" + "/*$default" ] ] } @@ -832,7 +832,7 @@ { "Ref": "mywsapi32E6CE11" }, - "/*/*sendmessage" + "/*sendmessage" ] ] } From 83a6e16124cbcc64eb1543e73240ff782fdf9587 Mon Sep 17 00:00:00 2001 From: Sumu Date: Tue, 31 Oct 2023 15:26:24 -0400 Subject: [PATCH 15/15] update snapshots in authorizers websocket/integ.iam test Signed-off-by: Sumu --- .../integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json | 4 ++-- .../integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json | 2 +- .../test/websocket/integ.iam.js.snapshot/manifest.json | 2 +- .../test/websocket/integ.iam.js.snapshot/tree.json | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json index acfbbfa7a6875..4ab5619801629 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.assets.json @@ -1,7 +1,7 @@ { "version": "34.0.0", "files": { - "89f3eb281075e38df0df45fd2cf30f90cd7bbaabddef614ebee1040631c2a0c6": { + "0fecdddcc93cb59f37820c43eaa8030e35f0be824e2f8e7b63bde0bb0b24e264": { "source": { "path": "IntegApiGatewayV2Iam.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "89f3eb281075e38df0df45fd2cf30f90cd7bbaabddef614ebee1040631c2a0c6.json", + "objectKey": "0fecdddcc93cb59f37820c43eaa8030e35f0be824e2f8e7b63bde0bb0b24e264.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json index ec0283f3bd2bd..5e3e47d97b6cf 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/IntegApiGatewayV2Iam.template.json @@ -100,7 +100,7 @@ { "Ref": "WebSocketApi34BCF99B" }, - "/*/*$connect" + "/*$connect" ] ] } diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json index 1168578c0a740..5cd819d527b7b 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/manifest.json @@ -18,7 +18,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}/89f3eb281075e38df0df45fd2cf30f90cd7bbaabddef614ebee1040631c2a0c6.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/0fecdddcc93cb59f37820c43eaa8030e35f0be824e2f8e7b63bde0bb0b24e264.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json index 3aeaca1832db8..2192187ed14af 100644 --- a/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-apigatewayv2-authorizers-alpha/test/websocket/integ.iam.js.snapshot/tree.json @@ -205,7 +205,7 @@ { "Ref": "WebSocketApi34BCF99B" }, - "/*/*$connect" + "/*$connect" ] ] }