Layer-4 listener overview
- TCP protocol
A connection-oriented protocol. A reliable connection must be established with the peer side before data can be sent and received. Applicable to scenarios with high requirements on reliability and data accuracy, but with tolerance for low speed, such as file transmission, sending or receiving emails, remote logon, and web applications without special requirements.
- UDP protocol
A non-connection-oriented protocol. Before sending data, UDP directly performs data packet transmission instead of making three handshakes with the other party. It does not provide error recovery or data retransmission. Applicable to scenarios with preference for real-time content over reliability, such as video chats and pushes of real-time financial quotations.
Note the following limitations when configuring the UDP protocol listeners:
- The maximum number of connections per listener: 100,000.
- Currently, does not support fragmented packages.
- Obtaining the real IP address for the UDP protocol in the classic network is not supported.
- In the following two scenarios, the UDP protocol listener configuration takes five minutes to take effect:
- Remove the backend ECS instances.
- Set the weight of a backend ECS instance to zero.
Layer-4 listener configurations
Configuration | Description | |||
---|---|---|---|---|
Front-end Protocol [Port] | The front-end protocol and port used to receive connection requests and forward the requests to backend servers. When configuring a layer-4 listener, select TCP or UDP. The port number is 1-65535.
|
|||
Backend Protocol [Port] | The open port on the backend ECS instance for receiving requests. The backend protocol is the same as the front-end protocol, and the port number is 1-65535.
|
|||
Peak Bandwidth | For Load Balancing instances with bandwidth charges, you can set different bandwidth peaks for different listeners to limit the traffic that you listen. The sum of the peak bandwidth of all listeners under an instance cannot exceed the bandwidth of that instance. When the listen bandwidth is not restricted, the total bandwidth of each listening shared instance. For more details, refer to Share bandwidht. |
|||
Scheduling Algorithm | Server Load Balancer supports three scheduling algorithms: round robin, weighted round robin (WRR), and weighted least connections (WLC).
|
|||
Use Server Group | If used, you can manage backend servers in the listener dimension. A server group contains multiple backend servers with different ports.
|
|||
Sever Group Type | After enabling the server group function, select the type of server group to be used:
|
|||
Automatically Activate Listener after Creation | Choose whether to activate the listener once the listener is created. The default setting is Activated. |
Advanced settings | Description | |||
---|---|---|---|---|
Obtain Real IP | For layer-4 listeners, you can directly get the real IP of the client.
|
|||
Session persistence | Choose whether to enable session persistence. If enabled, all requests from a client are sent to the same backend server for the duration of the session. For TCP listeners, session persistence is based on IP addresses. Requests from the same IP address are forwarded to the same backend server.
|
|||
Enable Access Control | Specify whether to enable the access control function. | |||
Access Control Method | Select an access control method after enabling the access control function:
|
|||
Select an Access Control List | Select an access control list as the whitelist or the blacklist. For more information, see Configure an access control list. |