javax.management.MBeanRegistration
, Contained
, JmxEnabled
, Lifecycle
, Valve
public class PersistentValve extends ValveBase
USAGE CONSTRAINT: To work correctly it requires a PersistentManager.
USAGE CONSTRAINT: To work correctly it assumes only one request exists per session at any one time.
Lifecycle.SingleUse
AFTER_DESTROY_EVENT, AFTER_INIT_EVENT, AFTER_START_EVENT, AFTER_STOP_EVENT, BEFORE_DESTROY_EVENT, BEFORE_INIT_EVENT, BEFORE_START_EVENT, BEFORE_STOP_EVENT, CONFIGURE_START_EVENT, CONFIGURE_STOP_EVENT, PERIODIC_EVENT, START_EVENT, STOP_EVENT
mserver
asyncSupported, container, containerLog, next, sm
Constructor | Description |
---|---|
PersistentValve() |
Modifier and Type | Method | Description |
---|---|---|
void |
invoke(Request request,
Response response) |
Select the appropriate child Context to process this request,
based on the specified request URI.
|
protected boolean |
isSessionStale(Session session,
long timeNow) |
Indicate whether the session has been idle for longer
than its expiration date as of the supplied time.
|
void |
setContainer(Container container) |
Set the Container with which this Valve is associated, if any.
|
addLifecycleListener, destroy, findLifecycleListeners, fireLifecycleEvent, getState, getStateName, getThrowOnFailure, init, removeLifecycleListener, setState, setState, setThrowOnFailure, start, stop
destroyInternal, getDomain, getObjectName, postDeregister, postRegister, preDeregister, preRegister, register, setDomain, unregister
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
backgroundProcess, getContainer, getDomainInternal, getNext, getObjectNameKeyProperties, initInternal, isAsyncSupported, setAsyncSupported, setNext, startInternal, stopInternal, toString
public void setContainer(Container container)
ValveBase
setContainer
in interface Contained
setContainer
in class ValveBase
container
- The new associated containerpublic void invoke(Request request, Response response) throws java.io.IOException, ServletException
request
- Request to be processedresponse
- Response to be producedjava.io.IOException
- if an input/output error occurredServletException
- if a servlet error occurredprotected boolean isSessionStale(Session session, long timeNow)
session
- The session to checktimeNow
- The current time to check fortrue
if the session is past its expirationCopyright © 2000-2019 Apache Software Foundation. All Rights Reserved.