Package org.cache2k.core
Class HeapCache.Tunable
- java.lang.Object
-
- org.cache2k.core.util.TunableConstants
-
- org.cache2k.core.HeapCache.Tunable
-
- All Implemented Interfaces:
Cloneable
public static class HeapCache.Tunable extends TunableConstants
-
-
Field Summary
Fields Modifier and Type Field Description StandardCommonMetricsFactory
commonMetricsFactory
org.cache2k.io.ExceptionPropagator
exceptionPropagator
int
segmentCountOverride
Override parameter for segment count.long
sharpExpirySafetyGapMillis
When sharp expiry is enabled, the expiry timer goes before the actual expiry to switch back to a time checking scheme when the cache is accessed.ThreadFactoryProvider
threadFactoryProvider
long
timerLagMillis
-
Constructor Summary
Constructors Constructor Description Tunable()
-
-
-
Field Detail
-
sharpExpirySafetyGapMillis
public long sharpExpirySafetyGapMillis
When sharp expiry is enabled, the expiry timer goes before the actual expiry to switch back to a time checking scheme when the cache is accessed. This prevents that an expired value gets served by the cache when the time is too late. Experiments showed that a value of one second is usually sufficient.OS scheduling is not reliable on virtual servers (e.g. KVM) to give the expiry task compute time on a busy server. To be safe in extreme cases, this parameter is set to a high value.
-
threadFactoryProvider
public ThreadFactoryProvider threadFactoryProvider
-
commonMetricsFactory
public StandardCommonMetricsFactory commonMetricsFactory
-
exceptionPropagator
public org.cache2k.io.ExceptionPropagator exceptionPropagator
-
segmentCountOverride
public int segmentCountOverride
Override parameter for segment count. Has to be power of two, e.g. 2, 4, 8, etc. Invalid numbers will be replaced by the next higher power of two. Default is 0, no override.
-
timerLagMillis
public long timerLagMillis
-
-