SetBackendServers

Last Updated: May 22, 2017

Description

  • Set Backend Servers; set weight for the backend ECSs; return to the backend servers list for the Server Load Balancer instance.

Request parameter

Name Type Mandatory or not Description
Action String Yes Name of the operating interface, which is specified in the system. Value:SetBackendServers
LoadBalancerId String Yes The unique ID of an Server Load Balancer instance
BackendServers String Yes The backend servers list which need to be added. Value: a Json string,the structure is a JsonList。the number of backend servers contained in a list must be less than 20. The structure of the list elements is shown in the following table.
  • Backend server list(BackendServers)
Name Type Description
ServerId String Backend server ID (ECS instance ID)
Weight Integer Backend server Weight. Value: 0-100. Default: 100

Return parameter

Name Type Description
Common Parameter See Common Parameter for details.
LoadBalancerId String The unique ID of an 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 details.
  • Backend server information (BackendServers)
Name Type Description
ServerId String Backend server ID (ECS instance ID)
Weight Integer Backend server Weight. Value: 0-100

Example

Request example

  1. https://slb.aliyuncs.com/
  2. &Action=SetBackendServers
  3. &LoadBalancerId=139a00604ad-cn-east-hangzhou-01
  4. &BackendServers=[{"ServerId":"vm-233","Weight":"0"},{"ServerId":"vm-234","Weight":"0"}]
  5. &<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>0</Weight>
    9. </BackendServer>
    10. <BackendServer>
    11. <ServerId>vm-234</ServerId>
    12. <Weight>0</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":0},
    8. {"ServerId":"vm-234",
    9. "Weight":0}] }
    10. }
Thank you! We've received your feedback.