Package org.eclipse.jetty.server.session
Class TestServer
- java.lang.Object
-
- org.eclipse.jetty.server.session.TestServer
-
public class TestServer extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description protected static int__workersprotected SessionCacheFactory_cacheFactoryprotected java.lang.Object_configprotected ContextHandlerCollection_contextsprotected int_maxInactivePeriodprotected int_scavengePeriodprotected Server_serverprotected SessionIdManager_sessionIdManagerprotected SessionDataStoreFactory_storeFactorystatic intDEFAULT_EVICTIONPOLICYstatic intDEFAULT_MAX_INACTIVEstatic intDEFAULT_SCAVENGE_SEC
-
Constructor Summary
Constructors Constructor Description TestServer(int port, int maxInactivePeriod, int scavengePeriod, SessionCacheFactory cacheFactory, SessionDataStoreFactory storeFactory)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ServletContextHandleraddContext(java.lang.String contextPath)WebAppContextaddWebAppContext(java.lang.String warPath, java.lang.String contextPath)static java.lang.StringextractSessionId(java.lang.String sessionCookie)HouseKeepergetHouseKeeper()intgetPort()ServergetServer()ServerConnectorgetServerConnector()SessionHandlernewSessionHandler()SessionIdManagernewSessionIdManager()voidstart()voidstop()
-
-
-
Field Detail
-
DEFAULT_MAX_INACTIVE
public static int DEFAULT_MAX_INACTIVE
-
DEFAULT_SCAVENGE_SEC
public static int DEFAULT_SCAVENGE_SEC
-
DEFAULT_EVICTIONPOLICY
public static int DEFAULT_EVICTIONPOLICY
-
__workers
protected static int __workers
-
_server
protected final Server _server
-
_maxInactivePeriod
protected final int _maxInactivePeriod
-
_scavengePeriod
protected final int _scavengePeriod
-
_contexts
protected final ContextHandlerCollection _contexts
-
_sessionIdManager
protected SessionIdManager _sessionIdManager
-
_config
protected java.lang.Object _config
-
_cacheFactory
protected SessionCacheFactory _cacheFactory
-
_storeFactory
protected SessionDataStoreFactory _storeFactory
-
-
Constructor Detail
-
TestServer
public TestServer(int port, int maxInactivePeriod, int scavengePeriod, SessionCacheFactory cacheFactory, SessionDataStoreFactory storeFactory) throws java.lang.Exception- Throws:
java.lang.Exception
-
-
Method Detail
-
extractSessionId
public static java.lang.String extractSessionId(java.lang.String sessionCookie)
-
newSessionIdManager
public SessionIdManager newSessionIdManager()
-
newSessionHandler
public SessionHandler newSessionHandler() throws java.lang.Exception
- Throws:
java.lang.Exception
-
getServerConnector
public ServerConnector getServerConnector()
-
start
public void start() throws java.lang.Exception- Throws:
java.lang.Exception
-
getHouseKeeper
public HouseKeeper getHouseKeeper()
-
getPort
public int getPort()
-
addContext
public ServletContextHandler addContext(java.lang.String contextPath) throws java.lang.Exception
- Throws:
java.lang.Exception
-
stop
public void stop() throws java.lang.Exception- Throws:
java.lang.Exception
-
addWebAppContext
public WebAppContext addWebAppContext(java.lang.String warPath, java.lang.String contextPath) throws java.lang.Exception
- Throws:
java.lang.Exception
-
getServer
public Server getServer()
-
-