Package org.nuxeo.ecm.core.convert.cache
Class ConversionCacheHolder
- java.lang.Object
-
- org.nuxeo.ecm.core.convert.cache.ConversionCacheHolder
-
public class ConversionCacheHolder extends Object
Manager for the cache system of theConversionService.- Author:
- tiry
-
-
Field Summary
Fields Modifier and Type Field Description protected static Map<String,ConversionCacheEntry>cachestatic AtomicLongCACHE_HITSprotected static ReentrantReadWriteLockcacheLockstatic intNB_SUB_PATH_PARTstatic intSUB_PATH_PART_SIZE
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidaddToCache(String key, BlobHolder result)static voiddeleteCache()protected static voiddoAddToCache(String key, BlobHolder result)protected static ConversionCacheEntrydoGetCacheEntry(String key)protected static BlobHolderdoGetFromCache(String key)protected static voiddoRemoveFromCache(String key)static ConversionCacheEntrygetCacheEntry(String key)protected static StringgetCacheEntryPath(String key)static longgetCacheHits()static Set<String>getCacheKeys()static BlobHoldergetFromCache(String key)static intgetNbCacheEntries()protected static List<String>getSubPathFromKey(String key)static voidremoveFromCache(String key)
-
-
-
Field Detail
-
cache
protected static final Map<String,ConversionCacheEntry> cache
-
cacheLock
protected static final ReentrantReadWriteLock cacheLock
-
NB_SUB_PATH_PART
public static final int NB_SUB_PATH_PART
- See Also:
- Constant Field Values
-
SUB_PATH_PART_SIZE
public static final int SUB_PATH_PART_SIZE
- See Also:
- Constant Field Values
-
CACHE_HITS
public static final AtomicLong CACHE_HITS
-
-
Method Detail
-
getCacheHits
public static long getCacheHits()
-
getNbCacheEntries
public static int getNbCacheEntries()
-
addToCache
public static void addToCache(String key, BlobHolder result)
-
doAddToCache
protected static void doAddToCache(String key, BlobHolder result)
-
removeFromCache
public static void removeFromCache(String key)
-
doRemoveFromCache
protected static void doRemoveFromCache(String key)
-
getCacheEntry
public static ConversionCacheEntry getCacheEntry(String key)
-
doGetCacheEntry
protected static ConversionCacheEntry doGetCacheEntry(String key)
-
getFromCache
public static BlobHolder getFromCache(String key)
-
doGetFromCache
protected static BlobHolder doGetFromCache(String key)
-
deleteCache
public static void deleteCache()
- Since:
- 6.0
-
-