public class HealthClient extends Object
Modifier and Type | Method and Description |
---|---|
ConsulResponse<List<ServiceHealth>> |
getAllServiceInstances(String service)
Retrieves the healthchecks for all nodes.
|
ConsulResponse<List<ServiceHealth>> |
getAllServiceInstances(String service,
QueryOptions queryOptions)
Retrieves the healthchecks for all nodes in a given datacenter with
QueryOptions . |
void |
getAllServiceInstances(String service,
QueryOptions queryOptions,
ConsulResponseCallback<List<ServiceHealth>> callback)
Asynchronously retrieves the healthchecks for all nodes in a given
datacenter with
QueryOptions . |
ConsulResponse<List<HealthCheck>> |
getChecksByState(State state)
Retrieves the healthchecks for a state.
|
ConsulResponse<List<HealthCheck>> |
getChecksByState(State state,
QueryOptions queryOptions)
Retrieves the healthchecks for a state in a given datacenter with
QueryOptions . |
void |
getChecksByState(State state,
QueryOptions queryOptions,
ConsulResponseCallback<List<HealthCheck>> callback)
Asynchronously retrieves the healthchecks for a state in a given datacenter with
QueryOptions . |
ConsulResponse<List<ServiceHealth>> |
getHealthyServiceInstances(String service)
Retrieves the healthchecks for all healthy service instances.
|
ConsulResponse<List<ServiceHealth>> |
getHealthyServiceInstances(String service,
QueryOptions queryOptions)
Retrieves the healthchecks for all healthy service instances in a given datacenter with
QueryOptions . |
void |
getHealthyServiceInstances(String service,
QueryOptions queryOptions,
ConsulResponseCallback<List<ServiceHealth>> callback)
Asynchronously retrieves the healthchecks for all healthy service instances in a given
datacenter with
QueryOptions . |
ConsulResponse<List<HealthCheck>> |
getNodeChecks(String node)
Retrieves the healthchecks for a node.
|
ConsulResponse<List<HealthCheck>> |
getNodeChecks(String node,
QueryOptions queryOptions)
Retrieves the healthchecks for a node in a given datacenter with
QueryOptions . |
ConsulResponse<List<HealthCheck>> |
getServiceChecks(String service)
Retrieves the healthchecks for a service.
|
ConsulResponse<List<HealthCheck>> |
getServiceChecks(String service,
QueryOptions queryOptions)
Retrieves the healthchecks for a service in a given datacenter with
QueryOptions . |
void |
getServiceChecks(String service,
QueryOptions queryOptions,
ConsulResponseCallback<List<HealthCheck>> callback)
Asynchronously retrieves the healthchecks for a service in a given
datacenter with
QueryOptions . |
public ConsulResponse<List<HealthCheck>> getNodeChecks(String node)
node
- The node to return checks forConsulResponse
containing a list of
HealthCheck
objects.public ConsulResponse<List<HealthCheck>> getNodeChecks(String node, QueryOptions queryOptions)
QueryOptions
.
GET /v1/health/node/{node}?dc={datacenter}node
- The node to return checks forqueryOptions
- The Query Options to use.ConsulResponse
containing a list of
HealthCheck
objects.public ConsulResponse<List<HealthCheck>> getServiceChecks(String service)
ConsulResponse
containing a list of
HealthCheck
objects.public ConsulResponse<List<HealthCheck>> getServiceChecks(String service, QueryOptions queryOptions)
QueryOptions
.
GET /v1/health/checks/{service}?dc={datacenter}queryOptions
- The Query Options to use.ConsulResponse
containing a list of
HealthCheck
objects.public void getServiceChecks(String service, QueryOptions queryOptions, ConsulResponseCallback<List<HealthCheck>> callback)
QueryOptions
.
GET /v1/health/checks/{service}?dc={datacenter}service
- The service to query.queryOptions
- The Query Options to use.callback
- Callback implemented by callee to handle results.
HealthCheck
objects.public ConsulResponse<List<HealthCheck>> getChecksByState(State state)
state
- The state to query.ConsulResponse
containing a list of
HealthCheck
objects.public ConsulResponse<List<HealthCheck>> getChecksByState(State state, QueryOptions queryOptions)
QueryOptions
.
GET /v1/health/state/{state}?dc={datacenter}state
- The state to query.queryOptions
- The Query Options to use.ConsulResponse
containing a list of
HealthCheck
objects.public void getChecksByState(State state, QueryOptions queryOptions, ConsulResponseCallback<List<HealthCheck>> callback)
QueryOptions
.
GET /v1/health/state/{state}?dc={datacenter}state
- The state to query.queryOptions
- The Query Options to use.callback
- Callback implemented by callee to handle results.public ConsulResponse<List<ServiceHealth>> getHealthyServiceInstances(String service)
service
- The service to query.ConsulResponse
containing a list of
HealthCheck
objects.public ConsulResponse<List<ServiceHealth>> getHealthyServiceInstances(String service, QueryOptions queryOptions)
QueryOptions
.
GET /v1/health/service/{service}?dc={datacenter}&passingservice
- The service to query.queryOptions
- The Query Options to use.ConsulResponse
containing a list of
HealthCheck
objects.public void getHealthyServiceInstances(String service, QueryOptions queryOptions, ConsulResponseCallback<List<ServiceHealth>> callback)
QueryOptions
.
GET /v1/health/service/{service}?dc={datacenter}&passing
Experimental.service
- The service to query.queryOptions
- The Query Options to use.callback
- Callback implemented by callee to handle results.public ConsulResponse<List<ServiceHealth>> getAllServiceInstances(String service)
service
- The service to query.ConsulResponse
containing a list of
HealthCheck
objects.public ConsulResponse<List<ServiceHealth>> getAllServiceInstances(String service, QueryOptions queryOptions)
QueryOptions
.
GET /v1/health/service/{service}?dc={datacenter}service
- The service to query.queryOptions
- The Query Options to use.ConsulResponse
containing a list of
HealthCheck
objects.public void getAllServiceInstances(String service, QueryOptions queryOptions, ConsulResponseCallback<List<ServiceHealth>> callback)
QueryOptions
.
GET /v1/health/service/{service}?dc={datacenter}
Experimental.service
- The service to query.queryOptions
- The Query Options to use.callback
- Callback implemented by callee to handle results.Copyright © 2017. All rights reserved.