Class CachingBlobStore

  • All Implemented Interfaces:
    java.lang.AutoCloseable, org.apache.jackrabbit.oak.commons.cache.Cache.Backend<org.apache.jackrabbit.oak.spi.blob.AbstractBlobStore.BlockId,​org.apache.jackrabbit.oak.spi.blob.AbstractBlobStore.Data>, org.apache.jackrabbit.oak.spi.blob.BlobStore, org.apache.jackrabbit.oak.spi.blob.GarbageCollectableBlobStore
    Direct Known Subclasses:
    CloudBlobStore

    public abstract class CachingBlobStore
    extends org.apache.jackrabbit.oak.spi.blob.AbstractBlobStore
    A blob store with a cache.
    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.apache.jackrabbit.oak.spi.blob.AbstractBlobStore

        org.apache.jackrabbit.oak.spi.blob.AbstractBlobStore.BlockId, org.apache.jackrabbit.oak.spi.blob.AbstractBlobStore.Data
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected long blobCacheSize  
      protected org.apache.jackrabbit.oak.cache.CacheLIRS<java.lang.String,​byte[]> cache  
      protected static long DEFAULT_CACHE_SIZE  
      static java.lang.String MEM_CACHE_NAME  
      • Fields inherited from class org.apache.jackrabbit.oak.spi.blob.AbstractBlobStore

        BLOCK_SIZE_LIMIT, HASH_ALGORITHM, inUse, TYPE_DATA, TYPE_HASH
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clearCache()  
      long getBlobCacheSize()  
      org.apache.jackrabbit.oak.cache.CacheStats getCacheStats()  
      • Methods inherited from class org.apache.jackrabbit.oak.spi.blob.AbstractBlobStore

        clearInUse, close, deleteChunks, getBlobId, getBlobLength, getBlockSize, getBlockSizeMin, getInputStream, getOrCreateReferenceKey, getReference, getStatsCollector, isMarkEnabled, load, mark, mark, markInUse, readBlob, readBlockFromBackend, resolveChunks, setBlockSize, setBlockSizeMin, setReferenceKey, setReferenceKeyEncoded, setReferenceKeyPlainText, setStatsCollector, startMark, storeBlock, sweep, usesBlobId, writeBlob, writeBlob, writeBlob
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface org.apache.jackrabbit.oak.spi.blob.GarbageCollectableBlobStore

        countDeleteChunks, getAllChunkIds
    • Field Detail

      • cache

        protected final org.apache.jackrabbit.oak.cache.CacheLIRS<java.lang.String,​byte[]> cache
      • blobCacheSize

        protected final long blobCacheSize
    • Constructor Detail

      • CachingBlobStore

        public CachingBlobStore​(long cacheSize)
      • CachingBlobStore

        public CachingBlobStore()
    • Method Detail

      • clearCache

        public void clearCache()
      • getBlobCacheSize

        public long getBlobCacheSize()
      • getCacheStats

        public org.apache.jackrabbit.oak.cache.CacheStats getCacheStats()