using apache httpclient efficiently in multithreaded environment

2016-05-12 Thread Check Peck
I have a library which is being used by customer and they are passing DataRequest object which has userid, various timeouts and some other fields in it. Now I use this DataRequest object to make a URL and then I make an HTTP call using Apache HttpClient and my service returns back a JSON response w

Re: Apache HttpClient TCP Keep-Alive (socket keep-alive)

2016-05-12 Thread Oleg Kalnichevski
On Thu, 2016-05-12 at 13:46 +0100, Baratali Izmailov wrote: > > 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 clie

Re: Apache HttpClient TCP Keep-Alive (socket keep-alive)

2016-05-12 Thread Baratali Izmailov
> 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 th

Re: Apache HttpClient TCP Keep-Alive (socket keep-alive)

2016-05-12 Thread Oleg Kalnichevski
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

Re: Apache HttpClient TCP Keep-Alive (socket keep-alive)

2016-05-12 Thread Baratali Izmailov
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