public abstract class AbstractSessionIdManager extends AbstractLifeCycle implements SessionIdManager
AbstractLifeCycle.AbstractLifeCycleListenerLifeCycle.Listener| Modifier and Type | Field and Description |
|---|---|
protected Random |
_random |
protected long |
_reseed |
protected boolean |
_weakRandom |
protected String |
_workerName |
_listeners, FAILED, RUNNING, STARTED, STARTING, STOPPED, STOPPING| Constructor and Description |
|---|
AbstractSessionIdManager() |
AbstractSessionIdManager(Random random) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
doStart() |
protected void |
doStop() |
Random |
getRandom() |
long |
getReseed() |
String |
getWorkerName()
Get the workname.
|
void |
initRandom()
Set up a random number generator for the sessionids.
|
String |
newSessionId(javax.servlet.http.HttpServletRequest request,
long created)
Create a new session id if necessary.
|
void |
setRandom(Random random) |
void |
setReseed(long reseed)
Set the reseed probability.
|
void |
setWorkerName(String workerName)
Set the workname.
|
addLifeCycleListener, getState, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stopclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddSession, getClusterId, getNodeId, idInUse, invalidateAll, removeSessionaddLifeCycleListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stopprotected Random _random
protected boolean _weakRandom
protected String _workerName
protected long _reseed
public AbstractSessionIdManager()
public AbstractSessionIdManager(Random random)
public long getReseed()
public void setReseed(long reseed)
reseed - If non zero then when a random long modulo the reseed value == 1, the SecureRandom will be reseeded.public String getWorkerName()
getWorkerName in interface SessionIdManagerpublic void setWorkerName(String workerName)
workerName - public Random getRandom()
public void setRandom(Random random)
public String newSessionId(javax.servlet.http.HttpServletRequest request, long created)
newSessionId in interface SessionIdManagerSessionIdManager.newSessionId(javax.servlet.http.HttpServletRequest, long)protected void doStart()
throws Exception
doStart in class AbstractLifeCycleExceptionprotected void doStop()
throws Exception
doStop in class AbstractLifeCycleExceptionpublic void initRandom()
Copyright © 1995-2013 Mort Bay Consulting. All Rights Reserved.