SOFAStack provides public and private Server Load Balancer services. You can configure a public or private load balancer based on your business scenario. The system then assigns a public or private service endpoint based on your selection.
Procedure
When you set the access configuration for an application service, click the Create Server Load Balancer link to open the Create Server Load Balancer page.
Enter the following information and click Create.
Number of instances: Enter the number of instances.
Instance name: The name must be 1 to 50 characters long.
Instance type: Select Private or Public.
Internet bandwidth billing method: Select Pay-by-traffic or Pay-by-bandwidth. This option is available only for the Public instance type.
Network type: virtual private cloud (VPC). This option is available only for the Private instance type.
vSwitch: Select an existing vSwitch or create a new one. A vSwitch is required only for a private Server Load Balancer.
Listener information: To add a listener, enter the following information.
Frontend protocol and port: The protocol and port that the Server Load Balancer uses to receive requests and forward them to backend servers. Supported protocols include HTTP, HTTPS, and TCP. The frontend port must be unique within a Server Load Balancer instance.
Backend port: The port on the backend ECS instance that receives requests. This port can be reused within the same Server Load Balancer instance.
Forwarding rule: Round-robin or Least Connections.
Peak bandwidth: The peak bandwidth for the listener. This limits the service capacity of the backend ECS instances.
X-Forwarded-For: Allows the Server Load Balancer to obtain the real IP address of a client. This feature is enabled by default for security reasons.
Session persistence: When enabled, the Server Load Balancer listener directs requests from the same client to the same backend server.
Health check: When enabled, if a backend ECS instance fails a health check, the Server Load Balancer forwards requests to other healthy ECS instances. When the failed ECS instance recovers, the Server Load Balancer automatically resumes forwarding requests to it.