aws / aws-sdk-js-v3

Modularized AWS SDK for JavaScript.
Apache License 2.0
2.96k stars 556 forks source link

Link to Lambda Runtimes Page does not show AWS SDK V3 version provided by Lambda #6159

Closed swhalen-rsc closed 3 weeks ago

swhalen-rsc commented 3 weeks ago

Describe the issue

This link included in the documentation, Lambda runtimes doc page, does not seem to indicate what node runtimes provide what SDK versions.

While this information can be found by testing a lambda and logging the AWS SDK V3 version, it would be nice to have an official source showing what versions are available.

Use case: I would like to use the same SDK version testing locally as my code will use in the Lambda, installing modules as a peer dependency with npm

Links

https://github.com/aws/aws-sdk-js-v3?tab=readme-ov-file#working-with-the-sdk-in-lambda

RanVaknin commented 3 weeks ago

Hi @swhalen-rsc ,

Thanks for reaching out. While I agree that this information is important and useful, the documentation around which SDK version provided in Lambda is owned by the Lambda service, and not the SDK team therefore the SDK docs would not contain which version is provided by lambda. The SDK is vendored as a standalone client and any number of providers can supply their own SDK version without the knowledge of the SDK team.

That being said, this information existed up until not too long ago. The Lambda service team has recently removed this mapping because it wasn't entirely accurate. When the Lambda team updates the Lambda provided SDK, it rolls out the new version update on a per-region basis to avoid pushing a broken version across the board. Because it's hard to project and update this list in real-time, the Lambda team has removed this documentation and instead provided a new doc page to programmatically check which SDK version is provided for a given lambda:

Example Node.js 18 and above

const { version } = require("@aws-sdk/client-s3/package.json");

exports.handler = async () => ({ version });

This returns a response in the following format:

{
  "version": "3.462.0"
}

Since this is not actionable by the SDK team. I'm going to close this. Thanks again,

Ran~

github-actions[bot] commented 1 week ago

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.