From f504adec4030fc820dd7401f8824a8084f8dc93c Mon Sep 17 00:00:00 2001 From: Kaizen Conroy <36202692+kaizencc@users.noreply.github.com> Date: Tue, 28 Nov 2023 15:01:04 -0500 Subject: [PATCH] docs(lambda): explain NODEJS_LATEST better (#28171) Some confusion (including myself) surrounding what `NODEJS_LATEST` entails. So I'm clearing it up in this doc update. Basically, `NODEJS_LATEST` points to the latest nodejs region everywhere, and some regions lag behind when an official version is announced. So even though `NODEJS_20` exists, `NODEJS_LATEST` currently points to `NODEJS_18` until node20 has populated to all aws regions, including air-gapped regions. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license* --- packages/aws-cdk-lib/aws-lambda/lib/runtime.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/aws-cdk-lib/aws-lambda/lib/runtime.ts b/packages/aws-cdk-lib/aws-lambda/lib/runtime.ts index 96eb55b41231f..0013d67ad2079 100644 --- a/packages/aws-cdk-lib/aws-lambda/lib/runtime.ts +++ b/packages/aws-cdk-lib/aws-lambda/lib/runtime.ts @@ -110,7 +110,8 @@ export class Runtime { public static readonly NODEJS_20_X = new Runtime('nodejs20.x', RuntimeFamily.NODEJS, { supportsInlineCode: true }); /** - * The latest NodeJS version currently available + * The latest NodeJS version currently available in ALL regions (not necessarily the latest NodeJS version + * available in YOUR region). */ public static readonly NODEJS_LATEST = new Runtime('nodejs18.x', RuntimeFamily.NODEJS, { supportsInlineCode: true, isVariable: true });