Skip to content

Commit b2d293d

Browse files
authored
feat(s3): update runtime of notifications-handler to python3.9 (#23209)
closes #20973 This upgrades the runtime of the internal function `notifications-resource-handler` from Python 3.7 to Python 3.9 Referring to the PR below #21483 ---- ### All Submissions: * [ ] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) ### Adding new Construct Runtime Dependencies: * [ ] This PR adds new construct runtime dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-construct-runtime-dependencies) ### New Features * [ ] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)? * [ ] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)? *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
1 parent 75e7c94 commit b2d293d

File tree

55 files changed

+2657
-430
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+2657
-430
lines changed

Diff for: packages/@aws-cdk/aws-lambda-event-sources/lib/kafka.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
import { md5hash } from '@aws-cdk/core/lib/helpers-internal';
21
import { ISecurityGroup, IVpc, SubnetSelection } from '@aws-cdk/aws-ec2';
32
import * as iam from '@aws-cdk/aws-iam';
43
import * as lambda from '@aws-cdk/aws-lambda';
54
import * as secretsmanager from '@aws-cdk/aws-secretsmanager';
65
import { Stack, Names } from '@aws-cdk/core';
6+
import { md5hash } from '@aws-cdk/core/lib/helpers-internal';
77
import { Construct } from 'constructs';
88
import { StreamEventSource, BaseStreamEventSourceProps } from './stream';
99

Diff for: packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.js.snapshot/asset.33e2651435a0d472a75c1e033c9832b21321d9e56711926b04c5705e5f63874c/__entrypoint__.js

+144
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.js.snapshot/asset.60767da3831353fede3cfe92efef10580a600592dec8ccbb06c051e95b9c1b26/__entrypoint__.js

-118
This file was deleted.

Diff for: packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.js.snapshot/asset.60767da3831353fede3cfe92efef10580a600592dec8ccbb06c051e95b9c1b26/index.d.ts

-1
This file was deleted.

Diff for: packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.js.snapshot/asset.60767da3831353fede3cfe92efef10580a600592dec8ccbb06c051e95b9c1b26/index.ts

-82
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"version":"20.0.0"}
1+
{"version":"22.0.0"}

