Skip to content

Commit ea48444

Browse files
authored
chore: deprecate python3.6 (DataDog#391)
* remove `python3.6` from layer lookup * remove `python3.6` from scripts * remove `python3.6` from `layers.json` * update integration tests `.yml` * update integration tests snapshots * update `extension` snapshot * update `extension` snapshots * update `extension` snapshot * remove tag resource from policy * remove tag resource from policy - api * fix integration tests
1 parent 49ac23e commit ea48444

12 files changed

+49
-331
lines changed

integration_tests/correct_extension_apigateway_snapshot.json

Lines changed: 1 addition & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,6 @@
7171
}
7272
}
7373
},
74-
"PythonHello36LogGroup": {
75-
"Type": "AWS::Logs::LogGroup",
76-
"Properties": {
77-
"LogGroupName": "/aws/lambda/dd-sls-plugin-integration-test-dev-PythonHello36"
78-
}
79-
},
8074
"PythonHello37LogGroup": {
8175
"Type": "AWS::Logs::LogGroup",
8276
"Properties": {
@@ -249,56 +243,6 @@
249243
}
250244
}
251245
},
252-
"PythonHello36LambdaFunction": {
253-
"Type": "AWS::Lambda::Function",
254-
"Properties": {
255-
"Code": {
256-
"S3Bucket": {
257-
"Ref": "ServerlessDeploymentBucket"
258-
},
259-
"S3Key": "serverless/dd-sls-plugin-integration-test/dev/XXXXXXXXXXXXX-XXXX-XX-XXXXX:XX:XX.XXXX/dd-sls-plugin-integration-test.zip"
260-
},
261-
"Handler": "datadog_lambda.handler.handler",
262-
"Runtime": "python3.6",
263-
"FunctionName": "dd-sls-plugin-integration-test-dev-PythonHello36",
264-
"MemorySize": 1024,
265-
"Timeout": 6,
266-
"Tags": [
267-
{
268-
"Key": "dd_sls_plugin",
269-
"Value": "vX.XX.X"
270-
}
271-
],
272-
"Environment": {
273-
"Variables": {
274-
"DD_API_KEY": 1234,
275-
"DD_SITE": "datadoghq.com",
276-
"DD_LOG_LEVEL": "info",
277-
"DD_TRACE_ENABLED": true,
278-
"DD_MERGE_XRAY_TRACES": false,
279-
"DD_LOGS_INJECTION": true,
280-
"DD_SERVERLESS_LOGS_ENABLED": true,
281-
"DD_CAPTURE_LAMBDA_PAYLOAD": false,
282-
"DD_SERVICE": "dd-sls-plugin-integration-test",
283-
"DD_ENV": "dev",
284-
"DD_LAMBDA_HANDLER": "py_handler.hello"
285-
}
286-
},
287-
"Role": {
288-
"Fn::GetAtt": [
289-
"IamRoleLambdaExecution",
290-
"Arn"
291-
]
292-
},
293-
"Layers": [
294-
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Python36:XXX",
295-
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Extension:XXX"
296-
]
297-
},
298-
"DependsOn": [
299-
"PythonHello36LogGroup"
300-
]
301-
},
302246
"PythonHello37LambdaFunction": {
303247
"Type": "AWS::Lambda::Function",
304248
"Properties": {
@@ -987,24 +931,14 @@
987931
]
988932
},
989933
"Layers": [
990-
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Ruby3-2:19",
934+
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Ruby3-2:XXX",
991935
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Extension:XXX"
992936
]
993937
},
994938
"DependsOn": [
995939
"RubyHello32LogGroup"
996940
]
997941
},
998-
"PythonHello36LambdaVersionXXXX": {
999-
"Type": "AWS::Lambda::Version",
1000-
"DeletionPolicy": "Retain",
1001-
"Properties": {
1002-
"FunctionName": {
1003-
"Ref": "PythonHello36LambdaFunction"
1004-
},
1005-
"CodeSha256": "XXXX"
1006-
}
1007-
},
1008942
"PythonHello37LambdaVersionXXXX": {
1009943
"Type": "AWS::Lambda::Version",
1010944
"DeletionPolicy": "Retain",
@@ -1886,15 +1820,6 @@
18861820
"Name": "sls-dd-sls-plugin-integration-test-dev-ServerlessDeploymentBucketName"
18871821
}
18881822
},
1889-
"PythonHello36LambdaFunctionQualifiedArn": {
1890-
"Description": "Current Lambda function version",
1891-
"Value": {
1892-
"Ref": "PythonHello36LambdaVersionXXXX"
1893-
},
1894-
"Export": {
1895-
"Name": "sls-dd-sls-plugin-integration-test-dev-PythonHello36LambdaFunctionQualifiedArn"
1896-
}
1897-
},
18981823
"PythonHello37LambdaFunctionQualifiedArn": {
18991824
"Description": "Current Lambda function version",
19001825
"Value": {

integration_tests/correct_extension_snapshot.json

Lines changed: 44 additions & 121 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,6 @@
7171
}
7272
}
7373
},
74-
"PythonHello36LogGroup": {
75-
"Type": "AWS::Logs::LogGroup",
76-
"Properties": {
77-
"LogGroupName": "/aws/lambda/dd-sls-plugin-integration-test-dev-PythonHello36"
78-
}
79-
},
8074
"PythonHello37LogGroup": {
8175
"Type": "AWS::Logs::LogGroup",
8276
"Properties": {
@@ -244,22 +238,6 @@
244238
}
245239
}
246240
},
247-
"ProviderLevelLayerLambdaLayer": {
248-
"Type": "AWS::Lambda::LayerVersion",
249-
"Properties": {
250-
"Content": {
251-
"S3Bucket": {
252-
"Ref": "ServerlessDeploymentBucket"
253-
},
254-
"S3Key": "serverless/dd-sls-plugin-integration-test/dev/XXXXXXXXXXXXX-XXXX-XX-XXXXX:XX:XX.XXXX/ProviderLevelLayer.zip"
255-
},
256-
"LayerName": "dd-sls-plugin-integration-test-dev-ProviderLevelLayer",
257-
"Description": "It's a text file",
258-
"CompatibleRuntimes": [
259-
"nodejs12.x"
260-
]
261-
}
262-
},
263241
"FunctionLevelLayerLambdaLayer": {
264242
"Type": "AWS::Lambda::LayerVersion",
265243
"Properties": {
@@ -273,57 +251,21 @@
273251
"Description": "It's also a text file"
274252
}
275253
},
276-
"PythonHello36LambdaFunction": {
277-
"Type": "AWS::Lambda::Function",
254+
"ProviderLevelLayerLambdaLayer": {
255+
"Type": "AWS::Lambda::LayerVersion",
278256
"Properties": {
279-
"Code": {
257+
"Content": {
280258
"S3Bucket": {
281259
"Ref": "ServerlessDeploymentBucket"
282260
},
283-
"S3Key": "serverless/dd-sls-plugin-integration-test/dev/XXXXXXXXXXXXX-XXXX-XX-XXXXX:XX:XX.XXXX/dd-sls-plugin-integration-test.zip"
284-
},
285-
"Handler": "datadog_lambda.handler.handler",
286-
"Runtime": "python3.6",
287-
"FunctionName": "dd-sls-plugin-integration-test-dev-PythonHello36",
288-
"MemorySize": 1024,
289-
"Timeout": 6,
290-
"Tags": [
291-
{
292-
"Key": "dd_sls_plugin",
293-
"Value": "vX.XX.X"
294-
}
295-
],
296-
"Environment": {
297-
"Variables": {
298-
"DD_API_KEY": 1234,
299-
"DD_SITE": "datadoghq.com",
300-
"DD_TRACE_ENABLED": true,
301-
"DD_MERGE_XRAY_TRACES": false,
302-
"DD_LOGS_INJECTION": true,
303-
"DD_SERVERLESS_LOGS_ENABLED": true,
304-
"DD_CAPTURE_LAMBDA_PAYLOAD": false,
305-
"DD_SERVICE": "dd-sls-plugin-integration-test",
306-
"DD_ENV": "dev",
307-
"DD_LAMBDA_HANDLER": "py_handler.hello"
308-
}
309-
},
310-
"Role": {
311-
"Fn::GetAtt": [
312-
"IamRoleLambdaExecution",
313-
"Arn"
314-
]
261+
"S3Key": "serverless/dd-sls-plugin-integration-test/dev/XXXXXXXXXXXXX-XXXX-XX-XXXXX:XX:XX.XXXX/ProviderLevelLayer.zip"
315262
},
316-
"Layers": [
317-
{
318-
"Ref": "ProviderLevelLayerLambdaLayer"
319-
},
320-
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Python36:XXX",
321-
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Extension:XXX"
263+
"LayerName": "dd-sls-plugin-integration-test-dev-ProviderLevelLayer",
264+
"Description": "It's a text file",
265+
"CompatibleRuntimes": [
266+
"nodejs12.x"
322267
]
323-
},
324-
"DependsOn": [
325-
"PythonHello36LogGroup"
326-
]
268+
}
327269
},
328270
"PythonHello37LambdaFunction": {
329271
"Type": "AWS::Lambda::Function",
@@ -1074,34 +1016,14 @@
10741016
{
10751017
"Ref": "ProviderLevelLayerLambdaLayer"
10761018
},
1077-
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Ruby3-2:19",
1019+
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Ruby3-2:XXX",
10781020
"arn:aws:lambda:sa-east-1:464622532012:layer:Datadog-Extension:XXX"
10791021
]
10801022
},
10811023
"DependsOn": [
10821024
"RubyHello32LogGroup"
10831025
]
10841026
},
1085-
"JavascriptHello12DashxLambdaVersionXXXX": {
1086-
"Type": "AWS::Lambda::Version",
1087-
"DeletionPolicy": "Retain",
1088-
"Properties": {
1089-
"FunctionName": {
1090-
"Ref": "JavascriptHello12DashxLambdaFunction"
1091-
},
1092-
"CodeSha256": "XXXX"
1093-
}
1094-
},
1095-
"PythonHello36LambdaVersionXXXX": {
1096-
"Type": "AWS::Lambda::Version",
1097-
"DeletionPolicy": "Retain",
1098-
"Properties": {
1099-
"FunctionName": {
1100-
"Ref": "PythonHello36LambdaFunction"
1101-
},
1102-
"CodeSha256": "XXXX"
1103-
}
1104-
},
11051027
"PythonHello37LambdaVersionXXXX": {
11061028
"Type": "AWS::Lambda::Version",
11071029
"DeletionPolicy": "Retain",
@@ -1241,6 +1163,16 @@
12411163
},
12421164
"CodeSha256": "XXXX"
12431165
}
1166+
},
1167+
"JavascriptHello12DashxLambdaVersionXXXX": {
1168+
"Type": "AWS::Lambda::Version",
1169+
"DeletionPolicy": "Retain",
1170+
"Properties": {
1171+
"FunctionName": {
1172+
"Ref": "JavascriptHello12DashxLambdaFunction"
1173+
},
1174+
"CodeSha256": "XXXX"
1175+
}
12441176
}
12451177
},
12461178
"Outputs": {
@@ -1252,29 +1184,6 @@
12521184
"Name": "sls-dd-sls-plugin-integration-test-dev-ServerlessDeploymentBucketName"
12531185
}
12541186
},
1255-
"ProviderLevelLayerLambdaLayerQualifiedArn": {
1256-
"Description": "Current Lambda layer version",
1257-
"Value": {
1258-
"Ref": "ProviderLevelLayerLambdaLayer"
1259-
},
1260-
"Export": {
1261-
"Name": "sls-dd-sls-plugin-integration-test-dev-ProviderLevelLayerLambdaLayerQualifiedArn"
1262-
}
1263-
},
1264-
"ProviderLevelLayerLambdaLayerHash": {
1265-
"Description": "Current Lambda layer hash",
1266-
"Value": "ca99f65eb22bc573edd4f9ac2a087d0dd5acc751",
1267-
"Export": {
1268-
"Name": "sls-dd-sls-plugin-integration-test-dev-ProviderLevelLayerLambdaLayerHash"
1269-
}
1270-
},
1271-
"ProviderLevelLayerLambdaLayerS3Key": {
1272-
"Description": "Current Lambda layer S3Key",
1273-
"Value": "serverless/dd-sls-plugin-integration-test/dev/XXXXXXXXXXXXX-XXXX-XX-XXXXX:XX:XX.XXXX/ProviderLevelLayer.zip",
1274-
"Export": {
1275-
"Name": "sls-dd-sls-plugin-integration-test-dev-ProviderLevelLayerLambdaLayerS3Key"
1276-
}
1277-
},
12781187
"FunctionLevelLayerLambdaLayerQualifiedArn": {
12791188
"Description": "Current Lambda layer version",
12801189
"Value": {
@@ -1298,22 +1207,27 @@
12981207
"Name": "sls-dd-sls-plugin-integration-test-dev-FunctionLevelLayerLambdaLayerS3Key"
12991208
}
13001209
},
1301-
"JavascriptHello12DashxLambdaFunctionQualifiedArn": {
1302-
"Description": "Current Lambda function version",
1210+
"ProviderLevelLayerLambdaLayerQualifiedArn": {
1211+
"Description": "Current Lambda layer version",
13031212
"Value": {
1304-
"Ref": "JavascriptHello12DashxLambdaVersionXXXX"
1213+
"Ref": "ProviderLevelLayerLambdaLayer"
13051214
},
13061215
"Export": {
1307-
"Name": "sls-dd-sls-plugin-integration-test-dev-JavascriptHello12DashxLambdaFunctionQualifiedArn"
1216+
"Name": "sls-dd-sls-plugin-integration-test-dev-ProviderLevelLayerLambdaLayerQualifiedArn"
13081217
}
13091218
},
1310-
"PythonHello36LambdaFunctionQualifiedArn": {
1311-
"Description": "Current Lambda function version",
1312-
"Value": {
1313-
"Ref": "PythonHello36LambdaVersionXXXX"
1314-
},
1219+
"ProviderLevelLayerLambdaLayerHash": {
1220+
"Description": "Current Lambda layer hash",
1221+
"Value": "ca99f65eb22bc573edd4f9ac2a087d0dd5acc751",
13151222
"Export": {
1316-
"Name": "sls-dd-sls-plugin-integration-test-dev-PythonHello36LambdaFunctionQualifiedArn"
1223+
"Name": "sls-dd-sls-plugin-integration-test-dev-ProviderLevelLayerLambdaLayerHash"
1224+
}
1225+
},
1226+
"ProviderLevelLayerLambdaLayerS3Key": {
1227+
"Description": "Current Lambda layer S3Key",
1228+
"Value": "serverless/dd-sls-plugin-integration-test/dev/XXXXXXXXXXXXX-XXXX-XX-XXXXX:XX:XX.XXXX/ProviderLevelLayer.zip",
1229+
"Export": {
1230+
"Name": "sls-dd-sls-plugin-integration-test-dev-ProviderLevelLayerLambdaLayerS3Key"
13171231
}
13181232
},
13191233
"PythonHello37LambdaFunctionQualifiedArn": {
@@ -1441,6 +1355,15 @@
14411355
"Export": {
14421356
"Name": "sls-dd-sls-plugin-integration-test-dev-RubyHello32LambdaFunctionQualifiedArn"
14431357
}
1358+
},
1359+
"JavascriptHello12DashxLambdaFunctionQualifiedArn": {
1360+
"Description": "Current Lambda function version",
1361+
"Value": {
1362+
"Ref": "JavascriptHello12DashxLambdaVersionXXXX"
1363+
},
1364+
"Export": {
1365+
"Name": "sls-dd-sls-plugin-integration-test-dev-JavascriptHello12DashxLambdaFunctionQualifiedArn"
1366+
}
14441367
}
14451368
}
14461369
}

0 commit comments

Comments
 (0)