Class PressureAwareThroughputController
java.lang.Object
org.apache.hadoop.conf.Configured
org.apache.hadoop.hbase.regionserver.throttle.PressureAwareThroughputController
- All Implemented Interfaces:
org.apache.hadoop.conf.Configurable,ThroughputController,Stoppable
- Direct Known Subclasses:
PressureAwareCompactionThroughputController,PressureAwareFlushThroughputController
@LimitedPrivate("Configuration")
public abstract class PressureAwareThroughputController
extends org.apache.hadoop.conf.Configured
implements ThroughputController, Stoppable
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final classStores the information of one controlled compaction. -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final ConcurrentMap<String,PressureAwareThroughputController.ActiveOperation> protected longprivate static final org.slf4j.Loggerprivate doubleprotected longprivate doubleprotected longprotected OffPeakHoursprivate booleanprotected int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlongControl the throughput.voidFinish the controller.doublebooleanReturns True ifStoppable.stop(String)has been closed.voidsetMaxThroughput(double maxThroughput) abstract voidsetup(RegionServerServices server) Setup controller for the given region server.voidStart the throughput controller.voidStop this service.protected StringthroughputDesc(double speed) protected StringthroughputDesc(long deltaSize, long elapsedTime) Methods inherited from class org.apache.hadoop.conf.Configured
getConf, setConf
-
Field Details
-
LOG
-
maxThroughputUpperBound
-
maxThroughputLowerBound
-
offPeakHours
-
controlPerSize
-
tuningPeriod
-
maxThroughput
-
maxThroughputPerOperation
-
activeOperations
-
stopped
-
-
Constructor Details
-
PressureAwareThroughputController
public PressureAwareThroughputController()
-
-
Method Details
-
setup
Description copied from interface:ThroughputControllerSetup controller for the given region server.- Specified by:
setupin interfaceThroughputController
-
throughputDesc
-
throughputDesc
-
start
Description copied from interface:ThroughputControllerStart the throughput controller.- Specified by:
startin interfaceThroughputController
-
control
Description copied from interface:ThroughputControllerControl the throughput. Will sleep if too fast.- Specified by:
controlin interfaceThroughputController- Returns:
- the actual sleep time.
- Throws:
InterruptedException
-
finish
Description copied from interface:ThroughputControllerFinish the controller. Should call this method in a finally block.- Specified by:
finishin interfaceThroughputController
-
stop
Description copied from interface:StoppableStop this service. Implementers should favor logging errors over throwing RuntimeExceptions. -
isStopped
Description copied from interface:StoppableReturns True ifStoppable.stop(String)has been closed. -
getMaxThroughput
-
setMaxThroughput
-