Diff for: packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.js.snapshot/integ.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "20.0.0",
2+
"version": "22.0.0",
33
"testCases": {
44
"integ.s3": {
55
"stacks": [

Diff for: packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.js.snapshot/lambda-event-source-s3.assets.json

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,28 @@
11
{
2-
"version": "20.0.0",
2+
"version": "22.0.0",
33
"files": {
4-
"60767da3831353fede3cfe92efef10580a600592dec8ccbb06c051e95b9c1b26": {
4+
"33e2651435a0d472a75c1e033c9832b21321d9e56711926b04c5705e5f63874c": {
55
"source": {
6-
"path": "asset.60767da3831353fede3cfe92efef10580a600592dec8ccbb06c051e95b9c1b26",
6+
"path": "asset.33e2651435a0d472a75c1e033c9832b21321d9e56711926b04c5705e5f63874c",
77
"packaging": "zip"
88
},
99
"destinations": {
1010
"current_account-current_region": {
1111
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
12-
"objectKey": "60767da3831353fede3cfe92efef10580a600592dec8ccbb06c051e95b9c1b26.zip",
12+
"objectKey": "33e2651435a0d472a75c1e033c9832b21321d9e56711926b04c5705e5f63874c.zip",
1313
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
1414
}
1515
}
1616
},
17-
"0bd7f56caf58087052c78e8b8dfb76284423c45fe7556ed0ca3c5f9c47d6b79b": {
17+
"88cd97cf8b61eb834d47062d3a923e447d47131e886b9487a06833f23868a9ec": {
1818
"source": {
1919
"path": "lambda-event-source-s3.template.json",
2020
"packaging": "file"
2121
},
2222
"destinations": {
2323
"current_account-current_region": {
2424
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
25-
"objectKey": "0bd7f56caf58087052c78e8b8dfb76284423c45fe7556ed0ca3c5f9c47d6b79b.json",
25+
"objectKey": "88cd97cf8b61eb834d47062d3a923e447d47131e886b9487a06833f23868a9ec.json",
2626
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
2727
}
2828
}

Diff for: packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.js.snapshot/lambda-event-source-s3.template.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@
227227
"S3Bucket": {
228228
"Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}"
229229
},
230-
"S3Key": "60767da3831353fede3cfe92efef10580a600592dec8ccbb06c051e95b9c1b26.zip"
230+
"S3Key": "33e2651435a0d472a75c1e033c9832b21321d9e56711926b04c5705e5f63874c.zip"
231231
},
232232
"Timeout": 900,
233233
"MemorySize": 128,
@@ -322,7 +322,7 @@
322322
"Arn"
323323
]
324324
},
325-
"Runtime": "python3.7",
325+
"Runtime": "python3.9",
326326
"Timeout": 300
327327
},
328328
"DependsOn": [

Diff for: packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.js.snapshot/manifest.json

+8-8
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,6 @@
11
{
2-
"version": "20.0.0",
2+
"version": "22.0.0",
33
"artifacts": {
4-
"Tree": {
5-
"type": "cdk:tree",
6-
"properties": {
7-
"file": "tree.json"
8-
}
9-
},
104
"lambda-event-source-s3.assets": {
115
"type": "cdk:asset-manifest",
126
"properties": {
@@ -23,7 +17,7 @@
2317
"validateOnSynth": false,
2418
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}",
2519
"cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}",
26-
"stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/0bd7f56caf58087052c78e8b8dfb76284423c45fe7556ed0ca3c5f9c47d6b79b.json",
20+
"stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/88cd97cf8b61eb834d47062d3a923e447d47131e886b9487a06833f23868a9ec.json",
2721
"requiresBootstrapStackVersion": 6,
2822
"bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version",
2923
"additionalDependencies": [
@@ -125,6 +119,12 @@
125119
]
126120
},
127121
"displayName": "lambda-event-source-s3"
122+
},
123+
"Tree": {
124+
"type": "cdk:tree",
125+
"properties": {
126+
"file": "tree.json"
127+
}
128128
}
129129
}
130130
}

Diff for: packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.js.snapshot/tree.json

+61-29
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,6 @@
44
"id": "App",
55
"path": "",
66
"children": {
7-
"Tree": {
8-
"id": "Tree",
9-
"path": "Tree",
10-
"constructInfo": {
11-
"fqn": "constructs.Construct",
12-
"version": "10.1.85"
13-
}
14-
},
157
"lambda-event-source-s3": {
168
"id": "lambda-event-source-s3",
179
"path": "lambda-event-source-s3",
@@ -24,6 +16,14 @@
2416
"id": "ServiceRole",
2517
"path": "lambda-event-source-s3/F/ServiceRole",
2618
"children": {
19+
"ImportServiceRole": {
20+
"id": "ImportServiceRole",
21+
"path": "lambda-event-source-s3/F/ServiceRole/ImportServiceRole",
22+
"constructInfo": {
23+
"fqn": "@aws-cdk/core.Resource",
24+
"version": "0.0.0"
25+
}
26+
},
2727
"Resource": {
2828
"id": "Resource",
2929
"path": "lambda-event-source-s3/F/ServiceRole/Resource",
@@ -199,14 +199,14 @@
199199
"id": "Default",
200200
"path": "lambda-event-source-s3/B/AutoDeleteObjectsCustomResource/Default",
201201
"constructInfo": {
202-
"fqn": "constructs.Construct",
203-
"version": "10.1.85"
202+
"fqn": "@aws-cdk/core.CfnResource",
203+
"version": "0.0.0"
204204
}
205205
}
206206
},
207207
"constructInfo": {
208-
"fqn": "constructs.Construct",
209-
"version": "10.1.85"
208+
"fqn": "@aws-cdk/core.CustomResource",
209+
"version": "0.0.0"
210210
}
211211
},
212212
"Notifications": {
@@ -217,14 +217,14 @@
217217
"id": "Resource",
218218
"path": "lambda-event-source-s3/B/Notifications/Resource",
219219
"constructInfo": {
220-
"fqn": "constructs.Construct",
221-
"version": "10.1.85"
220+
"fqn": "@aws-cdk/core.CfnResource",
221+
"version": "0.0.0"
222222
}
223223
}
224224
},
225225
"constructInfo": {
226226
"fqn": "constructs.Construct",
227-
"version": "10.1.85"
227+
"version": "10.1.168"
228228
}
229229
},
230230
"AllowBucketNotificationsTolambdaeventsources3F74160805": {
@@ -271,30 +271,30 @@
271271
"id": "Staging",
272272
"path": "lambda-event-source-s3/Custom::S3AutoDeleteObjectsCustomResourceProvider/Staging",
273273
"constructInfo": {
274-
"fqn": "constructs.Construct",
275-
"version": "10.1.85"
274+
"fqn": "@aws-cdk/core.AssetStaging",
275+
"version": "0.0.0"
276276
}
277277
},
278278
"Role": {
279279
"id": "Role",
280280
"path": "lambda-event-source-s3/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role",
281281
"constructInfo": {
282-
"fqn": "constructs.Construct",
283-
"version": "10.1.85"
282+
"fqn": "@aws-cdk/core.CfnResource",
283+
"version": "0.0.0"
284284
}
285285
},
286286
"Handler": {
287287
"id": "Handler",
288288
"path": "lambda-event-source-s3/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler",
289289
"constructInfo": {
290-
"fqn": "constructs.Construct",
291-
"version": "10.1.85"
290+
"fqn": "@aws-cdk/core.CfnResource",
291+
"version": "0.0.0"
292292
}
293293
}
294294
},
295295
"constructInfo": {
296-
"fqn": "constructs.Construct",
297-
"version": "10.1.85"
296+
"fqn": "@aws-cdk/core.CustomResourceProvider",
297+
"version": "0.0.0"
298298
}
299299
},
300300
"BucketNotificationsHandler050a0587b7544547bf325f094a3db834": {
@@ -305,6 +305,14 @@
305305
"id": "Role",
306306
"path": "lambda-event-source-s3/BucketNotificationsHandler050a0587b7544547bf325f094a3db834/Role",
307307
"children": {
308+
"ImportRole": {
309+
"id": "ImportRole",
310+
"path": "lambda-event-source-s3/BucketNotificationsHandler050a0587b7544547bf325f094a3db834/Role/ImportRole",
311+
"constructInfo": {
312+
"fqn": "@aws-cdk/core.Resource",
313+
"version": "0.0.0"
314+
}
315+
},
308316
"Resource": {
309317
"id": "Resource",
310318
"path": "lambda-event-source-s3/BucketNotificationsHandler050a0587b7544547bf325f094a3db834/Role/Resource",
@@ -393,26 +401,50 @@
393401
"id": "Resource",
394402
"path": "lambda-event-source-s3/BucketNotificationsHandler050a0587b7544547bf325f094a3db834/Resource",
395403
"constructInfo": {
396-
"fqn": "constructs.Construct",
397-
"version": "10.1.85"
404+
"fqn": "@aws-cdk/core.CfnResource",
405+
"version": "0.0.0"
398406
}
399407
}
400408
},
401409
"constructInfo": {
402410
"fqn": "constructs.Construct",
403-
"version": "10.1.85"
411+
"version": "10.1.168"
412+
}
413+
},
414+
"BootstrapVersion": {
415+
"id": "BootstrapVersion",
416+
"path": "lambda-event-source-s3/BootstrapVersion",
417+
"constructInfo": {
418+
"fqn": "@aws-cdk/core.CfnParameter",
419+
"version": "0.0.0"
420+
}
421+
},
422+
"CheckBootstrapVersion": {
423+
"id": "CheckBootstrapVersion",
424+
"path": "lambda-event-source-s3/CheckBootstrapVersion",
425+
"constructInfo": {
426+
"fqn": "@aws-cdk/core.CfnRule",
427+
"version": "0.0.0"
404428
}
405429
}
406430
},
431+
"constructInfo": {
432+
"fqn": "@aws-cdk/core.Stack",
433+
"version": "0.0.0"
434+
}
435+
},
436+
"Tree": {
437+
"id": "Tree",
438+
"path": "Tree",
407439
"constructInfo": {
408440
"fqn": "constructs.Construct",
409-
"version": "10.1.85"
441+
"version": "10.1.168"
410442
}
411443
}
412444
},
413445
"constructInfo": {
414-
"fqn": "constructs.Construct",
415-
"version": "10.1.85"
446+
"fqn": "@aws-cdk/core.App",
447+
"version": "0.0.0"
416448
}
417449
}
418450
}

Diff for: packages/@aws-cdk/aws-s3-notifications/package.json

+1
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@
7575
"@aws-cdk/assertions": "0.0.0",
7676
"@aws-cdk/cdk-build-tools": "0.0.0",
7777
"@aws-cdk/integ-runner": "0.0.0",
78+
"@aws-cdk/integ-tests": "0.0.0",
7879
"@aws-cdk/pkglint": "0.0.0",
7980
"@types/jest": "^27.5.2",
8081
"jest": "^27.5.1"
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"version":"20.0.0"}
1+
{"version":"22.0.0"}

Diff for: packages/@aws-cdk/aws-s3-notifications/test/integ.notifications.js.snapshot/integ.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "20.0.0",
2+
"version": "22.0.0",
33
"testCases": {
44
"integ.notifications": {
55
"stacks": [

0 commit comments

Comments
 (0)