Get a node pool
From Hostway API Documentation
Contents |
GET /accounts/{accountId}/loadbalancers/{lbId}/nodePools/{nodePoolId}
This operation lists the details for the specified node pool
Request
GET /accounts/{accountId}/loadbalancers/{lbId}/nodePools/{nodePoolId}
Request Parameters
- accountId - string
- The selected account id.
- lbId - string
- The selected load balancer id.
- nodePoolId - string
- The selected node pool id.
Response
Response Codes
- 200 OK
- 401 Unauthorized
- This server could not verify that you are authorized to access the document you requested. Either you supplied the wrong credentials (e.g., bad password), or your browser does not understand how to supply the credentials required.
- 404 Not Found
- The resource does not exist.
Response Body
{ "id": "{nodePoolId}", "displayName": "{lbName}", "protocol": "{lbProtocol}", "port": {lbPort}, "algorithm": "{lbAlgorithm}", "timeout": {timeout}, "nodes": [{"href": "http://{api-server}/accounts/{accountId}/loadbalancers/{lbId}/nodePools/{nodePoolId}/nodes", "rel": "related"}], "sessionPersistence": [{"href": "http://{api-server}/accounts/{accountId}/loadbalancers/{lbId}/nodePools/{nodePoolId}/sessionpersistence", "rel": "related"}], "healthMonitor": [{"href": "http://{api-server}/accounts/{accountId}/loadbalancers/{lbId}/nodePools/{nodePoolId}/healthmonitor", "rel": "related"}], "links": [{"href": "http://{api-server}/accounts/{accountId}/loadbalancers/{lbId}/nodePools/{nodePoolId}", "rel": "self"}] }
Parameters
- id - string
- The id of this node pool.
- displayName - string
- The display name of the node pool.
- protocol - string
- The protocol to be balanced by this load balancer
- Allowed values are TCP or HTTP. (Note: HTTPS is not supported)
- port - integer
- The tcp port the load balancer will act on
- Allowed range is 1 ~ 65535
- algorithm - string
- Load balancing algorithm to be used
- Allowed values are ROUND_ROBIN or SOURCE_IP
- timeout - integer
- Load balancer timeout (ex, check, connect timeouts)
- nodes - list
- Hypermedia to a resource of the nodes under this node pool
- sessionPersistence - list
- Optional, Hypermedia to a resource of the session persistence under this node pool
- if node pool has no sessionPersistence, this will not be returned
- healthMonitor - list
- Optional, Hypermedia to a resource of the health monitor under this node pool
- if node pool has no healthMonitor, this will not be returned
- links - list
- Hypermedia for this resource. Links to self.
Examples
Successfully list details for specified load balancer
Request
GET /accounts/{accountId}/loadbalancers/{lbId}/nodePools/123 Content-Type:application/json Charset=UTF-8 Authorization: Basic {Base64-encoded username & password string}
Response
HTTP/1.1 200 OK { "id" : "123", "displayName" : "test Load Balancer", "protocol" : "HTTP", "port" : 80, "algorithm" : "ROUND_ROBIN", "timeout": 30, "nodes" : [{"href": "http://{api-server}/accounts/{accountId}/loadbalancers/{lbId}/nodePools/123/nodes", "rel": "related"}], "sessionPersistence" : [{"href": "http://{api-server}/accounts/{accountId}/loadbalancers/{lbId}/nodePools/123/sessionpersistence", "rel": "related"}], "healthMonitor" : [{"href": "http://{api-server}/accounts/{accountId}/loadbalancers/{lbId}/nodePools/123/healthmonitor", "rel": "related"}], "links" : [{"href" : "http://{api-server}/accounts/{accountId}/loadbalancers/{lbId}/nodePools/123", "rel" : "self"}] }
Failure while trying to request details for a node pool that does not exist
Request
GET /accounts/{accountId}/loadbalancers/{lbId}/nodePools/{fake-node-pool-id} Content-Type:application/json Charset=UTF-8 Authorization: Basic {Base64-encoded username & password string}
Response
HTTP/1.1 404 Not Found { "itemNotFound": { "message": "Resource not found", "code": 404, "details": "", "errorid": "59e0b3dd-2173-432a-8ff5-60efe16e83bf" } }