> Please consider upgrading. I am not entirely sure if HC 4.2 supports TCP > keepalive setting.
Unfortunately, to upgrade HC we need to upgrade Spring to the latest version which requires Java 8. But, we cannot force our clients to use Java 8 yet. However, I don't see SO_KEEPALIVE parameter in the lastest Apache HC javadocs in "The following parameters can be used to customize the behavior of this class:" section: https://hc.apache.org/httpcomponents-client-ga/httpclient/apidocs/org/apache/http/impl/client/DefaultHttpClient.html Could you please show me example how to set SO_KEEPALIVE parameter in new versions of Apache HC? Thanks, Baratali Izmailov. On 12 May 2016 at 09:53, Oleg Kalnichevski <ol...@apache.org> wrote: > On Thu, 2016-05-12 at 09:23 +0100, Baratali Izmailov wrote: > > Hello. Thanks for the quick response. > > > > > Is there any way you can turn this into 2 requests? > > For now we cannot split this into 2 HTTP requests, because we have to > > change client-server protocol communication and re-implement some parts > of > > our application, which will take much time. > > I understand that it is not that effective to keep connection open too > > long, but it's only simple solution I see for now. > > > > > What version of HttpClient are you using? It looks like something > fairly > > old. > > It is 4.2.2. Actually I use Spring 3.2.1 httpInvoker which uses > > DefaultHttpClient. > > > > Please consider upgrading. I am not entirely sure if HC 4.2 supports TCP > keepalive setting. > > Oleg > > > > Using TCP keepalive wont help you with default OS settings, it would > not > > start to send them in the first 20 idle minutes. > > Can I configure Apache httpd server to do this (set keep-alive timeouts)? > > > > Thanks, > > Baratali. > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org > For additional commands, e-mail: httpclient-users-h...@hc.apache.org > >