Skip to content

Commit b9d1977

Browse files
authored
chore: end of support for nodejs12x runtime (#1190)
* chore: remove nodejs12 from codebase * chore: removed nodejs12 from e2eUtils * chore: housekeeping * chore: update tsconfig to ES2020
1 parent 804d47c commit b9d1977

27 files changed

+41
-48
lines changed

.devcontainer/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# See here for image contents: https://github.com/microsoft/vscode-dev-containers/blob/v0.212.0/containers/javascript-node/.devcontainer/base.Dockerfile
2-
# [Choice] Node.js version (use -bullseye variants on local arm64/Apple Silicon): 16, 14, 12, 16-bullseye, 14-bullseye, 12-bullseye, 16-buster, 14-buster, 12-buster
2+
# [Choice] Node.js version (use -bullseye variants on local arm64/Apple Silicon): 16, 14, 16-bullseye, 14-bullseye, 16-buster, 14-buster
33
ARG VARIANT="16-bullseye"
44
FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:0-${VARIANT}
55

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"name": "Node.js",
55
"build": {
66
"dockerfile": "Dockerfile",
7-
// Update 'VARIANT' to pick a Node version: 16, 14, 12.
7+
// Update 'VARIANT' to pick a Node version: 16, 14.
88
// Append -bullseye or -buster to pin to an OS version.
99
// Use -bullseye variants on local arm64/Apple Silicon.
1010
"args": {

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,6 @@ body:
5858
attributes:
5959
label: AWS Lambda function runtime
6060
options:
61-
- 12.x
6261
- 14.x
6362
- 16.x
6463
validations:

.github/workflows/reusable-run-linting-check-and-unit-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
NODE_ENV: dev
1111
strategy:
1212
matrix:
13-
version: [12, 14, 16]
13+
version: [14, 16]
1414
fail-fast: false
1515
steps:
1616
- name: Checkout code

.github/workflows/run-e2e-tests.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
strategy:
2121
matrix:
2222
package: [logger, metrics, tracer]
23-
version: [12, 14, 16]
23+
version: [14, 16]
2424
fail-fast: false
2525
steps:
2626
- name: Checkout Repo
@@ -70,7 +70,7 @@ jobs:
7070
strategy:
7171
fail-fast: false
7272
matrix:
73-
version: [12, 14, 16]
73+
version: [14, 16]
7474
steps:
7575
- name: Checkout Repo
7676
uses: actions/checkout@v3

layer-publisher/src/powertools-typescript-layer.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,11 @@ export class PowerToolsTypeScriptLayer extends lambda.LayerVersion {
3838
super(scope, id, {
3939
layerVersionName: props?.layerVersionName,
4040
description: `Lambda Powertools for TypeScript version ${props?.version}`,
41-
compatibleRuntimes: [ lambda.Runtime.NODEJS_12_X, lambda.Runtime.NODEJS_14_X, lambda.Runtime.NODEJS_16_X ],
41+
compatibleRuntimes: [ lambda.Runtime.NODEJS_14_X, lambda.Runtime.NODEJS_16_X ],
4242
code: lambda.Code.fromAsset(path.join(__dirname, '.'), {
4343
assetHash: Md5.hashStr(commandJoined),
4444
bundling: {
45-
image: lambda.Runtime.NODEJS_12_X.bundlingImage,
45+
image: lambda.Runtime.NODEJS_14_X.bundlingImage,
4646
local: {
4747
tryBundle(outputDir: string) {
4848
try {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@
8080
"lib/**/*"
8181
],
8282
"engines": {
83-
"node": ">=12"
83+
"node": ">=14"
8484
},
8585
"dependencies": {
8686
"hosted-git-info": "^5.0.0"

packages/commons/tests/utils/e2eUtils.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,9 @@ import { InvocationLogs } from './InvocationLogs';
1414

1515
const lambdaClient = new AWS.Lambda();
1616

17-
const testRuntimeKeys = [ 'nodejs12x', 'nodejs14x', 'nodejs16x' ];
17+
const testRuntimeKeys = [ 'nodejs14x', 'nodejs16x' ];
1818
export type TestRuntimesKey = typeof testRuntimeKeys[number];
1919
export const TEST_RUNTIMES: Record<TestRuntimesKey, Runtime> = {
20-
nodejs12x: Runtime.NODEJS_12_X,
2120
nodejs14x: Runtime.NODEJS_14_X,
2221
nodejs16x: Runtime.NODEJS_16_X,
2322
};

packages/commons/tsconfig-dev.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"compilerOptions": {
33
"experimentalDecorators": true,
44
"noImplicitAny": true,
5-
"target": "ES2019",
5+
"target": "ES2020",
66
"module": "commonjs",
77
"declaration": true,
88
"declarationMap": true,
@@ -23,7 +23,7 @@
2323
"watchDirectory": "useFsEvents",
2424
"fallbackPolling": "dynamicPriority"
2525
},
26-
"lib": [ "es2019" ],
26+
"lib": [ "es2020" ],
2727
"types": [
2828
"jest",
2929
"node"

packages/commons/tsconfig.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"compilerOptions": {
33
"experimentalDecorators": true,
44
"noImplicitAny": true,
5-
"target": "ES2019",
5+
"target": "ES2020",
66
"module": "commonjs",
77
"declaration": true,
88
"declarationMap": true,
@@ -23,7 +23,7 @@
2323
"watchDirectory": "useFsEvents",
2424
"fallbackPolling": "dynamicPriority"
2525
},
26-
"lib": [ "es2019" ],
26+
"lib": [ "es2020" ],
2727
"types": [
2828
"jest",
2929
"node"

0 commit comments

Comments
 (0)