On Sun, 2014-08-24 at 12:07 +0800, whybert wrote: > Hi, > I am evaluating HTTP Async client and have following questions. > > > There are two ways to set ConnectTimeout and SoTimeout in official examples: > // Create I/O reactor configuration > IOReactorConfig ioReactorConfig = IOReactorConfig.custom() > .setIoThreadCount(Runtime.getRuntime().availableProcessors()) > .setConnectTimeout(30000) > .setSoTimeout(30000) > .build(); > RequestConfig requestConfig = RequestConfig.copy(defaultRequestConfig) > .setSocketTimeout(5000) > .setConnectTimeout(5000) > .setConnectionRequestTimeout(5000) > .build(); > What's the difference between the two ways?
Consider I/O reactor configuration to be global defaults some which can overridden at the request level. > And I find the IOReactorConfig.custom().setConnectTimeout() doesn't seem to > work. I can see the default connecting I/O reactor impl clearly making use of this parameter. Could you please make sure you are not overriding the I/O reactor defaults at the request level? Oleg --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
