bq: Reason being If a write request is sent to the replica it relays it to the leader and then the leader relays it to all the replicas. This will help me in saving some network traffic as my application performs continuous writes
How are you indexing? SolrJ already is "leader aware" and sends updates to the leaders. Requests should go to any node, there's no good reason to send requests only to replicas since the replicas and leaders are both search and index nodes. And an upcoming enhancement to SolrJ will additionally route the documents to the correct leader, i.e. it'll divide documents up into packets that all live on the same shard and send those packets to the leader for that shard. Unless you can prove that this is actually causing you trouble, I'd advise not spending the effort on this and focusing on other aspects of your project.. This _really_ feels like premature optimization. Best Erick On Wed, Jul 3, 2013 at 8:27 AM, vicky desai <vicky.de...@germinait.com>wrote: > Hi, > > I have a requirement where in I want to write to the leader and read from > the replica. Reason being If a write request is sent to the replica it > relays it to the leader and then the leader relays it to all the replicas. > This will help me in saving some network traffic as my application performs > continuous writes > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Is-it-possible-to-find-a-leader-from-a-list-of-cores-in-solr-via-java-code-tp4074994p4075083.html > Sent from the Solr - User mailing list archive at Nabble.com. >