2 LB algorithms Round Robin & Least Outstanding Requests

Scenario

Web app behind an Application Load Balancer (ALB).
Some EC2 instances are overloaded (too many outstanding requests).

CloudWatch shows higher:

Request count
Response time

Requirement: Do not forward new requests to overload…


This content originally appeared on DEV Community and was authored by Wakeup Flower

Scenario

  • Web app behind an Application Load Balancer (ALB).
  • Some EC2 instances are overloaded (too many outstanding requests).
  • CloudWatch shows higher:

    • Request count
    • Response time
  • Requirement: Do not forward new requests to overloaded instances.

Key background:

ALBs support two main load-balancing algorithms:

  1. Round Robin (default) – evenly distributes requests, without considering instance load.
  2. Least Outstanding Requests (LOR) – sends new requests to the target with the fewest active (in-flight) requests, providing adaptive load distribution.

When some instances get slower (more outstanding requests), LOR automatically directs new traffic to the less busy instances.

Metric relevance

  • RequestCountPerTarget → shows how many requests each target handled.
  • ActiveConnectionCount → number of open connections (relevant for HTTP keep-alives or WebSockets).
  • TargetResponseTime → average response time, good for observation but not for routing logic directly.

The ALB’s Least Outstanding Requests algorithm inherently considers the number of active requests per target—it doesn’t need CloudWatch metrics directly for routing. But among the given choices, the ones referencing ActiveConnectionCount and RequestCountPerTarget correctly describe load indicators.

Option analysis

Option Algorithm Metrics Notes
A Round robin RequestCountPerTarget + ActiveConnectionCount ❌ Round robin ignores load; not suitable.
B Least outstanding requests RequestCountPerTarget + ActiveConnectionCount ✅ Correct — uses LOR algorithm, which addresses overloaded instances.
C Round robin RequestCount + TargetResponseTime ❌ Round robin still ignores load.
D Least outstanding requests RequestCount + TargetResponseTime ❌ “TargetResponseTime” not used by the ALB algorithm; LOR uses outstanding request count.

Why:

  • The Least Outstanding Requests algorithm automatically avoids sending new requests to busy instances.
  • Metrics like RequestCountPerTarget and ActiveConnectionCount confirm the balancing effectiveness, but the ALB handles this logic internally.


This content originally appeared on DEV Community and was authored by Wakeup Flower


Print Share Comment Cite Upload Translate Updates
APA

Wakeup Flower | Sciencx (2025-10-13T12:37:14+00:00) 2 LB algorithms Round Robin & Least Outstanding Requests. Retrieved from https://www.scien.cx/2025/10/13/2-lb-algorithms-round-robin-least-outstanding-requests/

MLA
" » 2 LB algorithms Round Robin & Least Outstanding Requests." Wakeup Flower | Sciencx - Monday October 13, 2025, https://www.scien.cx/2025/10/13/2-lb-algorithms-round-robin-least-outstanding-requests/
HARVARD
Wakeup Flower | Sciencx Monday October 13, 2025 » 2 LB algorithms Round Robin & Least Outstanding Requests., viewed ,<https://www.scien.cx/2025/10/13/2-lb-algorithms-round-robin-least-outstanding-requests/>
VANCOUVER
Wakeup Flower | Sciencx - » 2 LB algorithms Round Robin & Least Outstanding Requests. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2025/10/13/2-lb-algorithms-round-robin-least-outstanding-requests/
CHICAGO
" » 2 LB algorithms Round Robin & Least Outstanding Requests." Wakeup Flower | Sciencx - Accessed . https://www.scien.cx/2025/10/13/2-lb-algorithms-round-robin-least-outstanding-requests/
IEEE
" » 2 LB algorithms Round Robin & Least Outstanding Requests." Wakeup Flower | Sciencx [Online]. Available: https://www.scien.cx/2025/10/13/2-lb-algorithms-round-robin-least-outstanding-requests/. [Accessed: ]
rf:citation
» 2 LB algorithms Round Robin & Least Outstanding Requests | Wakeup Flower | Sciencx | https://www.scien.cx/2025/10/13/2-lb-algorithms-round-robin-least-outstanding-requests/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.