DEV Community

Le Huy Ho
Le Huy Ho

Posted on

Learning AWS - DVA - Day 6: Application Load Balancer

Overview

  • Application Load Balancers is Layer 7 in OSI model (HTTP)

  • Load balancing to multiple HTTP applications across machines (target groups)

  • Load balancing to multiple applications on the same machine (ex: containers)

  • Support for HTTP/2 and Websocket

  • Support redirects (from HTTP to HTTPS for example)

  • Routing based on path in URL (example.com/users & example.com/posts)

  • Routing based on hostname in URl (one.example.com * other.exmaple.com)

  • Routing based on Query String, Headers (example.com/users?id=123&order=false)


Use cases

ALB are great fit for micro service & container-based application:

  • Microservice Architecture: route traffic to different services base on URL paths

  • Containerized Application: Works well with Amazon ECS and EKS for managing traffic to containers

  • Multi-Region Applications: Distribute traffic across multiple AWS regions.


Good to know

  • The application servers don't see the IP of the client directly. The true IP of the client is inserted in the header X-Forwarded-For. We can also get Port (X-Forwarded-Port) and protocol (X-Forwarded-Proto).

Top comments (0)