DVA-C02 · Question #247
A developer wants to reduce risk when deploying a new version of an existing AWS Lambda function. To test the Lambda function, the developer needs to split the traffic between the existing version and
The correct answer is B. Create a function alias. Configure the alias to split the traffic between the two versions of the. Lambda aliases support weighted traffic routing, allowing a developer to split traffic between two function versions by assigning percentage weights directly on the alias.
Question
A developer wants to reduce risk when deploying a new version of an existing AWS Lambda function. To test the Lambda function, the developer needs to split the traffic between the existing version and the new version of the Lambda function. Which solution will meet these requirements?
Options
- AConfigure a weighted routing policy in Amazon Route 53. Associate the versions of the Lambda
- BCreate a function alias. Configure the alias to split the traffic between the two versions of the
- CCreate an Application Load Balancer (ALB) that uses the Lambda function as a target. Configure
- DCreate the new version of the Lambda function as a Lambda layer on the existing version.
How the community answered
(41 responses)- A2% (1)
- B95% (39)
- C2% (1)
Why each option
Lambda aliases support weighted traffic routing, allowing a developer to split traffic between two function versions by assigning percentage weights directly on the alias.
Route 53 weighted routing operates at the DNS level and cannot target individual Lambda function versions.
A Lambda alias can be configured with a routing configuration that assigns a weight (0-100%) to two different function versions. This enables canary or blue/green deployments by sending a defined percentage of invocations to the new version while the remainder go to the stable version, all through a single alias ARN.
ALB target group weights distribute traffic among targets but cannot differentiate between Lambda function versions.
Lambda layers provide shared code and dependencies across functions; they do not enable traffic splitting between versions.
Concept tested: Lambda alias weighted traffic shifting between versions
Source: https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html#configuring-alias-routing
Community Discussion
No community discussion yet for this question.