Package org.apache.catalina.valves
Class PersistentValve
- java.lang.Object
-
- org.apache.catalina.valves.ValveBase
-
- org.apache.catalina.valves.PersistentValve
-
- All Implemented Interfaces:
Contained
,Lifecycle
,Valve
,GlassFishValve
public class PersistentValve extends ValveBase
Valve that implements the default basic behavior for theStandardHost
container implementation.USAGE CONSTRAINT: To work correctly it requires a PersistentManager.
- Version:
- $Revision: 1.2 $ $Date: 2005/12/08 01:28:24 $
- Author:
- Jean-Frederic Clere
-
-
Field Summary
-
Fields inherited from class org.apache.catalina.valves.ValveBase
container, controller, debug, domain, lifecycle, log, next, oname, rb, started
-
Fields inherited from interface org.glassfish.web.valve.GlassFishValve
END_PIPELINE, INVOKE_NEXT
-
Fields inherited from interface org.apache.catalina.Lifecycle
AFTER_START_EVENT, AFTER_STOP_EVENT, BEFORE_START_EVENT, BEFORE_STOP_EVENT, INIT_EVENT, START_EVENT, STOP_EVENT
-
-
Constructor Summary
Constructors Constructor Description PersistentValve()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getInfo()
Return descriptive information about this Valve implementation.int
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.protected void
log(String message)
Log a message on the Logger associated with our Container (if any).void
postInvoke(Request request, Response response)
A post-request processing implementation that does nothing.-
Methods inherited from class org.apache.catalina.valves.ValveBase
addLifecycleListener, backgroundProcess, createObjectName, event, findLifecycleListeners, getContainer, getController, getDebug, getDomain, getNext, getObjectName, getParentName, invoke, isStarted, removeLifecycleListener, setContainer, setController, setDebug, setNext, setObjectName, start, stop
-
-
-
-
Method Detail
-
getInfo
public String getInfo()
Return descriptive information about this Valve implementation.
-
invoke
public int invoke(Request request, Response response) throws IOException, jakarta.servlet.ServletException
Select the appropriate child Context to process this request, based on the specified request URI. If no matching Context can be found, return an appropriate HTTP error.- Specified by:
invoke
in interfaceGlassFishValve
- Specified by:
invoke
in classValveBase
- Parameters:
request
- Request to be processedresponse
- Response to be produced- Returns:
INVOKE_NEXT
orEND_PIPELINE
- Throws:
IOException
- if an input/output error occurredjakarta.servlet.ServletException
- if a servlet error occurred
-
postInvoke
public void postInvoke(Request request, Response response) throws IOException, jakarta.servlet.ServletException
Description copied from class:ValveBase
A post-request processing implementation that does nothing. Very few Valves override this behaviour as most Valve logic is used for request processing.- Specified by:
postInvoke
in interfaceGlassFishValve
- Overrides:
postInvoke
in classValveBase
- Parameters:
request
- The servlet request to be processedresponse
- The servlet response to be created- Throws:
IOException
- if an input/output error occursjakarta.servlet.ServletException
- if a servlet error occurs
-
log
protected void log(String message)
Log a message on the Logger associated with our Container (if any).- Parameters:
message
- Message to be logged
-
isSessionStale
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. FIXME: Probably belongs in the Session class.
-
-