lucene-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Xavier Morera <xav...@familiamorera.com>
Subject Re: Question: Does Zookeeper/SolrCloud handle the failover?
Date Fri, 06 Jan 2017 14:34:31 GMT
Hi,

That's what we did in a project I was involved. Works fine for search. For indexing we check
clusterstate.json to see who is leader and then send all indexing requests to leader

Xavier

--------------------------------------------
Sent from a small attention grabbing screen


> On Jan 6, 2017, at 06:20, Mike Linnetz <Mike.Linnetz@theprimacy.com> wrote:
> 
> Thanks for the reply!
> What you describe makes sense.
> 
> I have another question as I'd like to present my team all of the options.
> 
> As an alternative to using SolrNetCloud to load balance, couldn't I just configure my
network load balancer to distribute requests among my cloud instances?  As I understand it,
Zookeeper and SolrCloud should take care of propagating any updates across all nodes in a
collection if a request is routed to any node in the collection.
> Is there anything I'm missing such that that solution would not work?
> 
> Thanks,
> Mike
> 
> 
> -----Original Message-----
> From: Mikhail Khludnev [mailto:mkhl@apache.org] 
> Sent: Thursday, January 5, 2017 4:26 PM
> To: general@lucene.apache.org
> Subject: Re: Question: Does Zookeeper/SolrCloud handle the failover?
> 
> Hello, Mike!
> 
> As far as I've got, you need to connect to SolrCloud (Zookeeper) via
> Solr.Net library.
> Here is the reference to the fork where it's done.
> https://github.com/mausch/SolrNet/issues/174#issuecomment-143697474
> Let me know if you need more info.
> 
> On Thu, Jan 5, 2017 at 8:50 PM, Mike Linnetz <Mike.Linnetz@theprimacy.com>
> wrote:
> 
>> Hello,
>> 
>> I am new to SolrCloud and Zookeeper, and there's a piece of the puzzle on
>> which I'm unclear.  I don't understand whether/how SolrCloud and Zookeeper
>> handles the high availability aspect.  That is, once I have the Zookeeper
>> ensemble set up, now how do I reference the collection in a
>> "high-availability" fashion so that if one Solr instance is down, it will
>> automatically route to another instance?
>> 
>> Am I thinking that SolrCloud does more than it actually does?  That is,
>> could I instead handle all Load Balancing outside of Zookeeper, and just
>> use our company's network load balancer to route/distribute traffic for a
>> single consolidated URL:port to the different actual Solr Instances/Ports?
>> 
>> Here's more details in case it helps:
>> I have an ASP.NET application which uses SolrNet to query and write to a
>> standalone Solr instance.  In my program , I specify the hostname:port of
>> my Solr instance:
>>                Startup.Init<SolrDoc>("hostname:port");
>> This setup was used for development and testing.
>> 
>> Now, for production, I need to implement Solr in a H.A. fashion so that I
>> don't have a single point of failure.    So, following Apache's
>> documentation, I understand that the solution would be to set up an
>> external Zookeeper Ensemble.
>> So, let's say I set up a new Zookeeper Ensemble (three instances). Let's
>> also say I have three Solr instances, #shards = 2, #replicas per shard = 2.
>> 
>> Once I have the Zookeeper ensemble set up, now how do I reference the
>> collection?
>> Previously, my code references a single standalone Solr instance, "
>> http://solrserver1:9983". What do I point it to now?
>> 
>> If I point it to any of the three Solr instances, and if that instance I'm
>> referencing goes down, it means the request would fail, right?
>> 
>> I read similar questions online, for example https://groups.google.com/
>> forum/#!msg/solrnet/-PeaGrLAMtw/pAfxuoYLVnIJ, and the answer seems to be
>> that SolrNet doesn't support this type of HA.  So, do I understand
>> correctly that the load balancing aspect needs to be handled on the
>> client-side (or via a network load balancer), not the zookeeper/solrcloud
>> server side?
>> 
>> Thanks,
>> Mike
>> 
>> 
>> 
>> 
> 
> 
> -- 
> Sincerely yours
> Mikhail Khludnev

Mime
View raw message