Solr connection timeout hardwired to 60s

Shawn Heisey elyograg at elyograg.org
Sat Apr 13 18:16:34 EEST 2019


On 4/13/2019 4:29 AM, John Fawcett via dovecot wrote:
> If this value was made configurable people could set it to what they
> want. However the underlying problem is likely on solr configuration.

The Jetty that is included in Solr has its idle timeout set to 50 
seconds.  But in practice, I have not seen this timeout trigger ... and 
if the OP is seeing a 60 second timeout, then the 50 second idle timeout 
in Jetty must not be occurring.

There may be a socket timeout configured on inter-server requests -- 
distributed queries or the load balancing that SolrCloud does.  I can 
never remember whether this is the case by default.  I think it is.

> If there is an issue on initial indexing, where you are not really
> concerned about qucik visibility but just getting things into the index
> efficiently, a better approach would be for dovecot plugin not to send
> any commit or softCommit (or waitSearcher either) and that should speed
> things up. You'd need to configure solr with a long autoSoftCommit
> maxTime and a reasonable autoCommit maxTime, which you could then
> reconfigure when the load was done.

Solr ships with autoCommit set to 15 seconds and openSearcher set to 
false on the autoCommit.  The autoSoftCommit setting is not enabled by 
default, but depending on how the index was created, Solr might try to 
set autoSoftCommit to 3 seconds ... which is WAY too short.

I will usually increase the autoCommit time to 60 seconds, just to 
reduce the amount of work that Solr is doing.  The autoSoftCommit time, 
if it is used, should be set to a reasonably long value ... values 
between two and five minutes would be good.  Attempting to use a very 
short autoSoftCommit time will usually lead to problems.

This thread says that dovecot is sending explicit commits.  One thing 
that might be happening to exceed 60 seconds is an extremely long 
commit, which is usually caused by excessive cache autowarming, but 
might be related to insufficient memory.  The max heap setting on an 
out-of-the-box Solr install (5.0 and later) is 512MB.  That's VERY 
small, and it doesn't take much index data before a much larger heap is 
required.

Thanks,
Shawn


More information about the dovecot mailing list