lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shawn Heisey <>
Subject Re: To understand SolrCloud configurations
Date Mon, 15 Dec 2014 06:22:51 GMT
On 12/14/2014 12:41 PM, E S J wrote:
> This question is related to the same configurations I've posted. How should
> I manually test indexing via Zookeeper, I mean not directly accessing solr
> nodes like,
> curl http://solr1.internal:7083/solr/c-ins/update?commit=true -H
> "Content-Type: text/xml" -d "@mem.xml"
> I have a solr client which uses CloudSolrServer to send request to
> SolrCloud, But my intention is to isolate my SolrCloud and send index &
> search requests to make sure Solr Cloud setup is working fine. Later I can
> do Solrclient integration testing. How should I send index requests
> manually ( like curl) to index data to solrcloud such a way CloudSolrServer
> use ZooKeeper to LB/Pick Solr instance ?

If you have either single-shard collections or multi-shard collections
with automatic routing, SolrCloud is designed so that you can send any
kind of request to any machine in the entire cloud, and it will be sent
where it needs to go.  If the collection uses manual (implicit) routing,
then queries can go anywhere, but updates must be directed to the
correct shard.

If you are not using CloudSolrServer, then you must either set up a load
balancer in front of SolrCloud, or your application will need to know
where your Solr servers are.  Curl cannot talk to zookeeper, because
zookeeper does not speak HTTP.

CloudSolrServer allows your application to specify only the zookeeper
hosts, it doesn't need to know where the Solr servers are.  This is
because it includes a full zookeeper client.

There is an API in Solr at /solr/zookeeper that can, with appropriate
parameters, return various pieces of information from zookeeper in JSON
format.  This is the place where the admin UI gathers the information
necessary to create the various options on the Cloud tab.  Once your
application has that information, it can use it to find out the Solr
URLs to use.

If this doesn't answer your question, please clarify it.


View raw message