RegionInfoBuilder to build RegionInfo.@Deprecated @InterfaceAudience.Public public class HRegionInfo extends Object implements RegionInfo
| Modifier and Type | Field and Description |
|---|---|
static String |
ENCODED_REGION_NAME_REGEX
Deprecated.
A non-capture group so that this can be embedded.
|
static HRegionInfo |
FIRST_META_REGIONINFO
Deprecated.
HRegionInfo for first meta region
|
static byte[] |
HIDDEN_END_KEY
Deprecated.
|
static byte[] |
HIDDEN_START_KEY
Deprecated.
|
static String |
NO_HASH
Deprecated.
|
| Constructor and Description |
|---|
HRegionInfo(HRegionInfo other,
int replicaId)
Deprecated.
|
HRegionInfo(long regionId,
TableName tableName,
int replicaId)
Deprecated.
|
HRegionInfo(RegionInfo other)
Deprecated.
Construct a copy of another HRegionInfo
|
HRegionInfo(TableName tableName)
Deprecated.
|
HRegionInfo(TableName tableName,
byte[] startKey,
byte[] endKey)
Deprecated.
Construct HRegionInfo with explicit parameters
|
HRegionInfo(TableName tableName,
byte[] startKey,
byte[] endKey,
boolean split)
Deprecated.
Construct HRegionInfo with explicit parameters
|
HRegionInfo(TableName tableName,
byte[] startKey,
byte[] endKey,
boolean split,
long regionId)
Deprecated.
Construct HRegionInfo with explicit parameters
|
HRegionInfo(TableName tableName,
byte[] startKey,
byte[] endKey,
boolean split,
long regionId,
int replicaId)
Deprecated.
Construct HRegionInfo with explicit parameters
|
| Modifier and Type | Method and Description |
|---|---|
static boolean |
areAdjacent(HRegionInfo regionA,
HRegionInfo regionB)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.areAdjacent(RegionInfo, RegionInfo). |
boolean |
containsRange(byte[] rangeStartKey,
byte[] rangeEndKey)
Deprecated.
Returns true if the given inclusive range of rows is fully contained by this region.
|
boolean |
containsRow(byte[] row)
Deprecated.
Returns true if the given row falls in this region.
|
static String |
encodeRegionName(byte[] regionName)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.encodeRegionName(byte[]). |
boolean |
equals(Object o)
Deprecated.
|
org.apache.hadoop.hbase.KeyValue.KVComparator |
getComparator()
Deprecated.
Use Region#getCellComparator(). deprecated for hbase 2.0, remove for hbase 3.0
|
String |
getEncodedName()
Deprecated.
Returns the encoded region name
|
byte[] |
getEncodedNameAsBytes()
Deprecated.
Returns the encoded region name as an array of bytes.
|
byte[] |
getEndKey()
Deprecated.
Returns the endKey
|
long |
getRegionId()
Deprecated.
Returns the regionId
|
byte[] |
getRegionName()
Deprecated.
Returns the regionName as an array of bytes.
|
String |
getRegionNameAsString()
Deprecated.
Returns Region name as a String for use in logging, etc.
|
int |
getReplicaId()
Deprecated.
Returns the region replica id
|
String |
getShortNameToLog()
Deprecated.
Returns Return a short, printable name for this region (usually encoded name) for us logging.
|
static String |
getShortNameToLog(HRegionInfo... hris)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.getShortNameToLog(RegionInfo...). |
static String |
getShortNameToLog(List<HRegionInfo> hris)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.getShortNameToLog(List))}. |
byte[] |
getStartKey()
Deprecated.
Returns the startKey
|
static byte[] |
getStartKey(byte[] regionName)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.getStartKey(byte[]). |
TableName |
getTable()
Deprecated.
Get current table name of the region n
|
static TableName |
getTable(byte[] regionName)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.getTable(byte[]). |
int |
hashCode()
Deprecated.
|
static boolean |
isEncodedRegionName(byte[] regionName)
Deprecated.
|
boolean |
isMetaRegion()
Deprecated.
Returns true if this region is a meta region
|
boolean |
isMetaTable()
Deprecated.
Returns true if this region is from hbase:meta
|
boolean |
isOffline()
Deprecated.
Returns true if this region is offline.
|
boolean |
isSplit()
Deprecated.
Returns true if has been split and has daughters.
|
boolean |
isSplitParent()
Deprecated.
Returns true if this is a split parent region.
|
boolean |
isSystemTable()
Deprecated.
Returns true if this region is from a system table
|
static List<HRegionInfo> |
parseDelimitedFrom(byte[] bytes,
int offset,
int length)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.parseDelimitedFrom(byte[], int, int). |
static HRegionInfo |
parseFrom(byte[] bytes)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.parseFrom(byte[]). |
static HRegionInfo |
parseFrom(byte[] bytes,
int offset,
int len)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.parseFrom(byte[], int, int). |
static HRegionInfo |
parseFromOrNull(byte[] bytes)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.parseFromOrNull(byte[]). |
static HRegionInfo |
parseFromOrNull(byte[] bytes,
int offset,
int len)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.parseFromOrNull(byte[], int, int). |
void |
setOffline(boolean offLine)
Deprecated.
The parent of a region split is offline while split daughters hold references to the parent.
|
void |
setSplit(boolean split)
Deprecated.
Set or clear the split status flag.
|
byte[] |
toByteArray()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.toByteArray(RegionInfo). |
byte[] |
toDelimitedByteArray()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0 Use
RegionInfo.toDelimitedByteArray(RegionInfo). |
String |
toString()
Deprecated.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, waitareAdjacent, compareTo, createMobRegionInfo, getShortNameToLog, getShortNameToLog, isAdjacent, isDegenerate, isFirst, isLast, isMD5Hash, isNext, isOverlap, parseRegionNameOrReturnNull, toByteArray, toDelimitedByteArray, toDelimitedByteArraypublic static final String ENCODED_REGION_NAME_REGEX
public static final byte[] HIDDEN_END_KEY
public static final byte[] HIDDEN_START_KEY
public static final HRegionInfo FIRST_META_REGIONINFO
public HRegionInfo(long regionId, TableName tableName, int replicaId)
public HRegionInfo(TableName tableName)
public HRegionInfo(TableName tableName, byte[] startKey, byte[] endKey) throws IllegalArgumentException
tableName - the table namestartKey - first key in regionendKey - end of key range nIllegalArgumentExceptionpublic HRegionInfo(TableName tableName, byte[] startKey, byte[] endKey, boolean split) throws IllegalArgumentException
tableName - the table namestartKey - first key in regionendKey - end of key rangesplit - true if this region has split and we have daughter regions regions that may or
may not hold references to this region. nIllegalArgumentExceptionpublic HRegionInfo(TableName tableName, byte[] startKey, byte[] endKey, boolean split, long regionId) throws IllegalArgumentException
tableName - the table namestartKey - first key in regionendKey - end of key rangesplit - true if this region has split and we have daughter regions regions that may or
may not hold references to this region.regionId - Region id to use.IllegalArgumentExceptionpublic HRegionInfo(TableName tableName, byte[] startKey, byte[] endKey, boolean split, long regionId, int replicaId) throws IllegalArgumentException
tableName - the table namestartKey - first key in regionendKey - end of key rangesplit - true if this region has split and we have daughter regions regions that may or
may not hold references to this region.regionId - Region id to use.replicaId - the replicaId to useIllegalArgumentExceptionpublic HRegionInfo(RegionInfo other)
public HRegionInfo(HRegionInfo other, int replicaId)
@Deprecated public static String encodeRegionName(byte[] regionName)
RegionInfo.encodeRegionName(byte[]).encodeRegionName in interface RegionInfopublic String getShortNameToLog()
getShortNameToLog in interface RegionInfo@Deprecated public static String getShortNameToLog(HRegionInfo... hris)
RegionInfo.getShortNameToLog(RegionInfo...).@Deprecated public static String getShortNameToLog(List<HRegionInfo> hris)
RegionInfo.getShortNameToLog(List))}.hris (usually encoded name)
for us logging.@Deprecated public static TableName getTable(byte[] regionName)
RegionInfo.getTable(byte[]).getTable in interface RegionInforegionName - to extract the table name from@Deprecated public static byte[] getStartKey(byte[] regionName) throws IOException
RegionInfo.getStartKey(byte[]).getStartKey in interface RegionInfoIOException@Deprecated public static boolean isEncodedRegionName(byte[] regionName) throws IOException
RegionInfo.isEncodedRegionName(byte[]).isEncodedRegionName in interface RegionInforegionName - A Region name either encoded or not.regionName represents an encoded name.IOExceptionpublic long getRegionId()
getRegionId in interface RegionInfopublic byte[] getRegionName()
RegionInfogetRegionName in interface RegionInfogetRegionNameAsString()public String getRegionNameAsString()
getRegionNameAsString in interface RegionInfopublic String getEncodedName()
getEncodedName in interface RegionInfopublic byte[] getEncodedNameAsBytes()
RegionInfogetEncodedNameAsBytes in interface RegionInfopublic byte[] getStartKey()
getStartKey in interface RegionInfopublic byte[] getEndKey()
getEndKey in interface RegionInfopublic TableName getTable()
getTable in interface RegionInfopublic boolean containsRange(byte[] rangeStartKey, byte[] rangeEndKey)
containsRange in interface RegionInfoIllegalArgumentException - if the range passed is invalid (ie. end < start)public boolean containsRow(byte[] row)
containsRow in interface RegionInfopublic boolean isMetaTable()
public boolean isMetaRegion()
isMetaRegion in interface RegionInfopublic boolean isSystemTable()
public boolean isSplit()
isSplit in interface RegionInfopublic void setSplit(boolean split)
split - set split statuspublic boolean isOffline()
isOffline in interface RegionInfopublic void setOffline(boolean offLine)
offLine - Set online/offline status.public boolean isSplitParent()
isSplitParent in interface RegionInfopublic int getReplicaId()
getReplicaId in interface RegionInfopublic String toString()
toString in class ObjectObject.toString()public boolean equals(Object o)
equals in class ObjectObject.equals(java.lang.Object)public int hashCode()
hashCode in class ObjectObject.hashCode()@Deprecated public org.apache.hadoop.hbase.KeyValue.KVComparator getComparator()
KeyValues.@Deprecated public byte[] toByteArray()
RegionInfo.toByteArray(RegionInfo).HRegionInfo into a byte array.parseFrom(byte[])@Deprecated public static HRegionInfo parseFromOrNull(byte[] bytes)
RegionInfo.parseFromOrNull(byte[]).HRegionInfo.parseFromOrNull in interface RegionInfoHRegionInfo or null if we failed deserialize or passed bytes
nulltoByteArray()@Deprecated public static HRegionInfo parseFromOrNull(byte[] bytes, int offset, int len)
RegionInfo.parseFromOrNull(byte[], int, int).HRegionInfo.parseFromOrNull in interface RegionInfoHRegionInfo or null if we failed deserialize or passed bytes
nulltoByteArray()public static HRegionInfo parseFrom(byte[] bytes) throws org.apache.hadoop.hbase.exceptions.DeserializationException
RegionInfo.parseFrom(byte[]).HRegionInfo.parseFrom in interface RegionInfobytes - A pb RegionInfo serialized with a pb magic prefix.HRegionInfo n * @see #toByteArray()org.apache.hadoop.hbase.exceptions.DeserializationException@Deprecated public static HRegionInfo parseFrom(byte[] bytes, int offset, int len) throws org.apache.hadoop.hbase.exceptions.DeserializationException
RegionInfo.parseFrom(byte[], int, int).HRegionInfo.parseFrom in interface RegionInfobytes - A pb RegionInfo serialized with a pb magic prefix.offset - starting point in the byte arraylen - length to read on the byte arrayHRegionInfo n * @see #toByteArray()org.apache.hadoop.hbase.exceptions.DeserializationException@Deprecated public byte[] toDelimitedByteArray() throws IOException
RegionInfo.toDelimitedByteArray(RegionInfo).toByteArray() when writing to a stream and you want to use the pb
mergeDelimitedFrom (w/o the delimiter, pb reads to EOF which may not be what you want).IOException@Deprecated public static List<HRegionInfo> parseDelimitedFrom(byte[] bytes, int offset, int length) throws IOException
RegionInfo.parseDelimitedFrom(byte[], int, int).toDelimitedByteArray()parseDelimitedFrom in interface RegionInfobytes - serialized bytesoffset - the start offset into the byte[] bufferlength - how far we should read into the byte[] bufferIOException@Deprecated public static boolean areAdjacent(HRegionInfo regionA, HRegionInfo regionB)
RegionInfo.areAdjacent(RegionInfo, RegionInfo).Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.