AWS Certified Developer Associate DVA-C02 Practice Question
A developer is tasked with maintaining the consistent deployment of a serverless function across multiple environments. This function requires a specific version of an external library. What approach should the developer take to manage the dependencies of the serverless function efficiently?
Manage the library version through a configuration management service.
Utilize layers to package the external library, managing its version independently.
Embed the dependencies directly into the function's deployment package.
Incorporate the library code within the function's script.
The correct approach is to utilize layers, a feature provided by the serverless function service, which allows dependencies to be packaged separately from the function code. This method promotes consistent deployment across different environments and makes it easier to update or modify the shared components without redeploying the entire function codebase. Inserting the dependencies directly into the function's deployment package would not provide the separate management and versioning that layers offer. Incorporating the library code within the function script lacks modularity and complicates updates. Using a configuration management service, which is typically meant for runtime configuration and not for binary dependencies, is not the right tool for managing external library versions.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
What are AWS Lambda layers?
Open an interactive chat with Bash
How do I create and use a layer in AWS Lambda?
Open an interactive chat with Bash
What are the benefits of using layers over embedding dependencies?
Open an interactive chat with Bash
AWS Certified Developer Associate DVA-C02
Deployment
Your Score:
Report Issue
Bash, the Crucial Exams Chat Bot
AI Bot
Loading...
Loading...
Loading...
IT & Cybersecurity Package Join Premium for Full Access