public class PerSessionPageStore extends AbstractCachingPageStore<IManageablePage>
cacheSize constructor
parameter multiplied by the number of the active http sessions.
It depends on the application use cases but usually a reasonable value of
cacheSize would be just a few pages (2-3). If the application don't expect many
active http sessions and the work flow involves usage of the browser/application history
then the cacheSize value may be increased to a bigger value.| Modifier and Type | Class and Description |
|---|---|
protected static class |
PerSessionPageStore.PagesCache
An implementation of SecondLevelPageCache that stores the last used N live page instances
per http session.
|
pagesCachedataStore, pageSerializer| Constructor and Description |
|---|
PerSessionPageStore(ISerializer pageSerializer,
IDataStore dataStore,
int cacheSize)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
IManageablePage |
convertToPage(Object object)
Converts a page representation to an instance of
IManageablePage |
destroy, getPage, removePage, storePage, unbinddeserializePage, getPageData, prepareForSerialization, removePageData, removePageData, restoreAfterSerialization, serializePage, storePageDatapublic PerSessionPageStore(ISerializer pageSerializer, IDataStore dataStore, int cacheSize)
pageSerializer - the ISerializer that will be used to convert pages from/to byte arraysdataStore - the IDataStore that actually stores the pagescacheSize - the number of pages to cache in memory before passing them to
IDataStore.storeData(String, int, byte[])public IManageablePage convertToPage(Object object)
IPageStoreIManageablePageobject - some kind of page representationCopyright © 2006–2021 Apache Software Foundation. All rights reserved.