| Author |
how to get the server processing time
|
madhu gadde
Greenhorn
Joined: May 27, 2005
Posts: 11
|
|
Hi all, I need to know how long the server/servlet has taken to process a particular request. Could anybody help me in finding the servlet's processing time. Thanks in Advance Madhu Gadde
|
 |
Satish Chilukuri
Ranch Hand
Joined: Jun 23, 2005
Posts: 266
|
|
|
Have a filter intercept the Request. Note the time before and after invoking the doFilter method. The difference will give you the processing time for the request. But this won't include the network delay.
|
 |
John Dunn
slicker
Ranch Hand
Joined: Jan 30, 2003
Posts: 1108
|
|
put this in doGet(): long appStartTime = System.currentTimeInMillis(); Now any time you want a time marker you subtract appStartTime from System.currentTimeInMillis(); I get one buffer at start of doGet(), put log messages in along the way with an elapsed time and print once at the end. This way I can filter the log file for specific log points and get the elapsed time.
|
"No one appreciates the very special genius of your conversation as the dog does."
|
 |
 |
|
|
subject: how to get the server processing time
|
|
|