nerdexam
Amazon

SOA-C03 · Question #22

A company is migrating a legacy application to AWS. The application runs on EC2 instances across multiple Availability Zones behind an Application Load Balancer (ALB). The target group routing…

The correct answer is A. Set the routing algorithm of the target group to least outstanding requests. When sticky sessions are required, the target group routing algorithm must be compatible with session affinity. Weighted random routing with sticky sessions causes conflicts that lead to application errors.

Submitted by rania.sa· Mar 5, 2026Networking

Question

A company is migrating a legacy application to AWS. The application runs on EC2 instances across multiple Availability Zones behind an Application Load Balancer (ALB). The target group routing algorithm is set to weighted random, and the application requires session affinity (sticky sessions). After deployment, users report random application errors that were not present before migration, even though target health checks are passing. Which solution will meet this requirement?

Options

  • ASet the routing algorithm of the target group to least outstanding requests.
  • BTurn on anomaly mitigation for the target group.
  • CTurn off the cross-zone load balancing attribute of the target group.
  • DIncrease the deregistration delay attribute of the target group.

How the community answered

(57 responses)
  • A
    74% (42)
  • B
    4% (2)
  • C
    7% (4)
  • D
    16% (9)

Why each option

When sticky sessions are required, the target group routing algorithm must be compatible with session affinity. Weighted random routing with sticky sessions causes conflicts that lead to application errors.

ASet the routing algorithm of the target group to least outstanding requests.Correct

The Least Outstanding Requests (LOR) algorithm is fully compatible with sticky sessions on an ALB target group. When sticky sessions are enabled, LOR ensures that new requests from a user without an existing session cookie are routed to the instance with the fewest outstanding requests, while existing sessions continue to route to the same target - eliminating the routing conflicts that cause application errors under weighted random with stickiness enabled.

BTurn on anomaly mitigation for the target group.

Anomaly mitigation helps identify and stop routing to misbehaving targets, but it does not resolve the algorithmic incompatibility between weighted random routing and sticky sessions that is causing the application errors.

CTurn off the cross-zone load balancing attribute of the target group.

Turning off cross-zone load balancing restricts traffic to targets within the same Availability Zone as the load balancer node, but does not address the root cause of session affinity conflicts introduced by the weighted random routing algorithm.

DIncrease the deregistration delay attribute of the target group.

Increasing the deregistration delay extends the time a deregistering target continues to receive in-flight requests, which is relevant during scale-in or deployments, but has no effect on the routing algorithm incompatibility with sticky sessions causing current user errors.

Concept tested: ALB target group routing algorithm compatibility with sticky sessions

Source: https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-target-groups.html#modify-routing-algorithm

Topics

#ALB routing algorithm#sticky sessions#least outstanding requests#weighted random

Community Discussion

No community discussion yet for this question.

Full SOA-C03 Practice