AddBackendServers

Last Updated: Nov 07, 2017

Description

  • Add the backend server; add a group of backend servers to the Server Load Balancer instance (ECS instance) to return the backend server list of the Server Load Balancer instance.
  • Note: If BackendServers contains ECS instance already added, the ECS instance will be ignored, without any error being reported. If multiple identical ECS instances are to be added in one request, only the first instance will be taken while other identical instances will be ignored.

Request parameter

Name Type Required Description
Name String Yes Name of the operating interface, which is specified in the system. Value: AddBackendServers.
LoadBalancerId String Yes The unique ID of the Server Load Balancer instance.
BackendServers String Yes Backend server list to be added.

Value: It is a Jsonstring, and its structure is a JsonList. The List can only contain 20 elements at most in one request. See the following table and call example for the detailed structure of the List.

Backend server information (BackendServers)

Name Type Description
ServerId String

Backend server ID (ECS instance ID).

Weight Integer

Weight of the backend server, in the range of 0-100.

default: 100.

Return parameter

Name Type Description
Common Parameter For more information, see Common Parameter.
LoadBalancerId String

The unique ID of the Server Load Balancer instance.

BackendServers List

Information of multiple backend servers in the Server Load Balancer instance is returned in the array format. See the following table for more information.

Backend server information (BackendServers)
Name Type Description
ServerId String

Backend server ID (ECS instance ID).

Weight Integer

Weight of the backend server, in the range of 1-100.

Example

Request example

  1. https://slb.aliyuncs.com/
  2. &Action=AddBackendServers
  3. &LoadBalancerId=139a00604ad-cn-east-hangzhou-01
  4. &BackendServers=[
  5. {"ServerId":" vm-233","Weight":"100"},
  6. {"ServerId":" vm-234","Weight":"100"}]
  7. &<common request parameter>

Return example

  • XML format
    1. <?xml version="1.0" encoding="UTF-8"?>
    2. <AddBackendServersResponse>
    3. <RequestId>365F4154-92F6-4AE4-92F8-7FF34B540710</RequestId>
    4. <LoadBalancerId>139a00604ad-cn-east-hangzhou-01</LoadBalancerId>
    5. <BackendServers>
    6. <BackendServer>
    7. <ServerId>vm-233</ServerId>
    8. <Weight>100</Weight>
    9. </BackendServer>
    10. <BackendServer>
    11. <ServerId>vm-234</ServerId>
    12. <Weight>100</Weight>
    13. </BackendServer>
    14. </BackendServers>
    15. </AddBackendServersResponse>
  • JSON format
    1. {
    2. "RequestId":"365F4154-92F6-4AE4-92F8-7FF34B540710",
    3. "LoadBalancerId":"139a00604ad-cn-east-hangzhou-01",
    4. "BackendServers":{
    5. BackendServer”: [
    6. {"ServerId":"vm-233",
    7. "Weight":100},
    8. {"ServerId":"vm-234",
    9. "Weight":100}] }
    10. }
Thank you! We've received your feedback.