On Wed, 2018-05-16 at 15:16 +0300, Дмитрий Жихарев wrote: > Hi all! > > I was wondering if the IOReactorConfig.DEFAULT intentionally has > soTimeout set to ZERO_MILLESECONDS. Before version 5 there was also > connectTimeout, which also was 0 for the default builder. I > understand that the library can't make up its own mind on what > timeout the user requires, but isn't it a good practice for the > default config to have some sensible defaults so it doesn't hang > forever if something goes wrong? > > Regards, Dmitry Zhikharev >
Hi Dmitry HttpClient 5.0 already uses finite (3 min) timeout values for connect and connection request operations. https://github.com/apache/httpcomponents-client/blob/master/httpclient5 /src/main/java/org/apache/hc/client5/http/config/RequestConfig.java#L44 It is more difficult to say what the default value of socket timeout should be as different application might have different expectations and operational assumptions. What kind of value would you propose? Oleg --------------------------------------------------------------------- To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org For additional commands, e-mail: httpclient-users-h...@hc.apache.org