Skip to content

Conversation

@jackylamhk
Copy link
Contributor

Reopens #60

While the default custom resources runtime version has been bumped to Node 22, the plugin still does not make sure that the provider runtime version is at least Node 18.

AWS only includes AWS SDK v2 for Node <= 16 and v3 for Node >= 18 on Lambda. Without this check, the custom resources invocations will fail if the provider runtime is set to Node 16 or lower.

Copy link
Contributor

@GrahamCampbell GrahamCampbell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure we should actually fix this, and instead we could drop support for node 16 early.

@tonyliu-raken
Copy link

According to https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html, nodejs18.x is no longer supported.

@jackylamhk
Copy link
Contributor Author

AWS doesn't advertise this, for obvious reasons, but you can still create and update functions with EOL runtimes via the API (and therefore CloudFormation and Serverless). This check simply ensures backward compatibility without providing any extra support.
The current workaround is to set the runtime for each function individually, so provider.runtime remains unset.

@mnapoli
Copy link
Contributor

mnapoli commented Dec 4, 2025

@jackylamhk do you think this is the cause behind #128 and brefphp/bref#2034 ?

I'm wondering if these failures with custom resources might be related

@jackylamhk
Copy link
Contributor Author

@jackylamhk do you think this is the cause behind #128 and brefphp/bref#2034 ?

I'm wondering if these failures with custom resources might be related

It's possible, but I'd want to see the CloudFormation events and CloudWatch logs (if any; as you have asked) to be sure. And I'd also check what provider.runtime is set to.

@mnapoli
Copy link
Contributor

mnapoli commented Dec 5, 2025

I'm all for dropping support for Node 16, but see #130 and other issues linked, I believe this might be affecting several people. I'll merge this in the meantime to see if it helps.

@mnapoli mnapoli merged commit ce52589 into oss-serverless:main Dec 5, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants