Lifecycle.SingleUseconnectionName, connectionPassword, connectionURL, dataSource, dataSourceName, driver, driverName, preparedClearSql, preparedLoadSql, preparedRemoveSql, preparedSaveSql, preparedSizeSql, sessionAppCol, sessionDataCol, sessionIdCol, sessionLastAccessedCol, sessionMaxInactiveCol, sessionTable, sessionValidCol, storeName, threadNameAFTER_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| Constructor and Description |
|---|
DataSourceStore() |
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Remove all of the Sessions in this Store.
|
protected void |
close(Connection dbConnection)
Close the specified database connection.
|
String[] |
expiredKeys()
Get only those keys of sessions, that are saved in the Store and are to
be expired.
|
int |
getSize()
Return an integer containing a count of all Sessions
currently saved in this Store.
|
String[] |
keys() |
Session |
load(String id)
Load the Session associated with the id
id. |
protected Connection |
open()
Open (if necessary) and return a database connection for use by
this Store.
|
void |
remove(String id)
Remove the Session with the specified session identifier from
this Store, if present.
|
void |
save(Session session)
Save a session to the Store.
|
getConnection, getConnectionName, getConnectionPassword, getConnectionURL, getDataSourceName, getDriverName, getLocalDataSource, getName, getSessionAppCol, getSessionDataCol, getSessionIdCol, getSessionLastAccessedCol, getSessionMaxInactiveCol, getSessionTable, getSessionValidCol, getStoreName, getThreadName, release, setConnectionName, setConnectionPassword, setConnectionURL, setDataSourceName, setDriverName, setLocalDataSource, setSessionAppCol, setSessionDataCol, setSessionIdCol, setSessionLastAccessedCol, setSessionMaxInactiveCol, setSessionTable, setSessionValidCol, startInternal, stopInternaladdPropertyChangeListener, destroyInternal, getManager, getObjectInputStream, initInternal, processExpires, removePropertyChangeListener, setManager, toStringaddLifecycleListener, destroy, findLifecycleListeners, fireLifecycleEvent, getState, getStateName, getThrowOnFailure, init, removeLifecycleListener, setState, setState, setThrowOnFailure, start, stoppublic String[] expiredKeys() throws IOException
StoreBaseexpiredKeys in class JDBCStoreIOException - if an input-/output error occurredpublic String[] keys() throws IOException
keys in interface Storekeys in class JDBCStoreIOException - if an input/output error occurredpublic int getSize()
throws IOException
0 is returned.getSize in interface StoregetSize in class JDBCStoreIOException - if an input/output error occurredpublic Session load(String id) throws ClassNotFoundException, IOException
id.
If no such session is found null is returned.load in interface Storeload in class JDBCStoreid - a value of type StringSessionClassNotFoundException - if an error occursIOException - if an input/output error occurredpublic void remove(String id) throws IOException
remove in interface Storeremove in class JDBCStoreid - Session identifier of the Session to be removedIOException - if an input/output error occurspublic void clear()
throws IOException
clear in interface Storeclear in class JDBCStoreIOException - if an input/output error occurspublic void save(Session session) throws IOException
save in interface Storesave in class JDBCStoresession - the session to be storedIOException - if an input/output error occursprotected Connection open() throws SQLException
open in class JDBCStoreSQLException - if a database error occursprotected void close(Connection dbConnection)
Copyright © 2000-2021 Apache Software Foundation. All Rights Reserved.