Package org.wicketstuff.datastores.redis
Class RedisDataStore
java.lang.Object
org.apache.wicket.pageStore.AbstractPersistentPageStore
org.wicketstuff.datastores.redis.RedisDataStore
- All Implemented Interfaces:
IPageStore,IPersistentPageStore
An IPageStore that saves serialized pages in Redis.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.wicket.pageStore.AbstractPersistentPageStore
AbstractPersistentPageStore.PersistedPage -
Constructor Summary
ConstructorsConstructorDescriptionRedisDataStore(String applicationname, IRedisSettings settings) Constructor.RedisDataStore(String applicationname, redis.clients.jedis.JedisPool pool, IRedisSettings settings) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddPersistedPage(String sessionIdentifier, IManageablePage page) voiddestroy()protected IManageablePagegetPersistedPage(String sessionIdentifier, int id) getPersistedPages(String sessionIdentifier) protected voidremoveAllPersistedPages(String sessionIdentifier) protected voidremovePersistedPage(String sessionIdentifier, IManageablePage page) booleanMethods inherited from class org.apache.wicket.pageStore.AbstractPersistentPageStore
addPage, canBeAsynchronous, createSessionIdentifier, getPage, getSessionIdentifier, removeAllPages, removePageMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.wicket.pageStore.IPageStore
addPage, canBeAsynchronous, detach, end, getPage, removeAllPages, removePage, revertPageMethods inherited from interface org.apache.wicket.pageStore.IPersistentPageStore
getSessionIdentifier
-
Constructor Details
-
RedisDataStore
Constructor. Creates a connection pool by using the hostname and port from the provided settings- Parameters:
settings- The various settings
-
RedisDataStore
public RedisDataStore(String applicationname, redis.clients.jedis.JedisPool pool, IRedisSettings settings) Constructor.- Parameters:
pool- The pool with Jedis connectionssettings- The various settings
-
-
Method Details
-
supportsVersioning
public boolean supportsVersioning()- Specified by:
supportsVersioningin interfaceIPageStore
-
getPersistedPage
- Specified by:
getPersistedPagein classAbstractPersistentPageStore
-
removePersistedPage
- Specified by:
removePersistedPagein classAbstractPersistentPageStore
-
removeAllPersistedPages
- Specified by:
removeAllPersistedPagesin classAbstractPersistentPageStore
-
addPersistedPage
- Specified by:
addPersistedPagein classAbstractPersistentPageStore
-
destroy
public void destroy()- Specified by:
destroyin interfaceIPageStore- Overrides:
destroyin classAbstractPersistentPageStore
-
getSessionIdentifiers
- Specified by:
getSessionIdentifiersin interfaceIPersistentPageStore
-
getPersistedPages
- Specified by:
getPersistedPagesin interfaceIPersistentPageStore
-
getTotalSize
- Specified by:
getTotalSizein interfaceIPersistentPageStore
-