setBytesSent(0); setBytesReceived(0); setProcessingTime(0); setMaxTime(0); setMaxRequestUri(null); setRequestCount(0); setErrorCount(0); setCount2xx(0); setCount3xx(0); setCount4xx(0); setCount5xx(0); setCountOther(0); setCount200(0); setCount302(0); setCount304(0); setCount400(0); setCount401(0); setCount403(0); setCount404(0); setCount503(0); setWorkerThreadID(0); setRequestCompletionTime(0);
public synchronized void removeRequestProcessor( RequestInfo rp ) { if( rp != null ) { if( deadMaxTime < rp.getMaxTime() ) deadMaxTime = rp.getMaxTime(); deadProcessingTime += rp.getProcessingTime(); deadRequestCount += rp.getRequestCount(); deadErrorCount += rp.getErrorCount(); deadBytesReceived += rp.getBytesReceived(); deadBytesSent += rp.getBytesSent(); // START S1AS deadCount2xx += rp.getCount2xx(); deadCount3xx += rp.getCount3xx(); deadCount4xx += rp.getCount4xx(); deadCount5xx += rp.getCount5xx(); deadCountOther += rp.getCountOther(); deadCount200 += rp.getCount200(); deadCount302 += rp.getCount302(); deadCount304 += rp.getCount304(); deadCount400 += rp.getCount400(); deadCount401 += rp.getCount401(); deadCount403 += rp.getCount403(); deadCount404 += rp.getCount404(); deadCount503 += rp.getCount503(); // END S1AS processors.remove( rp ); } }
/** * Post process the http request, after the response has been * commited. */ public void postProcess(InputStream input, OutputStream output) throws Exception { if (!recycle){ started = false; inputBuffer = null; outputBuffer = null; response = null; if (isMonitoringEnabled()) { request.getRequestProcessor().setWorkerThreadID(0); } request = null; } else { inputBuffer.recycle(); outputBuffer.recycle(); } // Recycle ssl info sslSupport = null; if (error){ keepAlive = false; connectionHeaderValueSet = false; } }
request.getRequestProcessor().setRequestCompletionTime(0);
public synchronized long getCount2xx() { long ret = deadCount2xx; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount2xx(); } return ret; }
public synchronized long getBytesReceived() { long bytes=deadBytesReceived; for( int i=0; i<processors.size(); i++ ) { RequestInfo rp = processors.get( i ); bytes += rp.getBytesReceived(); } return bytes; }
public synchronized long getCount3xx() { long ret = deadCount3xx; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount3xx(); } return ret; }
public synchronized long getCount400() { long ret = deadCount400; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount400(); } return ret; }
public synchronized long getCount302() { long ret = deadCount302; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount302(); } return ret; }
public synchronized long getCount304() { long ret = deadCount304; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount304(); } return ret; }
public synchronized long getCount200() { long ret = deadCount200; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount200(); } return ret; }
public synchronized long getBytesSent() { long bytes=deadBytesSent; for( int i=0; i<processors.size(); i++ ) { RequestInfo rp = processors.get( i ); bytes += rp.getBytesSent(); } return bytes; }
/** * Prepare this object before parsing the request. */ protected void configPreProcess() throws Exception { if(selectorThread.isMonitoringEnabled() && !hasRequestInfoRegistered ) { registerMonitoring(); } else if (!selectorThread.isMonitoringEnabled() && hasRequestInfoRegistered) { unregisterMonitoring(); } if (selectorThread.isMonitoringEnabled()) { requestInfo = request.getRequestProcessor(); requestInfo.setWorkerThreadID(Thread.currentThread().getId()); } if (request.getServerPort() == 0) { request.setServerPort(selectorThread.getPort()); } }
request.getRequestProcessor().setRequestCompletionTime(0);
public synchronized long getCount2xx() { long ret = deadCount2xx; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount2xx(); } return ret; }
public synchronized long getBytesReceived() { long bytes=deadBytesReceived; for( int i=0; i<processors.size(); i++ ) { RequestInfo rp = processors.get( i ); bytes += rp.getBytesReceived(); } return bytes; }
public synchronized long getCount3xx() { long ret = deadCount3xx; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount3xx(); } return ret; }
public synchronized long getCount400() { long ret = deadCount400; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount400(); } return ret; }
public synchronized long getCount302() { long ret = deadCount302; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount302(); } return ret; }
public synchronized long getCount304() { long ret = deadCount304; for (int i=0; i<processors.size(); i++) { RequestInfo rp = processors.get(i); ret += rp.getCount304(); } return ret; }