nerdexam
Amazon

DVA-C02 · Question #396

A developer wants the ability to roll back to a previous version of an AWS Lambda function in the event of errors caused by a new deployment. How can the developer achieve this with MINIMAL impact on

The correct answer is A. Change the application to use an alias that points to the current version. Deploy the new version. Using a Lambda alias as an indirection layer is the correct approach because the application always invokes the alias ARN (not a version ARN directly), so a rollback is as simple as updating the alias to point back to the previous version - no application code changes, no redeplo

Submitted by diego_uy· Mar 5, 2026Deployment

Question

A developer wants the ability to roll back to a previous version of an AWS Lambda function in the event of errors caused by a new deployment. How can the developer achieve this with MINIMAL impact on users?

Options

  • AChange the application to use an alias that points to the current version. Deploy the new version
  • BChange the application to use an alias that points to the current version. Deploy the new version
  • CDo not make any changes to the application. Deploy the new version of the code. If too many
  • DCreate three aliases: new, existing, and router. Point the existing alias to the current version.

How the community answered

(15 responses)
  • A
    80% (12)
  • C
    13% (2)
  • D
    7% (1)

Explanation

Using a Lambda alias as an indirection layer is the correct approach because the application always invokes the alias ARN (not a version ARN directly), so a rollback is as simple as updating the alias to point back to the previous version - no application code changes, no redeployment, near-instant recovery for users.

Why the distractors are wrong:

  • B appears identical to A as shown (likely a formatting artifact in this question - both describe the alias pattern correctly).
  • C is wrong because deploying without an alias means the application is coupled to $LATEST or a hardcoded version ARN. Rolling back requires a full redeployment of old code rather than a quick pointer swap, increasing user impact time.
  • D is wrong because a three-alias "router" setup is not a standard Lambda pattern and introduces unnecessary complexity. Lambda does support weighted alias routing natively (shifting a percentage of traffic to a new version), but you don't need three separate aliases to accomplish this.

Memory tip: Think of a Lambda alias like a DNS record - it's a named pointer you control independently of the underlying version. Just as you can update a DNS entry to redirect traffic, you can update an alias to instantly redirect invocations to any published version. "Alias = rollback handle."

Topics

#AWS Lambda#Lambda Aliases#Function Versioning#Rollback

Community Discussion

No community discussion yet for this question.

Full DVA-C02 Practice