On 1/7/2016 3:11 PM, Aswath Srinivasan (TMS) wrote:
> I have a situation where the search front-end application is using java 1.6. 
> Upgrading Java version is out of the question.
>
> Planning to use Solrcloud 5.x version for the search implementation. The show 
> stopper here is, solrj for solrcloud needs atleast java1.7
>
> What best can be done to use the latest version of solrcloud and solrj for a 
> portal that runs on java 1.6?

The last version of Solr (and SolrJ) that supports Java 6 is 4.7.2.  I
would strongly NOT recommend using the CloudSolrServer object from SolrJ
4.7.2 with SolrCloud 5.x.  SolrCloud is evolving *very* quickly from
version to version, so different versions may not work together well. 
With the difference being a *major* version, I would not be surprised if
doesn't work at all.

> I was thinking, in solrj, instead of using zookeeper (which also acts as the 
> load balancer) I can mention the exact replica's http://solr-cloud-HOST:PORT 
> pairs using some kind of round-robin with some external load balancer.

You have two choices here, assuming you'll be using SolrJ 4.7.2.

One choice is to put a load balancer in front of your SolrCloud and use
that host in the HttpSolrServer object.  I use haproxy for a Solr load
balancer, it works very well.

The other choice is to put all of the server URLs into an instance of
LBHttpSolrServer.  I have never used this object, but this is the same
object that CloudSolrServer uses internally, so it should work.  It will
not respond as quickly to clusterstate changes as CloudSolrServer would,
because it cannot talk to Zookeeper.

Cross-version compatibility with HttpSolrServer and LBHttpSolrServer
should be very good.  It's just CloudSolrServer that doesn't work well
when you mix versions.

Thanks,
Shawn

Reply via email to