Class ShrinkerThread
java.lang.Object
org.apache.commons.jcs3.auxiliary.disk.jdbc.ShrinkerThread
- All Implemented Interfaces:
Runnable
Calls delete expired on the disk caches. The shrinker is run by a clock daemon. The shrinker
calls delete on each region. It pauses between calls.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addDiskCacheToShrinkList
(JDBCDiskCache<?, ?> diskCache) Adds a JDBC disk cache to the set of disk cache to shrink.long
How long should we wait between calls to deleteExpired when we are iterating through the list of regions.void
run()
Calls deleteExpired on each item in the set.void
setPauseBetweenRegionCallsMillis
(long pauseBetweenRegionCallsMillis) How long should we wait between calls to deleteExpired when we are iterating through the list of regions.
-
Constructor Details
-
ShrinkerThread
protected ShrinkerThread()Does nothing special.
-
-
Method Details
-
addDiskCacheToShrinkList
Adds a JDBC disk cache to the set of disk cache to shrink.- Parameters:
diskCache
-
-
run
Calls deleteExpired on each item in the set. It pauses between each call. -
setPauseBetweenRegionCallsMillis
How long should we wait between calls to deleteExpired when we are iterating through the list of regions.- Parameters:
pauseBetweenRegionCallsMillis
- The pauseBetweenRegionCallsMillis to set.
-
getPauseBetweenRegionCallsMillis
How long should we wait between calls to deleteExpired when we are iterating through the list of regions.- Returns:
- Returns the pauseBetweenRegionCallsMillis.
-