A developer has fixed a bug in a production AWS Lambda function and validated the change in a test environment. The developer wants to roll the update out gradually in production so that initially only 10% of users see the new code. What is the appropriate approach?
Choose an answer
Tap an option to check your answer.
Correct answer: Update the Lambda code and publish a new version. Create a Lambda alias and configure weighted traffic on the alias to send 90% to the production version and 10% to the new version..
Why this is the answer
The correct approach is to update the Lambda code, publish a new version, and then create a Lambda alias configured for weighted traffic. Lambda aliases allow you to point to a specific function version or split traffic between two versions based on a defined weight. This enables gradual rollouts (canary deployments) where a small percentage of traffic is routed to the new version, allowing for monitoring before a full rollout. Incorrect options: Creating a Lambda trigger to split traffic is not how triggers work; triggers invoke functions based on events, not traffic weighting. Creating a separate Lambda function with the updated code and using an alias to split traffic between two functions is not the standard or most efficient way to handle versioning and gradual rollouts within Lambda. Aliases are designed to manage versions of the same function. A Lambda proxy integration is typically used with API Gateway to pass requests directly to a Lambda function, not for managing weighted traffic between different Lambda versions.
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