WebAPI Reference Guide > Available API Methods > Server and Cluster Management Methods > The clusterGetServersCount Method

The clusterGetServersCount Method

Get the number of servers registered in the cluster. Note that this action ignores the servers’ current state and returns only a total number of known servers. In a single-server the response to this action will always be 0.

Version: 1.3

Required Permissions: read-only

HTTP method: GET

Supported by Editions: Zend Server

Request Parameters: There are no request parameters.

Expected Response Code: 200 OK

Response Type: serversCount

Possible Action Specific Error Codes: There are no action specific error codes.

Example

Usage Example

Request (URI broken for readability)

GET /ZendServerManager/Api/clusterGetServerCount

Response

<?xml version="1.0" encoding="UTF-8"?>

<zendServerAPIResponse xmlns="http://www.zend.com/server/api/1.0">

<requestData>

<apiKeyName>angel.eyes</apiKeyName>

<method>clusterGetServersStatus</method>

</requestData>

<responseData>

<serversCount>2</serversCount>

</responseData>

</zendServerAPIResponse>

 

 

 

Related Links

Related Links:

Server and Cluster Management Methods

 

 

 

© 1999-2013 Zend Technologies, Ltd. All rights reserved.