Device Configuration SOAP Methods

The Configuration API provides over 2500 different methods to alter load balancer configuration. Configuring a load balancer is usually a complicated task and goes far beyond the scope of this book. In this section I am going to show how to get a list of services, and then you will learn how to enable and disable them. Other functions behave in a very similar fashion, so if you need to create a new virtual server you would just call appropriate functions.

Table 2-2 lists the methods we will be using in the configuration tool, along with each one's return variable and a description.

Table 2-2. Methods Used to Enable and Disable Servers

Method

Return Variable

Description

disableservice

_rc

The return code of the operation (simpleResult type); 0 if successful.

_message

A detailed explanation of the result (simpleResult type). Done" if successful; otherwise a meaningful explanation is provided.

enableservice

_rc

The return code of the operation (simpleResult type); 0 if successful.

_message

A detailed explanation of the result (simpleResult type). "Done" if successful; otherwise a meaningful explanation is provided.

getlbvserver

_servicename

A list of all services bound to a particular virtual server.

As you can see, the first two methods for enabling and disabling services are really simple in their responses; they either succeed or fail. Just like the login method, they return a datastructure simpleResponse, which contains only a return code and a detailed description of the error in case of failure.

The last method is getlbvserver, which we used in previous section to retrieve a list of all services that are bound to a virtual server. The same method wrapper will be reused here as well.

Was this article helpful?

0 0

Post a comment