Skip to main content

Classic Load Balancer vs. Application Load Balancer in AWS

Cox employee working on laptop outdoors (2)

Cox Automotive’s technology teams are driving a better future through innovation. Here’s a sneak peek into the digital magic that drives two of the industry’s most well-known car-shopping websites: Kelley Blue Book and Autotrader.

The high traffic consumer-facing sites, KBB.com and Autotrader.com, run on Amazon Web Services (AWS).

To give the best user experience for our visitors, our engineering teams strive for high availability and responsiveness of both websites. To prevent server overload, we distribute traffic using a load balancer. Initially, our apps were setup to use Classic Load Balancer (CLB)After reviewing some of the many advantages of an Application Load Balancer (ALB), including Layer 7 of Open Systems Interconnection (OSI) Model, health monitoring, security features, and setting target groups, we chose to switch our apps to use Application Load Balancer. Below is the comparison of AWS Classic vs Application load balancer. 

What is load balancing?

Load balancing distributes incoming application traffic across multiple available servers. This helps to improve application responsiveness and prevents server overload. A load balancer checks the health of the servers and sends traffic to the servers that can handle the requests to ensure scalability and availability of services.  

About the Classic Load Balancer

Classic Load Balancer provides basic load balancing across multiple Amazon Elastic Computing (EC2) instances and operates at both the request level and connection level. Classic Load Balancer is recommended only for EC2 Classic instances. Layer 4 or Layer 7 Load Balancing of OSI, SSL Offloading and IPv6 Support are features of Classic Load Balancer. It does not support host and path-based routing.  

About the Application Load Balancer

Application Load Balancer allows a developer to configure and route incoming end-user traffic to applications based in the AWS public cloud. It operates at the seventh layer of the (OSI) model. At Layer 7, the Elastic Load Balancing (ELB) can inspect application-level content, not just network packets. This allows the load balancer to route traffic based on more complex rules such as the path of the request to targets.  

What are the benefits of migrating to the Application Load Balancer?

  • ALB operates at layer 7 and supports a variety of communication protocols – HTTP, HTTPS, HTTP/2, as well as WebSockets. 
  • Request forwarding based on the URL path can be configured with the help of ALB rules. 
  • Single load balancer can handle routing for multiple domains. 
  • You can route based on fields in the request, such as HTTP header conditions and methods, IP addresses, etc. 
  • Lambda functions can be registered as targets.  
  • Priorities can be set to decide the order to evaluate the rules.  
  • User authentication can be done for your applications before routing requests. 
  • Dynamic port mapping is supported using the EC2 Container Service.  
  • It simplifies and improves the security of your application, by ensuring that the latest SSL/TLS ciphers and protocols are always used. 
  • Though both CLB and ALB support health checks, ALB allows detailed error codes to be configured.  
  • Attaching a target group to an Auto Scaling group enables you to scale each service dynamically based on demand. 
  • Request tracing can be added to the HTTP requests from clients to targets.  
  • Web Application Firewall can be used to monitor web requests and protect the application from malicious requests.  
  • ALB supports slow start mode which helps to add new targets to ramp-up without overloading requests.  

Comparing the benefits of AWS Application load balancer vs Classic load balancer, ALB is preferred if you need more complex load balancing and CLB can be used when using EC2 classic instances only.

To hear more about what else our engineering teams have been up to, stay tuned for future blog posts!

 

We're hiring! Explore technology careers at Cox here.

Related Articles

View All Stories
Cox employee working on laptop in front of window
Business Innovation

A Study Guide for the AWS Security Specialty Exam

Digital Divide 8202024 (4)
Business Innovation

How Cox is Bridging the Digital Divide