Class CacheManager

All Implemented Interfaces:
SpaceEvictionManager

public class CacheManager extends AbstractCacheManager implements SpaceEvictionManager
The Cache Manager acts as a fast intermediate storage for objects in Virtual Memory.

The maximum number of objects cached in memory is determined by a space property (cache-size).

However, according to this implementation, the following objects are always in the cache:

  • Templates of any kind
  • Active Transactions
  • Entries locked under Active Transactions
  • Entries waiting for templates

The objects in the cache are indexed.

Templates are cached in memory and are not written to the underlying SA.

  • Field Details

    • _terminatingXtnsInfo

      public final TerminatingFifoXtnsInfo _terminatingXtnsInfo
    • MIN_SIZE_TO_PERFORM_EXPLICIT_PROPERTIES_INDEX_SCAN_

      public static final int MIN_SIZE_TO_PERFORM_EXPLICIT_PROPERTIES_INDEX_SCAN_
      See Also:
    • GS_13953_ENABLED

      public static final boolean GS_13953_ENABLED
    • MIN_SIZE_TO_CONSIDER_COMPOUND_INDICES

      public static final int MIN_SIZE_TO_CONSIDER_COMPOUND_INDICES
      See Also:
  • Constructor Details

  • Method Details

    • isSyncHybrid

      public boolean isSyncHybrid()
    • getLogger

      public static org.slf4j.Logger getLogger()
    • setLeaseManager

      public void setLeaseManager(LeaseManager leaseManager)
    • init

      public void init(Properties properties) throws SAException, CreateException
      Throws:
      SAException
      CreateException
    • isTimeBasedEvictionStrategy

      public boolean isTimeBasedEvictionStrategy()
    • requiresEvictionReplicationProtection

      public boolean requiresEvictionReplicationProtection()
    • getEvictionReplicationsMarkersRepository

      public IEvictionReplicationsMarkersRepository getEvictionReplicationsMarkersRepository()
    • initCache

      public void initCache(boolean loadDataFromDB, Properties properties) throws SAException
      Init. the cache.

      This method is called after init(), and after the engine Xtn table and Directory are completely built, but before any other SA method is called.

      This implementation preloads all active transactions and entries locked under these transactions into cache.

      In addition, all class info is preloaded into cache.

      Throws:
      SAException
    • isCacheExternalDB

      public boolean isCacheExternalDB()
      Returns an indication if Storage Adapter acts as an external data-source.
      Returns:
      true if Storage Adapter is an external data-source; false otherwise.
    • getEngine

      public SpaceEngine getEngine()
    • getTypeManager

      public SpaceTypeManager getTypeManager()
    • getLeaseManager

      public LeaseManager getLeaseManager()
    • getBlobStoreStorageHandler

      public BlobStoreExtendedStorageHandler getBlobStoreStorageHandler()
    • getBlobStoreMemoryMonitor

      public BlobStoreMemoryMonitor getBlobStoreMemoryMonitor()
    • getBlobStoreRecoveryHelper

      public IStorageConsistency getBlobStoreRecoveryHelper()
    • useBlobStoreBulks

      public boolean useBlobStoreBulks()
    • useBlobStoreReplicationBackupBulks

      public boolean useBlobStoreReplicationBackupBulks()
    • useBlobStorePreFetch

      public boolean useBlobStorePreFetch()
    • isPersistentBlobStore

      public boolean isPersistentBlobStore()
    • optimizedBlobStoreClear

      public boolean optimizedBlobStoreClear()
    • needReReadAfterEntryLock

      public boolean needReReadAfterEntryLock()
    • mayNeedEntriesUnpinning

      public boolean mayNeedEntriesUnpinning()
    • isClusteredExternalDBEnabled

      public boolean isClusteredExternalDBEnabled()
      Returns an indication if Storage Adapter acts as an external clustered data-source. true if either indicated by a cluster-wide property or by enabling the mirror service in the cluster.
      Returns:
      true if Storage Adapter is an external clustered data-source; false otherwise.
    • isCentralDB

      public boolean isCentralDB()
      returns an indication if the underlying DB is a central DB common to several cluster members
      Returns:
      true if the underlying DB is cental; false otherwise.
    • isVersionedExternalDB

      public boolean isVersionedExternalDB()
      returns an indication if the underlying data-source supports versioning.
      Returns:
      true if the underlying DB supports versioning; false otherwise.
    • isEmptyAfterInitialLoadStage

      public boolean isEmptyAfterInitialLoadStage()
    • isDirectPersistencyEmbeddedtHandlerUsed

      public boolean isDirectPersistencyEmbeddedtHandlerUsed()
    • getLockManager

      public IBasicLockManager<IEntryHolder> getLockManager()
      get the lock manager
    • touchByEntry

      public void touchByEntry(Context context, IEntryHolder entry, boolean modifyOp, ITemplateHolder template, CacheOperationReason cacheOperationReason)
    • getBlobStoreInternalCache

      public IBlobStoreCacheHandler getBlobStoreInternalCache()
    • hasBlobStoreOffHeapCache

      public boolean hasBlobStoreOffHeapCache()
    • hasBlobStoreOffHeapStore

      public boolean hasBlobStoreOffHeapStore()
    • getConfigInfo

      public String getConfigInfo()
    • shutDown

      public void shutDown()
      shut down cache manager. does not throw any exception- unusable.
    • useRecentDeletes

      public boolean useRecentDeletes()
      returns true if recentDeletes hash in engine need to be used.
    • insertToRecentDeletes

      public void insertToRecentDeletes(IEntryHolder entry, long duration, ServerTransaction committingXtn)
    • removeFromRecentDeletes

      public boolean removeFromRecentDeletes(IEntryHolder entry)
    • getRecentDeletesIterator

      public Iterator<RecentDeletesRepository.RecentDeleteInfo> getRecentDeletesIterator()
    • getRecentDeleteInfo

      public RecentDeletesRepository.RecentDeleteInfo getRecentDeleteInfo(String uid)
    • getNumOfRecentDeletes

      public int getNumOfRecentDeletes()
    • useRecentUpdatesForPinning

      public boolean useRecentUpdatesForPinning()
      returns true if recentUpdates hash in engine need to be used.
    • insertToRecentUpdates

      public void insertToRecentUpdates(IEntryHolder entry, long duration, ServerTransaction committingXtn)
    • insertToRecentUpdatesIfNeeded

      public void insertToRecentUpdatesIfNeeded(IEntryHolder entry, long duration, ServerTransaction committingXtn)
    • removeFromRecentUpdatesIfNeeded

      public boolean removeFromRecentUpdatesIfNeeded(IEntryHolder entry)
    • getRecentUpdatesIterator

      public Iterator<RecentUpdatesRepository.RecentUpdateInfo> getRecentUpdatesIterator()
    • getRecentUpdateInfo

      public RecentUpdatesRepository.RecentUpdateInfo getRecentUpdateInfo(String uid)
    • getNumOfRecentUpdates

      public int getNumOfRecentUpdates()
    • isEntryInRecentUpdates

      public boolean isEntryInRecentUpdates(IEntryHolder entry)
    • isDummyEntry

      public boolean isDummyEntry(IEntryHolder eh)
    • evictBatch

      public int evictBatch(int evictionQuota)
      evict a quota of entries from cache.
      Specified by:
      evictBatch in class AbstractCacheManager
      Returns:
      number of actual evicted
    • insertEntry

      public void insertEntry(Context context, IEntryHolder entryHolder, boolean shouldReplicate, boolean origin, boolean suppliedUid, boolean fromReplication) throws SAException, EntryAlreadyInSpaceException
      insert an entry to the space.
      Throws:
      SAException
      EntryAlreadyInSpaceException
    • handleInsertEntryReplication

      public void handleInsertEntryReplication(Context context, IEntryHolder entryHolder) throws SAException
      Throws:
      SAException
    • handleInsertEntryReplication

      public void handleInsertEntryReplication(Context context, IEntryHolder entryHolder, int blobstoreBulkId) throws SAException
      Throws:
      SAException
    • getEvictionPolicyReplicationMembersGroupName

      public String getEvictionPolicyReplicationMembersGroupName()
    • updateEntry

      public IEntryHolder updateEntry(Context context, IEntryHolder entry, ITemplateHolder template, boolean shouldReplicate, boolean origin) throws SAException
      update entry- if the entry should be updated under a xtn - insert to xtn lists. update entry cache, call SA to perform update NOTE- if the template is under xtn associateEntryWithXtn is called by the engine- and not this routine
      Throws:
      SAException
    • handleUpdateEntryReplication

      public void handleUpdateEntryReplication(Context context, IEntryHolder new_eh, IEntryData originalData, Collection<SpaceEntryMutator> mutators)
    • handleUpdateEntryReplication

      public void handleUpdateEntryReplication(Context context, IEntryHolder new_eh, IEntryData originalData, Collection<SpaceEntryMutator> mutators, int blobstoreBulkId)
    • makeChangeOpEntry

      public IEntryHolder makeChangeOpEntry(Context context, ITemplateHolder template, IEntryHolder currentEntry)
    • insertTemplate

      public void insertTemplate(Context context, ITemplateHolder templateHolder, boolean shouldReplicate)
      insert a template to the cache and DB.
    • getEntry

      public IEntryHolder getEntry(Context context, IEntryHolder entryHolder, boolean tryInsertToCache, boolean lockedEntry, boolean useOnlyCache) throws SAException
      Parameters:
      lockedEntry - - true if the entry is locked by the caller
      Throws:
      SAException
    • getEntry

      public IEntryHolder getEntry(Context context, IEntryHolder entryHolder, boolean tryInsertToCache, boolean lockedEntry) throws SAException
      Throws:
      SAException
    • getEntry

      public IEntryHolder getEntry(Context context, String uid, String inputClassName, IEntryHolder template, boolean tryInsertToCache, boolean lockedEntry, boolean useOnlyCache) throws SAException
      get entry by its uid, and, optionally, by its template className is passed if known, can be null template is not null if isCacheExternalDB is true: external DB, the template must contain the PK fields insertToCache- true if entry shouldbe inserted to cache
      Throws:
      SAException
    • getTemplatesInfo

      public List<TemplateInfo> getTemplatesInfo(String className)
      returns a list of all the pending templates for the given class
    • getTemplate

      public ITemplateHolder getTemplate(String uid)
    • getMatchingMemoryEntriesForScanning

      public IScanListIterator<IEntryCacheInfo> getMatchingMemoryEntriesForScanning(Context context, IServerTypeDesc currServerTypeDesc, ITemplateHolder template, IServerTypeDesc serverTypeDesc)
    • removeEntry

      public int removeEntry(Context context, IEntryHolder entryHolder, IEntryCacheInfo pEntry, boolean shouldReplicate, boolean origin, SpaceEngine.EntryRemoveReasonCodes removeReason, boolean disableSAcall) throws SAException
      remove entry from cache & SA
      Parameters:
      disableSAcall - - if true don't call the underlying SA
      Returns:
      number of completed sync replications.
      Throws:
      SAException
    • handleRemoveEntryReplication

      public void handleRemoveEntryReplication(Context context, IEntryHolder entryHolder, SpaceEngine.EntryRemoveReasonCodes removeReason)
    • handleRemoveEntryReplication

      public void handleRemoveEntryReplication(Context context, IEntryHolder entryHolder, SpaceEngine.EntryRemoveReasonCodes removeReason, int blobstoreBulkId)
    • removeTemplate

      public void removeTemplate(Context context, ITemplateHolder template, boolean fromReplication, boolean origin, boolean dontReplicate)
      Marks template as DELETED and send a BUS Packet to the GC. Assumes the specified template is locked.
    • removeTemplate

      public void removeTemplate(Context context, ITemplateHolder template, boolean fromReplication, boolean origin, boolean dontReplicate, SpaceEngine.TemplateRemoveReasonCodes removeReason)
      Marks template as DELETED and send a BUS Packet to the GC. Assumes the specified template is locked.
    • getFifoBackgroundDispatcher

      public FifoBackgroundDispatcher getFifoBackgroundDispatcher()
    • makeWaitForInfo

      public void makeWaitForInfo(Context context, IEntryHolder entryHolder, ITemplateHolder templateHolder) throws SAException
      Throws:
      SAException
    • removeWaitingForInfo

      public void removeWaitingForInfo(Context context, IEntryHolder entryHolder, ITemplateHolder templateHolder, boolean unpinIfPossible)
    • associateEntryWithXtn

      public IEntryHolder associateEntryWithXtn(Context context, IEntryHolder entryHolder, ITemplateHolder template, XtnEntry xtnEntry, IEntryHolder new_content) throws SAException
      tie an entry with a transaction. new_content is the new values in case of update operation
      Throws:
      SAException
    • getPEntryByUid

      public IEntryCacheInfo getPEntryByUid(String uid)
    • getEntryByUidFromPureCache

      public IEntryHolder getEntryByUidFromPureCache(String uid)
    • getMVCCShellEntryCacheInfoByUid

      public MVCCShellEntryCacheInfo getMVCCShellEntryCacheInfoByUid(String uid)
    • getMVCCEntryCacheInfoByEntryHolder

      public IEntryCacheInfo getMVCCEntryCacheInfoByEntryHolder(MVCCEntryHolder entryHolder)
    • isEntryInPureCache

      public boolean isEntryInPureCache(String uid)
      Parameters:
      uid - of entry to check
      Returns:
      true if this entry is in pure cache; false otherwise.
    • disconnectEntryFromXtn

      public void disconnectEntryFromXtn(Context context, IEntryHolder entryHolder, XtnEntry xtnEntry, boolean xtnEnd) throws SAException
      disconnect an entry from xtn
      Parameters:
      entryHolder - - entry to disconnect
      xtnEnd - - true if its part of commit/rb process
      Throws:
      SAException
    • disconnectMVCCEntryFromXtn

      public void disconnectMVCCEntryFromXtn(Context context, MVCCEntryCacheInfo pEntry, XtnEntry xtnEntry, boolean xtnEnd) throws SAException
      Throws:
      SAException
    • prepare

      public void prepare(Context context, XtnEntry xtnEntry, boolean supportsTwoPhaseReplication, boolean handleReplication, boolean handleSA) throws SAException
      Throws:
      SAException
    • prePrepare

      public void prePrepare(XtnEntry xtnEntry)
      this method is called by the engine in order to make a "snapshot" of entries needed for notify.
    • isMVCCEnabled

      public boolean isMVCCEnabled()
    • getMVCCHandler

      public MVCCCacheManagerHandler getMVCCHandler()
    • handleUnderXtnUpdate

      public void handleUnderXtnUpdate(Context context, ServerTransaction xtn, IEntryHolder eh, boolean isCommitting, XtnData pXtn)
      xtn terminating-handle under xtn updates.
    • preCommit

      public void preCommit(Context context, XtnEntry xtnEntry, boolean supportsTwoPhaseReplication)
    • commit

      public void commit(Context context, XtnEntry xtnEntry, boolean singleParticipant, boolean anyUpdates, boolean supportsTwoPhaseReplication) throws SAException
      Throws:
      SAException
    • rollback

      public void rollback(Context context, XtnEntry xtnEntry, boolean alreadyPrepared, boolean anyUpdates, boolean supportsTwoPhaseReplication) throws SAException
      Throws:
      SAException
    • extendLeasePeriod

      public void extendLeasePeriod(Context context, long time, long original_time, String uid, String classname, int objectType, boolean shouldReplicate, boolean origin)
    • findTemplatesByIndex

      public Object findTemplatesByIndex(Context context, IServerTypeDesc typeDesc, IEntryHolder entry, MatchTarget matchTarget)
      given a class name return the SL of matching templates. This API is more efficient than direct use of templates iterator
    • getEntryFromCacheHolder

      public IEntryHolder getEntryFromCacheHolder(IEntryCacheInfo pt)
      given a PEntry, return the entry.
    • getEntryCacheInfo

      public IEntryCacheInfo getEntryCacheInfo(IEntryHolder eh)
      get PEntry for entry.
    • getTemplateCacheInfo

      public TemplateCacheInfo getTemplateCacheInfo(ITemplateHolder th)
      get PEntry for entry.
    • makeEntriesIter

      public ISAdapterIterator<IEntryHolder> makeEntriesIter(Context context, ITemplateHolder template, IServerTypeDesc serverTypeDesc, long SCNFilter, long leaseFilter, boolean memoryOnly, boolean transientOnly) throws SAException
      Throws:
      SAException
    • makeEntriesIter

      public ISAdapterIterator<IEntryHolder> makeEntriesIter(Context context, ITemplateHolder template, IServerTypeDesc serverTypeDesc, long SCNFilter, long leaseFilter, boolean memoryOnly) throws SAException
      Throws:
      SAException
    • makeMVCCShellsRecoveryIter

      public ISAdapterIterator<MVCCShellEntryCacheInfo> makeMVCCShellsRecoveryIter(IServerTypeDesc serverTypeDesc)
    • makeScanableEntriesIter

      public IScanListIterator makeScanableEntriesIter(Context context, ITemplateHolder template, IServerTypeDesc serverTypeDesc, long SCNFilter, long leaseFilter, boolean memoryOnly) throws SAException
      Throws:
      SAException
    • makeUnderXtnTemplatesIter

      public ISAdapterIterator<ITemplateHolder> makeUnderXtnTemplatesIter(Context context, XtnEntry xtnEntry) throws SAException
      Throws:
      SAException
    • makeUnderXtnEntriesIter

      public ISAdapterIterator makeUnderXtnEntriesIter(Context context, XtnEntry xtnEntry, int selectType) throws SAException
      Throws:
      SAException
    • makeUnderXtnEntriesIter

      public ISAdapterIterator makeUnderXtnEntriesIter(Context context, XtnEntry xtnEntry, int selectType, boolean returnPentries) throws SAException
      Throws:
      SAException
    • count

      public int count(Context context, ITemplateHolder template, XtnEntry xtnFilter) throws SAException
      Throws:
      SAException
    • getTypeDataFactory

      public TypeDataFactory getTypeDataFactory()
    • getTypeData

      public TypeData getTypeData(IServerTypeDesc typeDesc)
    • safeInsertEntryToCache

      public IEntryCacheInfo safeInsertEntryToCache(Context context, IEntryHolder entryHolder, boolean newEntry, TypeData pType, boolean pin, CacheManager.InitialLoadOrigin fromInitialLoad) throws SAException
      Inserts the specified entry to cache, perform memory manager check. used by initial load.
      Throws:
      SAException
    • forceSpaceIdIndexIfEqual

      public boolean forceSpaceIdIndexIfEqual()
    • getBlobStoreStatistics

      public BlobStoreStatistics getBlobStoreStatistics()
    • handleMVCCGenerations

      public void handleMVCCGenerations(Context context, MVCCEntryHolder entry, XtnEntry xtnEntry) throws SAException
      Throws:
      SAException
    • validateMVCCGenerationConsistency

      public void validateMVCCGenerationConsistency(SpaceContext sc, int modifiers, boolean take)
    • internalInsertEntryToCache

      public IEntryCacheInfo internalInsertEntryToCache(Context context, IEntryHolder entryHolder, boolean newEntry, TypeData typeData, IEntryCacheInfo pEntry, boolean pin)
      Inserts the specified entry to cache.
    • insertEntryReferences

      public void insertEntryReferences(Context context, IEntryCacheInfo pEntry, TypeData pType, boolean applySequenceNumber)
      Inserts the refs to cache.
    • updateEntryInCache

      public IEntryCacheInfo updateEntryInCache(Context context, IEntryCacheInfo pEntry, IEntryHolder entryHolder, IEntryData newEntryData, long newExpirationTime, int modifiers)
      update entry values in cache. pEntry - the current in cache or null if unknown
    • removeEntryFromCache

      public boolean removeEntryFromCache(IEntryHolder entryHolder)
      Removes the specified entry from cache. return true if removal ok
    • removeEntryFromCache

      public boolean removeEntryFromCache(IEntryHolder entryHolder, boolean initiatedByEvictionStrategy, boolean locked, IEntryCacheInfo pEntry, CacheManager.RecentDeleteCodes recentDeleteUsage)
      Removes the specified entry from cache. return true if removal ok
    • getSqlFunctions

      public SQLFunctions getSqlFunctions()
    • removeEntryReferences

      public void removeEntryReferences(IEntryCacheInfo pEntry, TypeData pType, int numOfIndexesInsertedOnError)
      Removes entry refs from cache.
    • getEntryByUniqueId

      public IEntryCacheInfo getEntryByUniqueId(Context context, IServerTypeDesc currServerTypeDesc, Object templateValue, ITemplateHolder template)
    • getEntriesByUniqueIds

      public IEntryCacheInfo[] getEntriesByUniqueIds(Context context, IServerTypeDesc currServerTypeDesc, Object[] ids, ITemplateHolder template)
    • getEntriesMinIndex

      public IStoredList<IEntryCacheInfo> getEntriesMinIndex(Context context, TypeData typeData, int numOfFields, ITemplateHolder template)
      Computes the best way to reach a list of potential match of entries of the specified type.

      Handles also unindexed entries.

      Assumes the specified template is a superclass (in the wide sense) of the specified entry.

      Parameters:
      typeData - the type of entries to search for
      template - the template to match against
      Returns:
      a SL containing potential matches or null if there are no matches.
    • getEntriesMinIndexExtended

      public Object getEntriesMinIndexExtended(Context context, TypeData entryType, int numOfFields, ITemplateHolder template)
      Using extended match-

      Computes the best way to reach a list of potential match of entries of the specified type.

      Handles also un-indexed entries.

      Assumes the specified template is a superclass (in the wide sense) of the specified entry.

      Parameters:
      entryType - the type of entries to search for
      template - the template to match against
      Returns:
      a SL or IOrderedIndexScan containing potential matches or null if there are no matches.
    • canSkipFullScanForAggregators

      public boolean canSkipFullScanForAggregators(ITemplateHolder template)
    • canIgnoreLeaseExpiration

      public boolean canIgnoreLeaseExpiration()
    • canIgnoreOpenTransactions

      public boolean canIgnoreOpenTransactions()
    • getEntryByIdFromPureCache

      public IEntryHolder getEntryByIdFromPureCache(Object id, IServerTypeDesc typeDesc)
    • tryEvict

      public boolean tryEvict(EvictableServerEntry entry)
      get permission to evict an entry, and if granted remove the entry from cache. this function must be called by the eviction Strategy prior to performing an eviction of an entry. eviction must be performed only if permission is granted by the space. permission can be denied if the entry is currently locked by another thread that is performing a space operation on it NOTE: after calling grantEvictionPermissionAndRemove and receiving true as an answer the eviction strategy should remove the entry from its internal state and call reportEvictionCompletion(entry)
      Specified by:
      tryEvict in interface SpaceEvictionManager
      Parameters:
      entry - The entry to evict.
      Returns:
      true if permission is granted and entry was removed from cache
    • unpinIfNeeded

      public boolean unpinIfNeeded(Context context, IEntryHolder entry, ITemplateHolder template, IEntryCacheInfo pEntry)
      if relevant-unpin the entry method is called after each operation or xtn termination entry should be locked when method is called
      Returns:
      null if not unpinned
    • initiatedEviction

      public boolean initiatedEviction(Context context, IEntryHolder entry, boolean shouldReplicate) throws SAException
      Throws:
      SAException
    • isMemorySpace

      public boolean isMemorySpace()
      is this space a memory space ?
      Returns:
      true if the space is a memory space
    • getReplicationContext

      public IReplicationOutContext getReplicationContext(Context context)
    • isFromFifoClass

      public boolean isFromFifoClass(IServerTypeDesc typeDesc)
      Returns:
      true if the class represented by enumeration a fifo class
    • getTemplatesManager

      public TemplatesManager getTemplatesManager()
    • getNumberOfLockedObjectsUnderTxn

      public int getNumberOfLockedObjectsUnderTxn(XtnEntry xtnEntry)
      used by getTransactionsInfo to retrieve number of Locked Objects
      Returns:
      the number of Locked Objects by the given Transaction
    • getMinExtendedIndexActivationSize

      public int getMinExtendedIndexActivationSize()
    • getEnriesSize

      public int getEnriesSize()
    • getLatestTTransactionTerminationNum

      public long getLatestTTransactionTerminationNum()
      get the Terminating fifo transaction
    • setLatestTransactionTerminationNum

      public void setLatestTransactionTerminationNum(long xtnTerminationNum)
      get the Terminating fifo transaction //NOTE- must be called when xtns are locked !!!!!!!!
    • setFifoXtnNumber

      public void setFifoXtnNumber(XtnEntry xtnEntry, long fifoXtnNumber)
      set the fifo xtn number of a xtn
    • getFifoXtnNumber

      public long getFifoXtnNumber(XtnEntry xtnEntry)
      get the fifo xtn number of a xtn
    • updateFifoXtnInfoForEntry

      public void updateFifoXtnInfoForEntry(IEntryHolder eh, long xtnNumber, boolean writeLock, boolean entryWritingXtn)
      update fifo xtn info for entry MUST be called when entry is locked update write lock if writeLock is true, else update read lock entryWritingXtn = true if this is the commit of the entry write
    • setFifoCreationXtnInfoForEntry

      public void setFifoCreationXtnInfoForEntry(IEntryHolder eh, long xtnNumber)
      create fifo xtn info for entry MUST be called when entry is locked
      Parameters:
      xtnNumber - - the xtn in the system when entry was created
    • getFifoEntryXtnInfo

      public TerminatingFifoXtnsInfo.FifoXtnEntryInfo getFifoEntryXtnInfo(IEntryHolder eh)
    • removeFifoXtnInfoForEntry

      public void removeFifoXtnInfoForEntry(IEntryHolder eh)
      remove fifo xtn info for entry MUST be called when entry is locked
    • getTerminatingXtnsEntries

    • lockEntry

      public void lockEntry(XtnData xtn, IEntryCacheInfo pEntry, OperationID operationID)
    • updateLock

      public void updateLock(XtnData xtn, IEntryCacheInfo pEntry, OperationID operationID, int templateOperation)
    • removeLockedEntry

      public void removeLockedEntry(XtnData xtn, IEntryCacheInfo pEntry)
    • getStorageAdapter

      public IStorageAdapter getStorageAdapter()
      Returns:
      the sA
    • getFifoGroupCacheImpl

      public FifoGroupCacheImpl getFifoGroupCacheImpl()
    • getCacheContext

      public Context getCacheContext()
    • freeCacheContext

      public Context freeCacheContext(Context context)
    • viewCacheContext

      public Context viewCacheContext()
    • startTemplateExpirationManager

      public void startTemplateExpirationManager()
    • getTemplateExpirationManager

      public TemplateExpirationManager getTemplateExpirationManager()
    • testAndSetFGCacheForEntry

      public boolean testAndSetFGCacheForEntry(Context context, IEntryHolder entry, ITemplateHolder template, boolean testOnly, IServerTypeDesc tte)
    • handleFifoGroupsCacheOnXtnEnd

      public void handleFifoGroupsCacheOnXtnEnd(Context context, XtnEntry xtnEntry)
    • addToEvictionStrategy

      public void addToEvictionStrategy(EvictableServerEntry entry, boolean isNew)
    • removeFromEvictionStrategy

      public void removeFromEvictionStrategy(EvictableServerEntry entry)
    • getLocalCaches

      public Map<String,LocalCacheDetails> getLocalCaches()
    • getCacheLogger

      public static org.slf4j.Logger getCacheLogger()
    • getNumberOfEntries

      public int getNumberOfEntries()
    • getNumberOfEntries

      public int getNumberOfEntries(String typeName, boolean includeSubtypes)
    • getNumberOfNotifyTemplates

      public int getNumberOfNotifyTemplates()
    • getNumberOfNotifyTemplates

      public int getNumberOfNotifyTemplates(String typeName, boolean includeSubtypes)
    • getRuntimeInfo

      public SpaceRuntimeInfo getRuntimeInfo(String typeName)
    • getQueryExtensionManager

      public QueryExtensionIndexManagerWrapper getQueryExtensionManager(String namespace)
    • closeQueryExtensionManagers

      public void closeQueryExtensionManagers()