Hi all,

I'm trying to use the ConcurrentUpdateSolrClient class, that has some methods 
that accept and aditional parameter to indicate the collection, some of this 
methods are add(String collection, SolrInputDocument doc), request(SolrRequest, 
String collection). With HttpSolrClient this works flawlessly, but with 
ConcurrentUpdateSolrClient the request gets made against the URL specified in 
the constructor. 

In the case of the  commit(String collection) method, works without any trouble 
and the commit gets fired against the desired collection. 

Is this expected behavior? 

I'm using Solr 5.1.0/solrj 5.1.0. Haven't tried with 5.2.

Any thoughts on this?

Best regards,

Example code:

        SolrClient client = new 
ConcurrentUpdateSolrClient("http://localhost:8983/solr/";, 10, 1);

        SolrInputDocument doc = new SolrInputDocument();
        doc.addField("title", "this is a title of the document");

        client.add("status", doc); // trying to commit the document to a 
specific collection
        client.commit("status"); // commit to the same collection

Reply via email to