Soru

Zorluk: OrtaImplementing Auto Scaling and Fault Tolerance

A company hosts a critical web application on AWS using Amazon EC2 instances in an Auto Scaling Group (ASG) behind an Application Load Balancer (ALB). The instances are deployed across 33 Availability Zones and require outbound internet access to communicate with a third-party payment gateway. The company experiences two recurring issues during flash sale events: first, during the first few minutes of a traffic surge, users experience HTTP 503503 errors. Second, the ASG launches excess instances because new instances take 88 minutes to bootstrap, and the ASG initiates subsequent scale-out actions before the initial batch of instances completes bootstrapping. Currently, outbound internet traffic is routed via a single NAT gateway in one Availability Zone. Which TWO actions should a Solutions Architect recommend to resolve these scaling and reliability issues?

  1. Deploy a NAT gateway in each Availability Zone, update the route tables to route outbound traffic through the local NAT gateway, and contact AWS Support to pre-warm the Application Load Balancer before scheduled flash sale events.Cevap
  2. Transition the Auto Scaling group to use target tracking scaling policies, and configure the instance warmup time to be greater than the 88-minute instance bootstrapping duration.Cevap
  3. C
    Maintain the single NAT gateway to minimize running costs, and configure the Auto Scaling group to use step scaling policies with a scaling cooldown period of 120120 seconds.
  4. D
    Decrease the default cooldown period of the Auto Scaling group to 300300 seconds to accelerate scaling actions, and rely on the Application Load Balancer's automatic scaling to absorb the initial traffic spikes without pre-warming.
  5. E
    Configure simple scaling policies with a cooldown period that is shorter than the bootstrapping time to ensure the Auto Scaling group remains highly responsive during traffic surges.

Cevap

Deploy a NAT gateway in each Availability Zone, update route tables to route outbound traffic locally, request Application Load Balancer pre-warming prior to events, and transition the Auto Scaling group to target tracking scaling policies with an instance warmup time set to be greater than the 88-minute bootstrapping duration.
Deploying a NAT gateway per Availability Zone ensures that outbound connectivity is fault-tolerant across AZs. Pre-warming the Application Load Balancer ensures the load balancer has sufficient capacity to handle sudden flash sale traffic immediately without dropping connections. Configuring the target tracking scaling policy with an instance warmup period longer than the 88-minute bootstrapping time prevents the Auto Scaling group from launching redundant instances while the initial instances are still completing their startup configuration.

Adım Adım Çözüm

1
Address the immediate Application Load Balancer limitation for sudden traffic surges.
By pre-warming the Application Load Balancer, AWS provisionally scales the load balancer capacity to meet the expected flash sale traffic, eliminating the HTTP 503503 errors caused by scaling lag.
Sudden spikes in traffic exceed the normal scaling speed of the Application Load Balancer.
2
Address the Auto Scaling Group's over-provisioning behavior during bootstrapping.
By transitioning to target tracking scaling policies and configuring the instance warmup period to exceed the 88-minute (480480 seconds) bootstrapping time, the Auto Scaling group will wait for new instances to become operational and start contributing to metric reduction before executing further scaling actions.
This prevents duplicate scaling actions while the initial instances are booting.
3
Address the single point of failure in the outbound network path.
By deploying a NAT gateway in each of the three Availability Zones and directing each private subnet's route table to its local NAT gateway, the outbound connection is protected against a single Availability Zone outage.
This establishes fault tolerance and high availability for payment gateway communication.

Anahtar Kavram

Auto scaling warmup configuration, load balancer pre-warming, and multi-AZ NAT gateway redundancy are critical for fault tolerance and scaling efficiency under predictable burst loads.
Bu soruyu puanla