Node client as load balancer node

(None) #1

Hi I'm building a micro service using the native Java Node Client. The client is set to data = false and http = false because I want my user to go through my micro service. The Elasticsearch data nodes HTTP is disabled.

Do we get the same advantages from the node client as mentioned here:

(Luca Cavanna) #2

Yes, but I would also set master to false, otherwise that node can be elected as master, which is not good given that it is embedded in your application. In general, I would try to avoid using embedded client nodes though, as they do much more than a normal client (reduce phase in search, they hold the cluster state etc.). I would rather use the transport client in your application which connects to a separate process, possibly on the same machine as your application, that is the actual client node that joins the cluster. That way the client node would be more isolated and independent from your application.

(None) #3

But as transport client would it do the scatter gather portion?

(Luca Cavanna) #4

The tranport client would do the round robin across the nodes it knows about. No scatter gather, that is a pure client, as opposed as the node client which does more. hope this clarifies things.

(None) #5


(system) #6