Answers inline.
On Fri, Jul 25, 2014 at 3:06 AM, CB <[email protected]> wrote: > thanks for the answers, here are my thoughts: > > 1. If using pure REST client - Using a Load Balancer will make sure that > the endpoint address goes to any of the "live" nodes (round robin) so that > if one of those nodes "dies" or if I scale out the cluster (add more nodes) > it is transparent to the client. Does that make sense? > I do not use the REST client, but I would assume the use of a load balancer would depend on the client library. With the Java TransportClient, you simply provide a list of valid nodes and the option to discover other nodes based on those nodes (client.transport.sniff). If the REST client library has the same functionality, then there is no need for a load balancer, but it could simplify things to simply point to a load balancer. > 2. Jörg - can you please provide more details / link explaining about why > and how the "REST API sits on top a Java Client" > The Java API is the "true" API for Elasticsearch. The REST API is simply a wrapper around the Java API. The Java API is therefore always feature complete, while potentially the REST API might not expose everything. Take a look at the various Rest*Action classes such as RestSearchAction. You will see that basically the REST call gets transformed into a call using the Java API. > > 3. The java client is fine but the documentation of the actual query API > is pretty basic and will always send you to the REST documentation. I found > it hard to "translate" the REST API docs to native java client APIs > The Java documentation is indeed lacking. I believe David has a better write somewhere, but I always refer to the actual code for detailed usage of the API. You can look at both the aforementioned Rest*Action class or simply the many unit tests for concrete end-to-end examples. > elastic4s seems very promising, although not sure it supports scala 2.11. > I might give it a spin - thanks for the tip ;) > > BTW - Do you know if the java client is using a binary protocol ? that > might become a big advantage over REST for large query results.. > The Java Client is indeed binary and will have many advantages over REST. However, serialization issues between versions can occur, but the issue has almost gone away since the 1.x release. You still might have issues with newer clients accessing older servers. Cheers, Ivan -- You received this message because you are subscribed to the Google Groups "elasticsearch" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQDar92Lu_Y6WMkyzrRQ%3DVp3goGwDda1O74fq-Fsr41TDg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
