Package org.apache.hadoop.hbase
Class MetaMockingUtil
java.lang.Object
org.apache.hadoop.hbase.MetaMockingUtil
Mocking utility for common hbase:meta functionality
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic org.apache.hadoop.hbase.client.Result
getMetaTableRowResult
(org.apache.hadoop.hbase.client.RegionInfo region, org.apache.hadoop.hbase.ServerName sn, org.apache.hadoop.hbase.client.RegionInfo splita, org.apache.hadoop.hbase.client.RegionInfo splitb) Returns a Result object constructed from the given region information simulating a catalog table result.static org.apache.hadoop.hbase.client.Result
getMetaTableRowResult
(org.apache.hadoop.hbase.HRegionInfo region) Returns a Result object constructed from the given region information simulating a catalog table result.static org.apache.hadoop.hbase.client.Result
getMetaTableRowResult
(org.apache.hadoop.hbase.HRegionInfo region, org.apache.hadoop.hbase.ServerName sn) Returns a Result object constructed from the given region information simulating a catalog table result.
-
Constructor Details
-
MetaMockingUtil
public MetaMockingUtil()
-
-
Method Details
-
getMetaTableRowResult
public static org.apache.hadoop.hbase.client.Result getMetaTableRowResult(org.apache.hadoop.hbase.HRegionInfo region) throws IOException Returns a Result object constructed from the given region information simulating a catalog table result.- Parameters:
region
- the HRegionInfo object or null- Returns:
- A mocked up Result that fakes a Get on a row in the
hbase:meta
table. - Throws:
IOException
-
getMetaTableRowResult
public static org.apache.hadoop.hbase.client.Result getMetaTableRowResult(org.apache.hadoop.hbase.HRegionInfo region, org.apache.hadoop.hbase.ServerName sn) throws IOException Returns a Result object constructed from the given region information simulating a catalog table result.- Parameters:
region
- the HRegionInfo object or nullsn
- to use making startcode and server hostname:port in meta or null- Returns:
- A mocked up Result that fakes a Get on a row in the
hbase:meta
table. - Throws:
IOException
-
getMetaTableRowResult
public static org.apache.hadoop.hbase.client.Result getMetaTableRowResult(org.apache.hadoop.hbase.client.RegionInfo region, org.apache.hadoop.hbase.ServerName sn, org.apache.hadoop.hbase.client.RegionInfo splita, org.apache.hadoop.hbase.client.RegionInfo splitb) throws IOException Returns a Result object constructed from the given region information simulating a catalog table result.- Parameters:
region
- the HRegionInfo object or nullsn
- to use making startcode and server hostname:port in meta or nullsplita
- daughter region or nullsplitb
- daughter region or null- Returns:
- A mocked up Result that fakes a Get on a row in the
hbase:meta
table. - Throws:
IOException
-