You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Jason Gerlowski (JIRA)" <ji...@apache.org> on 2017/11/19 12:58:03 UTC
[jira] [Comment Edited] (SOLR-11596) SolrJ clients -- create
internal HttpClient objects with increased thread capability
[ https://issues.apache.org/jira/browse/SOLR-11596?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16258477#comment-16258477 ]
Jason Gerlowski edited comment on SOLR-11596 at 11/19/17 12:57 PM:
-------------------------------------------------------------------
Poking through the code, it's not clear to me that SolrClient's get the default max-connections-per-route...{{HttpClientUtil.createClient}}, eventually filters down to the following line:
{code}
cm.setDefaultMaxPerRoute(params.getInt(HttpClientUtil.PROP_MAX_CONNECTIONS_PER_HOST, 10000));
{code}
(see direct link here: https://github.com/apache/lucene-solr/blob/master/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java#L246)
Am I missing something here?
was (Author: gerlowskija):
Poking through the code, it's not clear to me that create HttpClient's are fed the default max-connections-per-route.
{{HttpClientUtil.createClient}}, eventually filters down to the following line:
{code}
cm.setDefaultMaxPerRoute(params.getInt(HttpClientUtil.PROP_MAX_CONNECTIONS_PER_HOST, 10000));
{code}
(see direct link here: https://github.com/apache/lucene-solr/blob/master/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java#L246)
Am I missing something here?
> SolrJ clients -- create internal HttpClient objects with increased thread capability
> ------------------------------------------------------------------------------------
>
> Key: SOLR-11596
> URL: https://issues.apache.org/jira/browse/SOLR-11596
> Project: Solr
> Issue Type: Bug
> Security Level: Public(Default Security Level. Issues are Public)
> Components: clients - java
> Affects Versions: 7.1
> Reporter: Shawn Heisey
> Priority: Minor
>
> The HttpClient object that various SolrClient implementations create has HttpClient's default per-destination thread limit of two. I'm not sure why they went with such a low default, but that's out of our hands. The low default makes default SolrClient objects that are thread-safe, but basically unable to handle more than two threads at the same time.
> Increasing this limit in user programs is very doable by creating a custom HttpClient object, but the amount of code required is fairly extensive.
> I think that when our client implementations create an HttpClient object, they should explicitly increase the thread limits to larger default values, and expose configuration knobs for those values in the fluent interface.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org