Re: question about performance

2004-04-13 Thread Ortwin Glück
Alvarez, Gil wrote: After the port, we saw a significant increase in cycles used by the machines, about 2-3 times (ie, the load on the boxes increased from using up 20% of the cpu, to about 50%-60% of the cpu. Besides the hints already given, you should profile your application to find out wher

RE: question about performance

2004-04-09 Thread Oleg Kalnichevski
rker thread. Just make sure you reuse HttpClient instances that may already have a connection to the target host open. Do not let it get GCed Oleg > -Original Message- > From: Oleg Kalnichevski [mailto:[EMAIL PROTECTED] > Sent: Friday, April 09, 2004 6:58 AM > To: Commons HttpClien

RE: question about performance

2004-04-09 Thread Alvarez, Gil
, April 09, 2004 6:58 AM To: Commons HttpClient Project Subject: RE: question about performance Gil, The problem is that until Java 1.4 there has simply been no way to ensure connection timeout. HttpClient only 'mimics' connect timeout at the expense of having a controller thread watch over t

RE: question about performance

2004-04-09 Thread Oleg Kalnichevski
e- > From: Oleg Kalnichevski [mailto:[EMAIL PROTECTED] > Sent: Thursday, April 08, 2004 1:20 PM > To: Commons HttpClient Project > Subject: RE: question about performance > > Gil, > HttpClient#getHost / HttpClient#getPort return the DEFAULT host and port > used when

RE: question about performance

2004-04-09 Thread Alvarez, Gil
a timeout per request? -Original Message- From: Oleg Kalnichevski [mailto:[EMAIL PROTECTED] Sent: Thursday, April 08, 2004 1:20 PM To: Commons HttpClient Project Subject: RE: question about performance Gil, HttpClient#getHost / HttpClient#getPort return the DEFAULT host and port used

RE: question about performance

2004-04-08 Thread Oleg Kalnichevski
2004 12:23 PM > To: Commons HttpClient Project > Subject: Re: question about performance > > Gil, > (1) First and foremost DO reuse HttpClient instances when using > multi-threaded connection manager. HttpClient class is thread-safe. In > fact there are no known problems with

RE: question about performance

2004-04-08 Thread Alvarez, Gil
tHost(), what's going to happen? -Original Message- From: Oleg Kalnichevski [mailto:[EMAIL PROTECTED] Sent: Thursday, April 08, 2004 12:23 PM To: Commons HttpClient Project Subject: Re: question about performance Gil, (1) First and foremost DO reuse HttpClient instances when using mult

Re: question about performance

2004-04-08 Thread Sam Berlin
It's not a big issue for us right now ... but when we start using HttpClient more heavily it'll become important. Just throwing the idea out there for now in case anyone else wants to do the patch. :) Thanks, Sam On Thursday, April 8, 2004, at 03:34 PM, Oleg Kalnichevski wrote: It's on my v

Re: question about performance

2004-04-08 Thread Oleg Kalnichevski
It's on my virtual 'to-do' list (along with many other things [Sigh]). Feel free to file a bug report and attach a patch against CVS HEAD, though. Oleg On Thu, 2004-04-08 at 21:29, Sam Berlin wrote: > Regarding point 4, it might be worthwhile to use reflection on newer > JVMs so that the contro

Re: question about performance

2004-04-08 Thread Sam Berlin
Regarding point 4, it might be worthwhile to use reflection on newer JVMs so that the controller thread isn't necessary. An example of this is: //a) Conceptually, this code does the following: // SocketAddress addr=new InetSocketAddress(host, port); //

Re: question about performance

2004-04-08 Thread Oleg Kalnichevski
Gil, (1) First and foremost DO reuse HttpClient instances when using multi-threaded connection manager. HttpClient class is thread-safe. In fact there are no known problems with having just one instance of HttpClient per application. Using a new instance of HttpClient for processing each request to