Updated on 2024-08-01 GMT+08:00

Listener Overview

A listener checks requests from clients and routes requests to backend servers using the protocol, port, and load balancing algorithm you select. You need to add at least one listener after you have created a shared load balancer.

Supported Protocols

ELB provides load balancing at both Layer 4 and Layer 7. You can select TCP or UDP for load balancing at Layer 4 and HTTP or HTTPS for load balancing at Layer 7.

Table 1 Protocols supported by ELB

Protocol

Description

Scenario

Layer 4

TCP

  • Source IP address–based sticky sessions
  • Fast data transfer
  • Scenarios that require high reliability and data accuracy, such as file transfer, email, and remote login
  • Web applications that receive a large number of concurrent requests and require high performance

Layer 4

UDP

  • Relatively low reliability
  • Fast data transfer

Scenarios that require quick response, such as video chat, gaming, and real-time financial quotations

Layer 7

HTTP

  • Cookie-based sticky sessions
  • X-Forward-For request header

Web applications where data content needs to be identified, such as mobile games

Layer 7

HTTPS

  • An extension of HTTP for encrypted data transmission that can prevent unauthorized access
  • Encryption and decryption performed on load balancers
  • Multiple versions of encryption protocols and cipher suites

Web applications that require encrypted transmission

Frontend Protocols and Ports

Frontend protocols and ports are used by load balancers to receive requests from clients. Load balancers use TCP or UDP at Layer 4, and HTTP or HTTPS at Layer 7. Select a protocol and a port that best suit your requirements.

The frontend protocols and ports cannot be changed once a listener is added. If you want to use a different protocol and port, add another listener.

Table 2 Frontend protocols and ports

Frontend Protocol

TCP, UDP, HTTP, and HTTPS

Frontend Port

Listeners using different protocols of a load balancer cannot use the same port. However, UDP listeners can use the same port as listeners that use other protocols. For example, if there is a UDP listener that uses port 88, you can add a TCP listener that also uses port 88. The port number ranges from 1 to 65535.

The following are some commonly-used protocols and port numbers:

TCP/80

HTTPS/443

Backend Protocols and Ports

Backend protocols and ports are used by backend servers to receive requests from load balancers. If Windows servers have Internet Information Services (IIS) installed, the default backend protocol and port are HTTP and 80.

Table 3 Backend protocols and ports

Backend Protocol

TCP, UDP, and HTTP

Backend Port

Backend servers of a load balancer can use the same ports. The port number ranges from 1 to 65535.

The following are some commonly-used protocols and port numbers:

TCP/80

HTTP/443