Skip to content

(lambda): (CDK lambdas still using node16) #26461

@alexherriott

Description

@alexherriott

Describe the bug

Since https://github.com/aws/aws-cdk/releases/tag/v2.87.0 CDK lambda runtime should be using node 18 runtime.

We are seeing some runtimes still using node 16 e.g. LogRetention lambda. (there may be more)

https://github.com/aws/aws-cdk/blob/v2.87.0/packages/aws-cdk-lib/aws-logs/lib/log-retention.ts

image

it seems to be defaulting to node_16 if a regional Fact is not set – where is this set? I couldn’t see anything in release notes relating to this. is this something AWS configures so that node 18 is used? Or do we have to do something?

Expected Behavior

node 18 runtime should be used in all CDK generated lambdas

Current Behavior

Node 16 is being used in some CDK generated lambdas

Reproduction Steps

this is autogenerated by CDK

Possible Solution

No response

Additional Information/Context

No response

CDK CLI Version

2.87.0

Framework Version

2.87.0

Node.js Version

16

OS

Ubuntu standard:6.0

Language

Typescript

Language Version

No response

Other information

No response

Metadata

Metadata

Assignees

Labels

@aws-cdk/aws-lambdaRelated to AWS LambdabugThis issue is a bug.node18-upgradeAny work (bug, feature) related to Node 18 upgradep1

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions