Class CompactedHFilesDischarger
java.lang.Object
org.apache.hadoop.hbase.ScheduledChore
org.apache.hadoop.hbase.regionserver.CompactedHFilesDischarger
- All Implemented Interfaces:
- Runnable
A chore service that periodically cleans up the compacted files when there are no active readers
 using those compacted files and also helps in clearing the block cache of these compacted file
 entries.
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate static final org.slf4j.Loggerprivate RegionServerServicesprivate boolean
- 
Constructor SummaryConstructorsConstructorDescriptionCompactedHFilesDischarger(int period, Stoppable stopper, RegionServerServices regionServerServices) CompactedHFilesDischarger(int period, Stoppable stopper, RegionServerServices regionServerServices, boolean useExecutor) 
- 
Method SummaryModifier and TypeMethodDescriptionvoidchore()The task to execute on each scheduled execution of the ChorebooleansetUseExecutor(boolean useExecutor) CompactedHFilesDischarger runs asynchronously by default using the hosting RegionServer's Executor.Methods inherited from class org.apache.hadoop.hbase.ScheduledChorecancel, cancel, choreForTesting, cleanup, getInitialDelay, getName, getPeriod, getStopper, getTimeUnit, initialChore, isInitialChoreComplete, isScheduled, run, shutdown, shutdown, toString, triggerNow
- 
Field Details- 
LOG
- 
regionServerServices
- 
useExecutor
 
- 
- 
Constructor Details- 
CompactedHFilesDischargerpublic CompactedHFilesDischarger(int period, Stoppable stopper, RegionServerServices regionServerServices) - Parameters:
- period- the period of time to sleep between each run
- stopper- the stopper
- regionServerServices- the region server that starts this chore
 
- 
CompactedHFilesDischargerpublic CompactedHFilesDischarger(int period, Stoppable stopper, RegionServerServices regionServerServices, boolean useExecutor) - Parameters:
- period- the period of time to sleep between each run
- stopper- the stopper
- regionServerServices- the region server that starts this chore
- useExecutor- true if to use the region server's executor service, false otherwise
 
 
- 
- 
Method Details- 
setUseExecutorCompactedHFilesDischarger runs asynchronously by default using the hosting RegionServer's Executor. In tests it can be useful to force a synchronous cleanup. Use this method to set no-executor before you call run.- Returns:
- The old setting for useExecutor
 
- 
choreDescription copied from class:ScheduledChoreThe task to execute on each scheduled execution of the Chore- Specified by:
- chorein class- ScheduledChore
 
 
-