You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Naveen Pajjuri <pa...@myntra.com> on 2016/07/30 08:23:32 UTC

CloudSolrServer instead of httpSolrServer

Hi,
While sending updates to solr cloud i randomly send updates to one of the
node (in my cloud) directly using httpSolrServer. if i use cloudSolrServer
(by passing zk ip's), instead of httpSolrServer can i expect any improvment
in performance.

my baisc question is how does updates propagate when i directly send
updates to one of the node using httpSolrServer in cloud model.

   - will the update bounces back to leader direclty??
   - or will it send to every node till it finds leader??


Thank You.

Re: CloudSolrServer instead of httpSolrServer

Posted by Erick Erickson <er...@gmail.com>.
In a word "yes". CloudSolrClient figures out what
shard each document belongs on and sends the
doc directly to the shard leader. If you use the
client.add(docList) format it sends sub-lists
consisting of the documents for each shard to
the correct shard leader in parallel by default.

Plus, CloudSolrClient will be aware of the
status of the collection and compensate whenever
nodes go up/down so you don't have to worry about
that kind of error handling in your client.

I'm assuming you're using 4.x, CloudSolrServer
has been renamed CloudSolrClient in 5x and beyond.

Best,
Erick

On Sat, Jul 30, 2016 at 1:23 AM, Naveen Pajjuri
<pa...@myntra.com> wrote:
> Hi,
> While sending updates to solr cloud i randomly send updates to one of the
> node (in my cloud) directly using httpSolrServer. if i use cloudSolrServer
> (by passing zk ip's), instead of httpSolrServer can i expect any improvment
> in performance.
>
> my baisc question is how does updates propagate when i directly send
> updates to one of the node using httpSolrServer in cloud model.
>
>    - will the update bounces back to leader direclty??
>    - or will it send to every node till it finds leader??
>
>
> Thank You.