public class TestSessionDataStore extends AbstractSessionDataStore
AbstractLifeCycle.AbstractLifeCycleListener
LifeCycle.Listener
Container.InheritedListener, Container.Listener
Modifier and Type | Field and Description |
---|---|
java.util.Map<java.lang.String,SessionData> |
_map |
boolean |
_passivating |
_context, _gracePeriodSec, _lastExpiryCheckTime, _savePeriodSec
FAILED, RUNNING, STARTED, STARTING, STOP_ON_FAILURE, STOPPED, STOPPING
Constructor and Description |
---|
TestSessionDataStore() |
TestSessionDataStore(boolean passivating) |
Modifier and Type | Method and Description |
---|---|
boolean |
delete(java.lang.String id)
Delete session data
|
java.util.Set<java.lang.String> |
doGetExpired(java.util.Set<java.lang.String> candidates)
Implemented by subclasses to resolve which sessions this node
should attempt to expire.
|
void |
doStore(java.lang.String id,
SessionData data,
long lastSaveTime)
Store the session data persistently.
|
boolean |
exists(java.lang.String id)
Test if data exists for a given session id.
|
boolean |
isPassivating()
True if this type of datastore will passivate session objects
|
SessionData |
load(java.lang.String id)
Read in session data.
|
checkStarted, doStart, getExpired, getGracePeriodSec, getSavePeriodSec, initialize, newSessionData, setGracePeriodSec, setSavePeriodSec, store, toString
addBean, addBean, addBean, addEventListener, addManaged, contains, destroy, doStop, dump, dump, dump, dump, dump, dumpBeans, dumpObject, dumpStdErr, dumpThis, getBean, getBeans, getBeans, getContainedBeans, getContainedBeans, isManaged, manage, removeBean, removeBeans, removeEventListener, setBeans, setStopTimeout, start, stop, unmanage, updateBean, updateBean, updateBeans
addLifeCycleListener, getState, getState, getStopTimeout, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addLifeCycleListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, start, stop, stop
public java.util.Map<java.lang.String,SessionData> _map
public boolean _passivating
public TestSessionDataStore()
public TestSessionDataStore(boolean passivating)
public boolean isPassivating()
SessionDataStore
public boolean exists(java.lang.String id) throws java.lang.Exception
SessionDataStore
id
- Identity of session whose existence should be checkedjava.lang.Exception
- if problem checking existence with persistence layerpublic SessionData load(java.lang.String id) throws java.lang.Exception
SessionDataMap
id
- identity of session to loadjava.lang.Exception
- if unable to load session datapublic boolean delete(java.lang.String id) throws java.lang.Exception
SessionDataMap
id
- identity of session to deletejava.lang.Exception
- if unable to delete session datapublic void doStore(java.lang.String id, SessionData data, long lastSaveTime) throws java.lang.Exception
AbstractSessionDataStore
doStore
in class AbstractSessionDataStore
id
- identity of session to storedata
- info of the sessionlastSaveTime
- time of previous save or 0 if never savedjava.lang.Exception
- if unable to store datapublic java.util.Set<java.lang.String> doGetExpired(java.util.Set<java.lang.String> candidates)
AbstractSessionDataStore
doGetExpired
in class AbstractSessionDataStore
candidates
- the ids of sessions the SessionDataStore thinks has expiredCopyright © 1995–2019 Webtide. All rights reserved.