Configure a custom routing listener for a standard Global Accelerator (GA) instance to deterministically route traffic to all IP addresses in a specified subnet, or to a specified IP address and destination port, based on the mapping between listener ports and destination ports in the target endpoint group.
Background information
After you configure a custom routing listener for a GA instance, GA generates a port mapping table from the listener port range, endpoint group port ranges, and endpoint IP addresses (vSwitches). The listener forwards requests to specific vSwitch IP addresses and ports based on this mapping table.
Custom routing listeners forward traffic to specified backend servers. Use cases: multiplayer online games, video conferencing, and virtual classrooms. For information about how custom routing listeners work and how to use custom routing listeners, see How custom routing listeners work.
To compare routing types and their port range limits, see Listeners.
Prerequisites
-
You have been approved to use custom routing listeners. The custom routing listener feature is in private preview. To use this feature, contact your account manager to request access.
-
You must have created a standard GA instance.
-
For subscription-based GA instances, you must have purchased and associated a basic bandwidth plan.
Add a listener
-
Configure the listener and protocol.
-
Log in to the Global Accelerator console.
-
On the Instances page, find the GA instance that you want to manage and click Configure Listener in the Actions column.
-
On the Listeners tab, click Add Listener.
NoteSkip this step if you are adding the first listener or if the Global Accelerator instance has no listeners.
-
On the Configure Listener & Protocol page, set the following parameters and click Next.
Parameter
Description
Listener Name
Enter a name for the listener.
Routing Type
Select a routing type. In this topic, select Custom Routing.
-
Standard: Routes traffic to the nearest or healthiest endpoint group based on latency.
-
Custom: Generates a port mapping table based on the listener port range, destination endpoint group port range, and IP addresses of endpoints (vSwitches). Deterministically routes traffic to specific IP addresses and ports on a vSwitch.Add and manage listeners of the Custom routing type.
NoteCustom routing listeners are in invitational preview. To use custom routing listeners, submit an application to your account manager. After your application is approved, you can use custom routing listeners.
Port
Specify the listener port that is used to receive and forward requests to endpoints. The port number must be in the range of 1 to 65499.
Use a comma (,) to separate multiple ports, for example, 80,90,8080.
For multiple consecutive ports, use a hyphen (-) to specify a port range, for example, 80-85.
Note-
The listener ports of different custom routing listeners on the same Global Accelerator instance cannot overlap.
-
Ports 25, 250, 4789, and 4790 are reserved by the system. GA automatically ignores these ports when it generates a mapping table.
-
Port 6081 cannot be configured for pay-as-you-go Global Accelerator instances.
-
The listener port range determines the number of possible combinations of ports in the associated endpoint group and IP addresses in all vSwitch endpoints. The formula is:
Number of listener ports ≥ Total number of ports in the endpoint group × Total number of IP addresses in all vSwitch endpoints. We recommend that you configure a large port range for the listener.
-
-
-
Configure endpoint groups and endpoints.
An endpoint group is associated with a specific region and defines the mapping between the listener's port range and the backend service's port range and protocol. Endpoints specify the destination subnets and their traffic policies.
For more information about endpoint groups and endpoints, see Endpoint groups and endpoints.
Configure the endpoint group.
On the Configure Endpoint Group page, configure the endpoint group based on the following information.
Parameter
Description
Endpoint Group Name
Enter a name for the endpoint group.
Region
Select the Alibaba Cloud region where the endpoint group is deployed.
Port Mapping Range and Protocol
Select an entry mode to define the port and protocol mappings from the listener to the backend services in the endpoint group.
List Mode: Enter the Port Range and Protocol. For Protocol, you can select TCP, UDP, or both.
Click Add to enter multiple mappings.
Use this mode to add up to 20 mappings at a time.
Batch Mode: Enter the port ranges and protocols according to the formatting instructions, or download the template, fill it out, and upload the file.
Use this mode to add up to 100 mappings at a time.
NoteThe total number of ports in the endpoint group multiplied by the total number of IP addresses in all vSwitch endpoints must be less than or equal to the total number of ports specified for the listener. The formula is:
(Total number of ports in the endpoint group) × (Total number of IP addresses in all vSwitch endpoints) ≤ (Number of listener ports).Configure endpoints.
In the Endpoint section, click Add Endpoint. In the Add Endpoint dialog box, configure the endpoint based on the following information, and then click OK.
Parameter
Description
Backend Service Type
Only vSwitch is supported.
Backend Service
Select the vSwitch to which you want to forward traffic.
Subnet Traffic
Select a subnet traffic access policy.
Allow All Traffic: All inbound traffic is forwarded to the specified backend service through Global Accelerator.
Deny All Traffic (Default): No inbound traffic is forwarded to the specified backend service through Global Accelerator.
Allow traffic for specific vSwitch IP addresses and ports: Specify the Access Policy that can receive traffic. Traffic destinations are the IP addresses and ports of ECS instances.
Optional: Click + Add Endpoint Group to configure another endpoint group.
NoteIf you need to create more than two endpoint groups, request a quota increase on the quota management page for gaplus_quota_epgs_per_listener.
-
In the Cross-border Acceleration Settings section, read the Compliance Commitments Regarding Cross-border Data Transfers and select Agree to the Preceding Compliance Agreement.
This step is required only if cross-border acceleration is not enabled for your GA instance and your service configuration involves cross-border acceleration between the Chinese mainland and other regions.
Click Next.
-
Review the configuration.
On the Configuration Review wizard page, confirm the listener and endpoint configurations, and then click Submit.
If you need to modify the configurations, you can click Edit in the corresponding section to return to the previous page.
NoteA new listener takes about 3 minutes to become active, and configuration changes take about 1 minute to apply.
Additional operations
|
Actions |
Description |
|
Edit a listener |
Modify the listener name and port.
|
|
Delete a listener |
Delete a listener. Deleting a listener also deletes its associated endpoint groups.
|
Related documentation
-
CreateListener: Creates a listener.
-
UpdateListener: Updates a listener.
-
DeleteListener: Deletes a listener.