public abstract class UpgradeProcessorBase extends AbstractProcessorLight implements WebConnection
| Modifier and Type | Field and Description |
|---|---|
protected static int |
INFINITE_TIMEOUT |
| Constructor and Description |
|---|
UpgradeProcessorBase(UpgradeToken upgradeToken) |
| Modifier and Type | Method and Description |
|---|---|
AbstractEndpoint.Handler.SocketState |
asyncPostProcess() |
boolean |
checkAsyncTimeoutGeneration()
Check to see if the async generation (each cycle of async increments the generation of the AsyncStateMachine) is
the same as the generation when the most recent async timeout was triggered.
|
java.nio.ByteBuffer |
getLeftoverInput()
Allows retrieving additional input during the upgrade process.
|
Request |
getRequest() |
UpgradeToken |
getUpgradeToken()
Generate an upgrade token.
|
boolean |
isAsync() |
boolean |
isUpgrade() |
void |
recycle()
Recycle the processor, ready for the next request which may be on the same connection or a different connection.
|
AbstractEndpoint.Handler.SocketState |
service(SocketWrapperBase<?> socketWrapper)
Service a 'standard' HTTP request.
|
void |
timeoutAsync(long now)
Check this processor to see if the timeout has expired and process a timeout if that is that case.
|
addDispatch, clearDispatches, dispatch, getIteratorAndClearDispatches, getLog, logAccess, processclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetInputStream, getOutputStreampause, setSslSupportprotected static final int INFINITE_TIMEOUT
public UpgradeProcessorBase(UpgradeToken upgradeToken)
public final boolean isUpgrade()
public UpgradeToken getUpgradeToken()
ProcessorgetUpgradeToken in interface Processorpublic final void recycle()
Processorpublic final AbstractEndpoint.Handler.SocketState service(SocketWrapperBase<?> socketWrapper) throws java.io.IOException
AbstractProcessorLightAbstractProcessorLight.dispatch(SocketEvent). Requests may be pipe-lined.service in class AbstractProcessorLightsocketWrapper - The connection to processjava.io.IOException - If an I/O error occurs during the processing of the requestpublic final AbstractEndpoint.Handler.SocketState asyncPostProcess()
asyncPostProcess in class AbstractProcessorLightpublic final Request getRequest()
getRequest in interface Processorpublic java.nio.ByteBuffer getLeftoverInput()
ProcessorgetLeftoverInput in interface Processorpublic boolean checkAsyncTimeoutGeneration()
ProcessorcheckAsyncTimeoutGeneration in interface Processortrue If the async generation has not changed since the async timeout was triggeredpublic void timeoutAsync(long now)
ProcessorNote: The name of this method originated with the Servlet 3.0 asynchronous processing but evolved over time to represent a timeout that is triggered independently of the socket read/write timeouts.
timeoutAsync in interface Processornow - The time (as returned by System.currentTimeMillis() to use as the current time to determine
whether the timeout has expired. If negative, the timeout will always be treated as ifq it has
expired.Copyright © 2000-2024 Apache Software Foundation.
Apache Tomcat, Tomcat, Apache, the Apache Tomcat logo and the Apache logo are either registered trademarks or trademarks of the Apache Software Foundation.