Networking · AWS SERVICE CHEATSHEET

Application Load Balancer (ALB)

Frontend traffic distributor providing SSL termination, HTTP routing rules, path-based load balancing, and health-check monitoring across compute fleets.

Open Interactive ALB Sandbox → Simulate in Architecture Studio

AWS Container Placement

SUBNET

Summary

Elastic Load Balancing Layer-7 load balancer routing HTTP/HTTPS traffic to targets based on content.

When to Use (SAA-C03)

Use for HTTP/HTTPS microservices, path-based routing (/api vs /web), and WebSockets; use NLB for raw TCP/UDP or static IPs.

Allowed Ingress Connections & Ports

Source ServiceProtocolPortArchitectural Rationale
WEBCLIENTHTTP, HTTPS80, 443Public web browsers and API consumers
CLOUDFRONTHTTPS443CloudFront CDN edge origins routing through custom headers
WAFINSPECT80, 443AWS WAF deep packet inspection barrier

Allowed Egress Targets & Ports

Target ServiceProtocolPortData Flow Rationale
TGHTTP, HTTPS80, 443, 8080, 3000Target Group forward action
EC2HTTP, HTTPS80, 8080, 443Direct compute node instance targets
ECSHTTPDynamic Container PortsECS container task definitions
LAMBDAHTTPN/AServerless Lambda function invocation targets

Key Configuration Parameters & AWS Best Practices

ParameterFormat / ExamplePurpose & Rationale
Load Balancer Scheme (albScheme) (Required)internet-facingDetermines whether the ALB resolves to public IP addresses or private VPC IPs. Why: AWS configures route tables and public DNS resolution differently for internet-facing vs internal ALBs.
Subnet Attachments (albSubnetIds) (Required)subnet-pub-1a, subnet-pub-1bSpecifies the Availability Zones and subnets where ALB elastic network interfaces are spawned. Why: AWS ALB requires at least 2 distinct Availability Zones for multi-AZ fault tolerance and routing.
Security Groups (securityGroupIds) (Required)sg-alb-public (Allows 0.0.0.0/0 on 80/443)Defines firewall filtering rules for ALB public listeners. Why: Without a security group rule allowing inbound port 80/443, all client requests are blocked at the ingress boundary.
WAF Web ACL AssociationAWS WAF Web ACL ARNAttaches Layer 7 Web Application Firewall rules to block OWASP threats and DDoS attacks. Why: Protects backend servers from bot abuse, SQL injections, and credential stuffing attacks.
Idle Timeout (Seconds)60The maximum duration the ALB keeps an idle TCP connection open before terminating it. Why: Long-running API calls or file uploads may require bumping this to 300s.
Drop Invalid Header FieldstrueBlocks HTTP requests containing invalid HTTP header syntax. Why: Hardens security posture against HTTP smuggling exploits.

Practice Labs Using Application Load Balancer

CLF-04

Single Point of Failure (Single-AZ)

Add a secondary subnet in us-east-1b and front instances with an Application Load Balancer across both Availab…

SAA-04

E-Commerce Flash Sale: ALB 502 Bad Gateway Port Mismatch

Reconcile Target Group port to match the backend EC2 application port (80) to restore healthy status.…

SAA-06

Streaming Media Platform: ASG Max Capacity Bottleneck

Increase ASG maximum capacity to at least 6 to absorb live traffic surges.…

SAA-08

Multi-Tier Highly Available Web Architecture: Dual-AZ ALB, ASG Fleet & Multi-AZ RDS

Re-architect for multi-AZ high availability: map the public ALB across dual AZs (us-east-1a and us-east-1b), d…

SAA-12

Publish Private Compute: Secure Route 53 CNAME & Dual-AZ ALB Reverse Proxy

Expose the private EC2 compute service via an Internet-Facing ALB spanning two public AZs, configure Target Gr…

SAA-GLOBAL-ACCELERATOR

Global Low-Latency Ingress: Global Accelerator Anycast Failover

Deploy AWS Global Accelerator with static Anycast IPs directing traffic to regional load balancers with instan…

Frequently Asked Questions

Where does Application Load Balancer live inside an AWS VPC architecture?

Valid container placement: SUBNET. Frontend traffic distributor providing SSL termination, HTTP routing rules, path-based load balancing, and health-check monitoring across compute fleets.

When should I use Application Load Balancer on the AWS SAA-C03 exam?

Use for HTTP/HTTPS microservices, path-based routing (/api vs /web), and WebSockets; use NLB for raw TCP/UDP or static IPs.

Can I simulate Application Load Balancer packet routing without an AWS account?

Yes. CloudTracer simulates Application Load Balancer along with 53 AWS services directly in your browser and exports production Terraform HCL.

More Networking Cheatsheets

Network Load Balancer → Virtual Private Cloud → VPC Subnet → VPC Route Table → Internet Gateway → NAT Gateway →