solarium icon indicating copy to clipboard operation
solarium copied to clipboard

Solr HTTP error: HTTP request failed, Operation timed out after 5000 milliseconds with 0 bytes received

Open htmax opened this issue 7 years ago • 3 comments

Solr HTTP error: HTTP request failed, Operation timed out after 5000 milliseconds with 0 bytes received How can I change the timeout?

htmax avatar Sep 20 '19 02:09 htmax

I would like to know that as well. I see in the adapter class the option for timeout but I don't know where to pass it on initialisation.

xiopt avatar Oct 04 '19 11:10 xiopt

You can pass 'timeout' as an endpoint option when instantiating Client

$client = new Client([
'endpoint' => [
   'localhost' => [
      'host' => 'localhost',
      'port' => 8983,
      'path' => '/',
      'collection' => 'yourcollection',
      'timeout' => 30,
      ]
   ]
]);

ryross avatar Oct 18 '19 16:10 ryross

@ryross that's right :-)

There's also a setter to adjust the value on the fly: Endpoint::setTimeout().

mkalkbrenner avatar Dec 06 '19 12:12 mkalkbrenner