Multiple Lambda functions share the same custom libraries. The developer wants a centralized, versioned, and easy way to update these libraries with the least development effort. Which option meets this need?
Choose an answer
Tap an option to check your answer.
Correct answer: Create a Lambda layer that packages all the custom libraries..
Why this is the answer
A Lambda layer is the most efficient solution for sharing custom libraries across multiple Lambda functions. It allows you to package dependencies separately from your function code, promoting code reuse and reducing deployment package sizes. When a library needs updating, you only update the layer, and all associated functions automatically use the new version, minimizing development effort. AWS CodeArtifact is for managing software packages within an organization, not directly for sharing runtime dependencies with Lambda functions. Building a custom container image would work but is more complex and adds overhead compared to a Lambda layer for just sharing libraries. An Amazon EFS file system could store libraries, but mounting it to every function adds latency and operational complexity, and it's not designed for versioning shared code dependencies in the same streamlined way as layers.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed