com.sun.ejb.containers.util.cache
Class FIFOSessionCache

java.lang.Object
  extended by com.sun.ejb.containers.util.cache.BaseCache
      extended by com.sun.ejb.containers.util.cache.LruCache
          extended by com.sun.ejb.containers.util.cache.LruSessionCache
              extended by com.sun.ejb.containers.util.cache.FIFOSessionCache
All Implemented Interfaces:
Cache, EJBCacheStatsProvider, StatsProvider

public class FIFOSessionCache
extends LruSessionCache


Nested Class Summary
 
Nested classes/interfaces inherited from class com.sun.ejb.containers.util.cache.LruSessionCache
LruSessionCache.LruSessionCacheItem
 
Nested classes/interfaces inherited from class com.sun.ejb.containers.util.cache.LruCache
LruCache.LruCacheItem
 
Nested classes/interfaces inherited from class com.sun.ejb.containers.util.cache.BaseCache
BaseCache.CacheItem
 
Field Summary
 
Fields inherited from class com.sun.ejb.containers.util.cache.LruSessionCache
backingStore, cacheIdleTimeoutInSeconds, configData, confMaxCacheSize, container, loadCountLock, loadFromBackupCount, numActivated, passivationCount, passivationCountLock, removalTimeoutInSeconds, removeIfIdle
 
Fields inherited from class com.sun.ejb.containers.util.cache.LruCache
_logger, cacheName, head, listSize, NO_TIMEOUT, tail, timeout, trimCount
 
Fields inherited from class com.sun.ejb.containers.util.cache.BaseCache
_rb, addCount, addCountLk, bucketLocks, buckets, entryCount, entryCountLk, hitCount, hitCountLk, listeners, maxBuckets, missCount, missCountLk, overflowCount, overflowCountLk, refreshCount, refreshCountLk, refreshFlags, removalCount, removalCountLk, threshold
 
Constructor Summary
FIFOSessionCache(String cacheName, SFSBContainerCallback container, int cacheIdleTime, int removalTime)
           
 
Method Summary
protected  void itemAccessed(BaseCache.CacheItem item)
          this item is accessed
protected  void itemRefreshed(BaseCache.CacheItem item, int oldSize)
          item value has been refreshed
 void trimTimedoutItems(int maxCount)
          trim the timedOut entries from the cache.
 
Methods inherited from class com.sun.ejb.containers.util.cache.LruSessionCache
appendStats, createItem, destroy, eligibleForRemovalFromCache, getCacheHits, getCacheMisses, getLoadFromBackupCount, getMaxCacheSize, getNumBeansInCache, getNumExpiredSessionsRemoved, getNumPassivationErrors, getNumPassivations, getNumPassivationSuccess, getNumVictimsAccessed, incrementLoadFromBackupCount, lookupEJB, passivateEJB, remove, remove, setBackingStore, setConfigData, setMaxCacheSize, setShutdownState, setStatefulSessionStoreMonitor, setUndeployedState, shutdown, trimItem, trimUnSortedTimedoutItems, values
 
Methods inherited from class com.sun.ejb.containers.util.cache.LruCache
getStatByName, getStats, itemAdded, itemRemoved, setCacheName, trimExpiredEntries, trimLru
 
Methods inherited from class com.sun.ejb.containers.util.cache.BaseCache
_put, _remove, _removeItem, add, add, addCacheListener, clear, clearStats, contains, decrementEntryCount, elements, eq, get, get, getAll, getEntryCount, getIndex, getIndex, handleOverflow, hash, incrementAddCount, incrementEntryCount, incrementHitCount, incrementMissCount, incrementOverflowCount, incrementRefreshCount, incrementRemovalCount, init, init, isEmpty, isThresholdReached, keys, loadValue, notifyRefresh, put, put, remove, remove, removeAll, waitRefresh
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FIFOSessionCache

public FIFOSessionCache(String cacheName,
                        SFSBContainerCallback container,
                        int cacheIdleTime,
                        int removalTime)
Method Detail

itemAccessed

protected void itemAccessed(BaseCache.CacheItem item)
Description copied from class: LruCache
this item is accessed

Overrides:
itemAccessed in class LruSessionCache
Parameters:
item - CacheItem accessed Cache bucket is already synchronized by the caller

itemRefreshed

protected void itemRefreshed(BaseCache.CacheItem item,
                             int oldSize)
Description copied from class: LruCache
item value has been refreshed

Overrides:
itemRefreshed in class LruCache
Parameters:
item - CacheItem that was refreshed
oldSize - size of the previous value that was refreshed Cache bucket is already synchronized by the caller

trimTimedoutItems

public void trimTimedoutItems(int maxCount)
Description copied from class: LruSessionCache
trim the timedOut entries from the cache. This call is to be scheduled by a thread managed by the container. In this case a sorted LRU list exists based on access time and this list is scanned

Overrides:
trimTimedoutItems in class LruSessionCache


Copyright © 2012 GlassFish Community. All Rights Reserved.