AWS Elastic Load Balancing

Elastic Load balancing is a tool that automatically distributes incoming traffic across multiple targets, such as EC2 instances, containers, and etc.

Load balancer increases availability of virtual servers and make it convenient to add or remove compute resources without disrupting the current flow of requests to the application.

AWS ELB architect diagram

Types of Load Blancers

  1. Classic Load Balancer (CLB): often called ELB itself; ideal for application constructed on ‘EC2-classic’ network.
    - Advantage
    I. Support for EC2-Classic
    II. Support TCP and SSL listeners
  2. Network Load Balancer (NLB): ideal for TCP or UDP traffic as it handles millions of requests in seconds. (NIB uses a fixed IP address per AZ that it is optimized for uncertain and unreliable traffic patterns.)
    - Advantage
    I. Ability to handle millions of requests per second.
    II. Support for static IP addresses for the load balancer. (can also assign one Elastic IP address per subnet)
    III. Support Elastic Container Service, CloudWatch and etc…
  3. Application Load Balancer(ALB): ideal for HTTP and HTTPS and mostly used for micro-services and container based application programs. (used a lot for website development)
    - Advantage
    I. Support Path condition: configure rules for listeners and send requests based on the URL in the request.
    II. Support Host condition : enables you to route request to multiple domains using a single load balancer.
    III. Support for redirecting requests from one URL to another.
    IV. Support Lambda, authentication of identity, Elastic Container Serbice, and CloudWatch.