# How to request an Elasticsearch cluster?

**URL:** <https://discuss.elastic.co/t/how-to-request-an-elasticsearch-cluster/78897>\
**Category:** Elasticsearch\
**Created:** [March 16, 2017, 3:57pm UTC](https://discuss.elastic.co/t/how-to-request-an-elasticsearch-cluster/78897 "2017-03-16T15:57:57Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![sen](https://avatars.discourse-cdn.com/v4/letter/s/cc9497/32.png) [@sen](https://discuss.elastic.co/u/sen)\
**Post date:** [March 16, 2017, 3:57pm UTC](https://discuss.elastic.co/t/how-to-request-an-elasticsearch-cluster/78897/1 "2017-03-16T15:57:57Z")

</div>

Hello folks,

I am building an Elasticsearch sluter with 3 nodes named 'node-i' where i=1,2 or 3.  
With a java or javascript client I want to request my data but I don't know which nodes to specify. Do you know how to do that ?

Regards

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [March 16, 2017, 4:41pm UTC](https://discuss.elastic.co/t/how-to-request-an-elasticsearch-cluster/78897/2 "2017-03-16T16:41:20Z")

</div>

Anyone you wish or all of them.

If you know their IP addresses whatever their node is, then just use that.

---

<div class="post-metadata">

**Author:** ![sen](https://avatars.discourse-cdn.com/v4/letter/s/cc9497/32.png) [@sen](https://discuss.elastic.co/u/sen)\
**Post date:** [March 16, 2017, 4:43pm UTC](https://discuss.elastic.co/t/how-to-request-an-elasticsearch-cluster/78897/3 "2017-03-16T16:43:58Z")

</div>

Ok but if i want to request my cluster to search something. Do I only have to send the request to a node among the cluster to get the response ? but if yes, if the node requested is down...i will get an error  
I don't know if it is clear what I am asking..

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [March 16, 2017, 5:15pm UTC](https://discuss.elastic.co/t/how-to-request-an-elasticsearch-cluster/78897/4 "2017-03-16T17:15:37Z")

</div>

It's the responsability of the client to detect it and route the operations to nodes which are still alive.

Or you can use a load balancer in front of the cluster which will do a similar job.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [April 13, 2017, 5:15pm UTC](https://discuss.elastic.co/t/how-to-request-an-elasticsearch-cluster/78897/5 "2017-04-13T17:15:40Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
