Package org.apache.hadoop.hbase.quotas
Class RegionSizeImpl
java.lang.Object
org.apache.hadoop.hbase.quotas.RegionSizeImpl
- All Implemented Interfaces:
HeapSize
,RegionSize
An object encapsulating a Region's size and whether it's been reported to the master since the
value last changed.
-
Field Summary
Modifier and TypeFieldDescriptionprivate static final long
private static final org.slf4j.Logger
private final AtomicLong
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionlong
getSize()
Returns the size of the region.long
heapSize()
Return the approximate 'exclusive deep size' of implementing object.incrementSize
(long delta) Atomically adds the provideddelta
to the region size.setSize
(long newSize) Updates the size of the Region.
-
Field Details
-
LOG
-
HEAP_SIZE
-
size
-
-
Constructor Details
-
RegionSizeImpl
-
-
Method Details
-
heapSize
Description copied from interface:HeapSize
Return the approximate 'exclusive deep size' of implementing object. Includes count of payload and hosting object sizings. -
setSize
Description copied from interface:RegionSize
Updates the size of the Region.- Specified by:
setSize
in interfaceRegionSize
- Parameters:
newSize
- the new size of the Region- Returns:
this
-
incrementSize
Description copied from interface:RegionSize
Atomically adds the provideddelta
to the region size.- Specified by:
incrementSize
in interfaceRegionSize
- Parameters:
delta
- The change in size in bytes of the region.- Returns:
this
-
getSize
Description copied from interface:RegionSize
Returns the size of the region.- Specified by:
getSize
in interfaceRegionSize
- Returns:
- The size in bytes.
-