Hi Folks,
In my Java application, the application is sending HTTP + SOAP request
to JBoss server. My observation is that for the very first request for
obtaining OutputStream object, application takes much time. And the
subsequent requests from the application does not take time for
obtaining the OutputStream object.
###########################################################
HttpURLConnection httpConn = (HttpURLConnection) serviceURL
.openConnection();
-------
-------
-------
OutputStream out = httpConn.getOutputStream();
#####################################################
Is there any reason behind this? Please let me know.
Regards,
Deepak
Matt Humphrey - 01 Jun 2006 19:30 GMT
> Hi Folks,
>
[quoted text clipped - 15 lines]
>
> Is there any reason behind this? Please let me know.
There are so many reasons for this that the standard advice for evaluating
performance is to be sure to ignore the first few requests. The first time
JBoss encounters the request it must load the servlet classes and initialize
the servlet. This only ever happens once. For JSP pages, the page must be
compiled and then loaded. There are usually lots of classes that have to be
brought in for the first request, so all this is normal. Focus instead on
the performance of later requests.
Cheers,
Matt Humphrey matth@ivizNOSPAM.com http://www.iviz.com/