Search in sources :

Example 6 with LBHttpSolrClient

use of org.apache.solr.client.solrj.impl.LBHttpSolrClient in project lucene-solr by apache.

the class HttpShardHandlerFactory method createLoadbalancer.

protected LBHttpSolrClient createLoadbalancer(HttpClient httpClient) {
    LBHttpSolrClient client = new Builder().withHttpClient(httpClient).build();
    client.setConnectionTimeout(connectionTimeout);
    client.setSoTimeout(soTimeout);
    return client;
}
Also used : Builder(org.apache.solr.client.solrj.impl.LBHttpSolrClient.Builder) LBHttpSolrClient(org.apache.solr.client.solrj.impl.LBHttpSolrClient)

Aggregations

LBHttpSolrClient (org.apache.solr.client.solrj.impl.LBHttpSolrClient)6 QueryResponse (org.apache.solr.client.solrj.response.QueryResponse)2 IOException (java.io.IOException)1 MalformedURLException (java.net.MalformedURLException)1 Path (java.nio.file.Path)1 ArrayList (java.util.ArrayList)1 HashSet (java.util.HashSet)1 CloseableHttpClient (org.apache.http.impl.client.CloseableHttpClient)1 DefaultHttpClient (org.apache.http.impl.client.DefaultHttpClient)1 CloudSolrClient (org.apache.solr.client.solrj.impl.CloudSolrClient)1 ConcurrentUpdateSolrClient (org.apache.solr.client.solrj.impl.ConcurrentUpdateSolrClient)1 HttpSolrClient (org.apache.solr.client.solrj.impl.HttpSolrClient)1 Builder (org.apache.solr.client.solrj.impl.LBHttpSolrClient.Builder)1 QueryRequest (org.apache.solr.client.solrj.request.QueryRequest)1 CoreContainer (org.apache.solr.core.CoreContainer)1 HttpShardHandlerFactory (org.apache.solr.handler.component.HttpShardHandlerFactory)1 ShardHandlerFactory (org.apache.solr.handler.component.ShardHandlerFactory)1