- v2- new generation. 2017, HTTP, HTTPS
- Application Layer (Layer7,HTTP) Load Balancer
- Can handle SSL termination, TLS encryption and decryption can be done by the ALB
- Http, HTTPS, Websocket, can support TCP too but not primary choice for TCP
- Allows redirects ( http → Https)
- ELB has a fixed hostname (xxx.region.elb.amazon.aws.com)
- Application servers in the target group do not see the client IP directly
- The true IP of the client is inserted in the header X-forwarded-for.
- We can also get the X-forwarded-Port and protocol (X-Forwarded-Proto → Http, or Https)
- Has a port mapping feature to redirect to a dynamic port in ECS
- ALB provides a static DNS name but does not provide a static IP. Only Network Load Balancer provides both static DNS name and static IP. Underlying IP can change in the case of an ALB
Target Groups
- EC2 instances (managed by auto scaling group)
- Lambda functions
- ECS tasks (managed by ECS itself)
- front to IP address - must be private addresses
- ALB can route to multiple target groups