Currently it seems that the ConsulHttpClient.getService method uses the Cataloghttps://www.consul.io/api/catalog.html#list-nodes-for-service to get all the endpoints for a service; but if a certain endpoint is considered unhealthy (for example since the consul agent is in failed mode due to network partition the client doesn't excluded it from the available nodes.
Currently it seems that the
ConsulHttpClient.getService
method uses the Catalog https://www.consul.io/api/catalog.html#list-nodes-for-service to get all the endpoints for a service; but if a certain endpoint is considered unhealthy (for example since the consul agent is infailed
mode due to network partition the client doesn't excluded it from the available nodes.Maybe it's better to use the Health https://www.consul.io/api/health.html#list-nodes-for-service for this?