public class StatisticsHandler extends HandlerWrapper
AbstractLifeCycle.AbstractLifeCycleListener
LifeCycle.Listener
_handler
_listeners, FAILED, RUNNING, STARTED, STARTING, STOPPED, STOPPING
Constructor and Description |
---|
StatisticsHandler() |
Modifier and Type | Method and Description |
---|---|
protected void |
doStart()
Start the managed lifecycle beans in the order they were added.
|
int |
getDispatched() |
int |
getDispatchedActive() |
int |
getDispatchedActiveMax() |
long |
getDispatchedTimeMax() |
double |
getDispatchedTimeMean() |
double |
getDispatchedTimeStdDev() |
long |
getDispatchedTimeTotal() |
int |
getExpires() |
int |
getRequests() |
int |
getRequestsActive() |
int |
getRequestsActiveMax() |
long |
getRequestTimeMax() |
double |
getRequestTimeMean() |
double |
getRequestTimeStdDev() |
long |
getRequestTimeTotal() |
int |
getResponses1xx() |
int |
getResponses2xx() |
int |
getResponses3xx() |
int |
getResponses4xx() |
int |
getResponses5xx() |
long |
getResponsesBytesTotal() |
int |
getResumes() |
long |
getStatsOnMs() |
int |
getSuspends() |
int |
getSuspendsActive() |
int |
getSuspendsActiveMax() |
void |
handle(String path,
Request request,
javax.servlet.http.HttpServletRequest httpRequest,
javax.servlet.http.HttpServletResponse httpResponse)
Handle a request.
|
void |
statsReset()
Resets the current request statistics.
|
String |
toStatsHTML() |
destroy, doStop, expandChildren, getHandler, getHandlers, getNestedHandlerByClass, setHandler, setServer
dump, expandHandler, findContainerOf, getChildHandlerByClass, getChildHandlers, getChildHandlersByClass
dumpThis, getServer
addBean, addBean, contains, dump, dump, dump, dump, dumpObject, dumpStdErr, getBean, getBeans, getBeans, isManaged, manage, removeBean, removeBeans, unmanage
addLifeCycleListener, getState, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addLifeCycleListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop
public void statsReset()
public void handle(String path, Request request, javax.servlet.http.HttpServletRequest httpRequest, javax.servlet.http.HttpServletResponse httpResponse) throws IOException, javax.servlet.ServletException
Handler
handle
in interface Handler
handle
in class HandlerWrapper
path
- The target of the request - either a URI or a name.request
- The original unwrapped request object.httpRequest
- The request either as the Request
object or a wrapper of that request. The AbstractHttpConnection.getCurrentConnection()
method can be used access the Request object if required.httpResponse
- The response as the Response
object or a wrapper of that request. The AbstractHttpConnection.getCurrentConnection()
method can be used access the Response object if required.IOException
javax.servlet.ServletException
protected void doStart() throws Exception
AggregateLifeCycle
doStart
in class HandlerWrapper
Exception
AbstractLifeCycle.doStart()
public int getRequests()
statsReset()
was last called, excluding
active requestsgetResumes()
public int getRequestsActive()
statsReset()
was last called.public int getRequestsActiveMax()
statsReset()
was last called.public long getRequestTimeMax()
statsReset()
was last called.public long getRequestTimeTotal()
statsReset()
was last called.public double getRequestTimeMean()
statsReset()
was last called.getRequestTimeTotal()
,
getRequests()
public double getRequestTimeStdDev()
statsReset()
was last called.getRequestTimeTotal()
,
getRequests()
public int getDispatched()
statsReset()
was last called, excluding
active dispatchespublic int getDispatchedActive()
statsReset()
was last called, including
resumed requestspublic int getDispatchedActiveMax()
statsReset()
was last called, including
resumed requestspublic long getDispatchedTimeMax()
statsReset()
was last called.public long getDispatchedTimeTotal()
statsReset()
was last called.public double getDispatchedTimeMean()
statsReset()
was last called.getRequestTimeTotal()
,
getRequests()
public double getDispatchedTimeStdDev()
statsReset()
was last called.getRequestTimeTotal()
,
getRequests()
public int getSuspends()
statsReset()
was last called, including
resumed requestsgetResumes()
public int getSuspendsActive()
statsReset()
was last called.public int getSuspendsActiveMax()
statsReset()
was last called.public int getResumes()
getExpires()
public int getExpires()
getResumes()
public int getResponses1xx()
statsReset()
was last called.public int getResponses2xx()
statsReset()
was last called.public int getResponses3xx()
statsReset()
was last called.public int getResponses4xx()
statsReset()
was last called.public int getResponses5xx()
statsReset()
was last called.public long getStatsOnMs()
statsReset()
.public long getResponsesBytesTotal()
public String toStatsHTML()
Copyright © 1995-2013 Mort Bay Consulting. All Rights Reserved.