SolrNet: How to switch Solr connection to another server if the current server is going down?

I need to configure two solr servers so that if one of the servers is down, traffic can be switched to the other server at runtime.

One way is to let Solr try to connect to the server, and then try connecting to another server. Is there a better way to do this? Using the try..catch method takes a long time, so if there is no better way, is there a faster way to use the try..catch method?

thank

+2


source to share


1 answer


You might want to use a regular HTTP load balancer like HAProxy or Varnish . This has the advantage of being completely transparent to your application.



+3


source







All Articles