dsmiley commented on code in PR #4626:
URL: https://github.com/apache/solr/pull/4626#discussion_r3837673262
##########
solr/solrj-jetty/src/java/org/apache/solr/client/solrj/jetty/HttpJettySolrClient.java:
##########
@@ -301,7 +301,7 @@ private HttpClient createHttpClient(Builder builder) {
asyncTracker.getMaxRequestsQueuedPerDestination());
httpClient.setUserAgentField(new HttpField(HttpHeader.USER_AGENT,
USER_AGENT));
httpClient.setConnectTimeout(builder.getConnectionTimeoutMillis());
- httpClient.setIdleTimeout(-1); // don't enforce an idle timeout at this
level
+ httpClient.setIdleTimeout(SolrHttpConstants.DEFAULT_SO_TIMEOUT);
Review Comment:
Real world scenario: A user (or internal Solr code) needs to create
HttpJettySolrClient instances for the solrj-streaming SolrClientCache. That
module implies use-cases where streams are rather long-lived -- a request
timeout would not be found in local testing but in production and it'd suck.
Especially within Solr, it's common to create a HttpJettySolrClient by
providing an existing client as a sort of template/default into a builder for a
new client so it can be customized further. These instances should have no
request timeout and a rather long idle timeout (like 60sec).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]