Efficiently repeating identical requests

2010-01-09 Thread Tony Poppleton
Hi, I send out the exact same HttpPost request every 3 milliseconds and would like to optimize it. As the POST data is exactly the same, I would like to hold it in a direct ByteBuffer so it is in the kernel memory, and then use the efficient NIO transfer methods to send it to the socket.  Is

re: Efficiently repeating identical requests

2010-01-09 Thread Tony Poppleton
Hi, Further to the previous mail, I have already implemented my own AbstractHttpEntity to eliminate a byte[] copy.  And I have seen the NIO implementations of HttpEntities, however they don't seem to copy using NIO methods so they won't be any faster than the standard IO implementations.

Re: Efficiently repeating identical requests

2010-01-09 Thread Ken Krugler
Hi Tony, I'm wondering why you need to do this level of optimization - are you running into issues with this type of POST request chewing up too many CPU cycles, and/or not being able to send the request every 3ms because it's taking too long? -- Ken On Jan 9, 2010, at 10:29am, Tony

Re: Efficiently repeating identical requests

2010-01-09 Thread Tony Poppleton
Hi Ken, It is for a financial application where fewer milliseconds = more money.  I am trying to improve on the 3ms. Cheers, Tony Message du 09/01/10 21:03 De : Ken Krugler A : HttpClient User Discussion Copie à : Objet : Re: Efficiently repeating identical requests Hi Tony,

Javadoc for each release?

2010-01-09 Thread KARR, DAVID (ATTCINW)
I just downloaded the 4.0.1 release of HttpClient, and I noticed that it doesn't include a javadoc distribution. There's one available on the web site, but only for the 4.1 alpha release. Why isn't it in the distribution? - To

Re: Efficiently repeating identical requests

2010-01-09 Thread Ken Krugler
Hi Tony, I'm assuming you can't just use more threads to reduce the average inter-request delay, right? -- Ken On Jan 9, 2010, at 12:32pm, Tony Poppleton wrote: Hi Ken, It is for a financial application where fewer milliseconds = more money. I am trying to improve on the 3ms.

Re: Connections per host and redirects

2010-01-09 Thread Oleg Kalnichevski
Ken Krugler wrote: I wanted to verify some behavior I'm seeing with HttpClient 4.0 I occasionally get a ConnectionPoolTimeoutException, even when I've got spare connections in my ThreadSafeClientConnManager pool. Looking at the ConnPoolByRoute.getEntryBlocking() code, it appears this could

Re: Efficiently repeating identical requests

2010-01-09 Thread Oleg Kalnichevski
Tony Poppleton wrote: Hi, Further to the previous mail, I have already implemented my own AbstractHttpEntity to eliminate a byte[] copy. And I have seen the NIO implementations of HttpEntities, however they don't seem to copy using NIO methods so they won't be any faster than the standard

Re: Javadoc for each release?

2010-01-09 Thread Oleg Kalnichevski
KARR, DAVID (ATTCINW) wrote: I just downloaded the 4.0.1 release of HttpClient, and I noticed that it doesn't include a javadoc distribution. There's one available on the web site, but only for the 4.1 alpha release. Why isn't it in the distribution? My bad. It is an oversight on my part.

Re: Connections per host and redirects

2010-01-09 Thread Ken Krugler
Hi Oleg, On Jan 9, 2010, at 1:35pm, Oleg Kalnichevski wrote: Ken Krugler wrote: I wanted to verify some behavior I'm seeing with HttpClient 4.0 I occasionally get a ConnectionPoolTimeoutException, even when I've got spare connections in my ThreadSafeClientConnManager pool. Looking at the

Blocked threads during requests

2010-01-09 Thread Ken Krugler
[In the interest of not hijacking Tony's discussion thread, I'm putting this into a new email.] Tony Poppleton wrote: Hi, Further to the previous mail, I have already implemented my own AbstractHttpEntity to eliminate a byte[] copy. And I have seen the NIO implementations of

Re: Blocked threads during requests

2010-01-09 Thread sebb
On 09/01/2010, Ken Krugler kkrugler_li...@transpac.com wrote: [In the interest of not hijacking Tony's discussion thread, I'm putting this into a new email.] Tony Poppleton wrote: Hi, Further to the previous mail, I have already implemented my own AbstractHttpEntity to eliminate a