Soru

Zorluk: ZorImplementing Auto Scaling and Fault Tolerance

A digital ticketing company hosts its high-demand event registration application on Amazon EC2 instances in an Auto Scaling group (ASG) behind an Application Load Balancer (ALB). The instances run in private subnets across 33 Availability Zones. The application requires outbound internet access to interact with external payment processors. Outbound traffic is currently routed through a single NAT Gateway in the first Availability Zone to minimize cost.

During major ticket release events, traffic surges from a baseline of 2,0002,000 requests per minute to over 100,000100,000 requests per minute in less than 22 minutes. During these spikes, users encounter frequent 502 Bad Gateway502\text{ Bad Gateway} and 504 Gateway Timeout504\text{ Gateway Timeout} errors. System logs show the ALB is dropping connections because backend EC2 instances are overwhelmed, and new instances take 55 minutes to bootstrap and become healthy. Additionally, a recent localized outage in the first Availability Zone disrupted payment processing for all healthy instances in the remaining zones.

Which combination of actions will address the scaling delays and the outbound network single point of failure while minimizing compute expenses during idle periods?

  1. A
    Maintain the single NAT Gateway in the first Availability Zone to control costs and enable load balancer cross-zone routing. Configure an Auto Scaling group warm pool with instances in the Stopped state, and request that AWS Support pre-warm the Application Load Balancer before scheduled events.
  2. B
    Provision a dedicated NAT Gateway in each Availability Zone and update the private subnet route tables. Configure an Auto Scaling group warm pool with instances in the Running state, and implement a target tracking policy based on the load balancer request count per target to scale dynamically.
  3. Provision a dedicated NAT Gateway in each Availability Zone and update the private subnet route tables. Configure an Auto Scaling group warm pool with instances in the Stopped state, and request that AWS Support pre-warm the Application Load Balancer before scheduled events.Cevap
  4. D
    Provision a dedicated NAT Gateway in each Availability Zone and update the private subnet route tables. Configure the Auto Scaling group cooldown and warmup periods to 6060 seconds to force rapid instance creation, and increase the Application Load Balancer idle timeout value.

Cevap

Provision a dedicated NAT Gateway in each Availability Zone and update the private subnet route tables. Configure an Auto Scaling group warm pool with instances in the Stopped state, and request that AWS Support pre-warm the Application Load Balancer before scheduled events.
The correct architecture combines three key improvements to solve the issues. First, provisioning a dedicated NAT Gateway per Availability Zone and updating private subnet route tables ensures that outbound traffic routes locally, eliminating the single point of failure and ensuring payment processing resilience during a single zone outage. Second, configuring an Auto Scaling group warm pool with instances in the Stopped state keeps pre-initialized instances ready to scale out rapidly, bypassing the 55-minute bootstrap latency while avoiding active compute charges when idle. Third, pre-warming the Application Load Balancer by contacting AWS Support ensures the load balancer has sufficient capacity to handle the 50×50\times traffic surge without dropping connections.

Adım Adım Çözüm

1
Address the outbound network single point of failure.
Deploy a dedicated NAT Gateway in each Availability Zone and associate them with the respective local subnet route tables.
This ensures that a localized AZ outage does not impact outbound payment gateway communication from the healthy AZs.
2
Resolve the compute scaling latency while controlling costs.
Enable an Auto Scaling group warm pool with instances in the Stopped state.
Instances are pre-bootstrapped and ready to start rapidly, bypassing the 55-minute initialization delay, while stopped instances do not incur EC2 compute charges.
3
Prevent connection drops at the entry point during flash traffic spikes.
Submit a request to AWS Support to pre-warm the Application Load Balancer prior to scheduled events.
This ensures the load balancer is pre-provisioned with enough capacity to handle the immediate 50×50\times increase in requests.

Anahtar Kavram

Implementing Auto Scaling and Fault Tolerance
Bu soruyu puanla