> As Odi pointed out, you can save the overhead of establishing
> a new connection for each request. How much that is depends
> on your infrastructure: network latency, authentication overhead,...

I've recently been doing some profiling work and was surprised to discover
that instantiating HttpClient is actually a reasonably expensive operation.
As a result, I'd say you'd probably get just as much of a speed up from not
having to instantiate a new HttpClient each time as you would from the
connection pooling.

I would absolutely recommend making the code changes to use a single
HttpClient instance - it's really not that difficult anyway.  We actually
make ours a static instance that's shared across the JVM as much as
possible.

Regards,

Adrian Sutton.

----------------------------------------------
Intencha "tomorrow's technology today"
Ph: 38478913 0422236329
Suite 8/29 Oatland Crescent
Holland Park West 4121
Australia QLD
www.intencha.com


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to