Package org.apache.hadoop.hbase.quotas
Class RegionSizeReportingChore
java.lang.Object
org.apache.hadoop.hbase.ScheduledChore
org.apache.hadoop.hbase.quotas.RegionSizeReportingChore
- All Implemented Interfaces:
Runnable
A Chore which sends the region size reports on this RegionServer to the Master.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final org.slf4j.Loggerprivate final MetricsRegionServer(package private) static final long(package private) static final String(package private) static final int(package private) static final String(package private) static final String(package private) static final Stringprivate final RegionServerServices -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) void_chore()protected voidchore()The task to execute on each scheduled execution of the Chore(package private) static longgetInitialDelay(org.apache.hadoop.conf.Configuration conf) Extracts the initial delay for the chore from the configuration.(package private) HashSet<RegionInfo>getOnlineRegionInfos(List<? extends Region> onlineRegions) (package private) static intgetPeriod(org.apache.hadoop.conf.Configuration conf) Extracts the period for the chore from the configuration.(package private) static TimeUnitgetTimeUnit(org.apache.hadoop.conf.Configuration conf) Extracts the time unit for the chore period and initial delay from the configuration.(package private) voidremoveNonOnlineRegions(RegionSizeStore store, Set<RegionInfo> onlineRegions) Methods inherited from class org.apache.hadoop.hbase.ScheduledChore
cancel, cancel, choreForTesting, cleanup, getInitialDelay, getName, getPeriod, getStopper, getTimeUnit, initialChore, isInitialChoreComplete, isScheduled, run, shutdown, shutdown, toString, triggerNow
-
Field Details
-
LOG
-
REGION_SIZE_REPORTING_CHORE_PERIOD_KEY
- See Also:
-
REGION_SIZE_REPORTING_CHORE_PERIOD_DEFAULT
- See Also:
-
REGION_SIZE_REPORTING_CHORE_DELAY_KEY
- See Also:
-
REGION_SIZE_REPORTING_CHORE_DELAY_DEFAULT
- See Also:
-
REGION_SIZE_REPORTING_CHORE_TIMEUNIT_KEY
- See Also:
-
REGION_SIZE_REPORTING_CHORE_TIMEUNIT_DEFAULT
-
rsServices
-
metrics
-
-
Constructor Details
-
RegionSizeReportingChore
-
-
Method Details
-
chore
Description copied from class:ScheduledChoreThe task to execute on each scheduled execution of the Chore- Specified by:
chorein classScheduledChore
-
_chore
void _chore() -
getOnlineRegionInfos
-
removeNonOnlineRegions
-
getPeriod
Extracts the period for the chore from the configuration.- Parameters:
conf- The configuration object.- Returns:
- The configured chore period or the default value.
-
getInitialDelay
Extracts the initial delay for the chore from the configuration.- Parameters:
conf- The configuration object.- Returns:
- The configured chore initial delay or the default value.
-
getTimeUnit
Extracts the time unit for the chore period and initial delay from the configuration. The configuration value forREGION_SIZE_REPORTING_CHORE_TIMEUNIT_KEYmust correspond to aTimeUnitvalue.- Parameters:
conf- The configuration object.- Returns:
- The configured time unit for the chore period and initial delay or the default value.
-