public class TestTableInputFormat extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
TestTableInputFormat.ExampleDeprecatedTIF |
static class |
TestTableInputFormat.ExampleJobConfigurableTIF |
static class |
TestTableInputFormat.ExampleTIF |
static class |
TestTableInputFormat.ExampleVerifier |
| Modifier and Type | Field and Description |
|---|---|
static HBaseClassTestRule |
CLASS_RULE |
private static byte[][] |
columns |
(package private) static byte[] |
FAMILY |
private static org.slf4j.Logger |
LOG |
private static HBaseTestingUtility |
UTIL |
| Constructor and Description |
|---|
TestTableInputFormat() |
| Modifier and Type | Method and Description |
|---|---|
static void |
afterClass() |
void |
before() |
static void |
beforeClass() |
(package private) static boolean |
checkResult(org.apache.hadoop.hbase.client.Result r,
org.apache.hadoop.hbase.io.ImmutableBytesWritable key,
byte[] expectedKey,
byte[] expectedValue)
Verify that the result and key have expected values.
|
(package private) static org.apache.hadoop.hbase.client.Table |
createDNRIOEScannerTable(byte[] name,
int failCnt)
Create a table that throws a DoNoRetryIOException on first scanner next
call
|
(package private) static org.apache.hadoop.hbase.client.Table |
createIOEScannerTable(byte[] name,
int failCnt)
Create a table that IOE's on first scanner next call
|
static org.apache.hadoop.hbase.client.Table |
createTable(byte[] tableName)
Setup a table with two rows and values.
|
static org.apache.hadoop.hbase.client.Table |
createTable(byte[] tableName,
byte[][] families)
Setup a table with two rows and values per column family.
|
(package private) static void |
runTestMapred(org.apache.hadoop.hbase.client.Table table)
Create table data and run tests on specified htable using the
o.a.h.hbase.mapred API.
|
void |
testDeprecatedExtensionOfTableInputFormatBase() |
void |
testExtensionOfTableInputFormatBase()
Verify the example we present in javadocs on TableInputFormatBase
|
(package private) void |
testInputFormat(Class<? extends org.apache.hadoop.mapred.InputFormat> clazz) |
void |
testJobConfigurableExtensionOfTableInputFormatBase() |
void |
testTableRecordReader()
Run test assuming no errors using mapred api.
|
void |
testTableRecordReaderScannerFail()
Run test assuming Scanner IOException failure using mapred api,
|
void |
testTableRecordReaderScannerFailTwice()
Run test assuming Scanner IOException failure using mapred api,
|
void |
testTableRecordReaderScannerTimeout()
Run test assuming NotServingRegionException using mapred api.
|
void |
testTableRecordReaderScannerTimeoutTwice()
Run test assuming NotServingRegionException using mapred api.
|
public static final HBaseClassTestRule CLASS_RULE
private static final org.slf4j.Logger LOG
private static final HBaseTestingUtility UTIL
static final byte[] FAMILY
private static final byte[][] columns
public TestTableInputFormat()
public static void beforeClass() throws Exception
Exceptionpublic static void afterClass() throws Exception
Exceptionpublic void before() throws IOException
IOExceptionpublic static org.apache.hadoop.hbase.client.Table createTable(byte[] tableName) throws IOException
tableName - the name of the table to createIOExceptionpublic static org.apache.hadoop.hbase.client.Table createTable(byte[] tableName, byte[][] families) throws IOException
tableName - IOExceptionstatic boolean checkResult(org.apache.hadoop.hbase.client.Result r, org.apache.hadoop.hbase.io.ImmutableBytesWritable key, byte[] expectedKey, byte[] expectedValue)
r - single row resultkey - the row keyexpectedKey - the expected keyexpectedValue - the expected valuestatic void runTestMapred(org.apache.hadoop.hbase.client.Table table) throws IOException
table - IOExceptionstatic org.apache.hadoop.hbase.client.Table createIOEScannerTable(byte[] name, int failCnt) throws IOException
IOExceptionstatic org.apache.hadoop.hbase.client.Table createDNRIOEScannerTable(byte[] name, int failCnt) throws IOException
IOExceptionpublic void testTableRecordReader() throws IOException
IOExceptionpublic void testTableRecordReaderScannerFail() throws IOException
IOExceptionpublic void testTableRecordReaderScannerFailTwice() throws IOException
IOExceptionpublic void testTableRecordReaderScannerTimeout() throws IOException
org.apache.hadoop.hbase.DoNotRetryIOExceptionIOExceptionpublic void testTableRecordReaderScannerTimeoutTwice() throws IOException
org.apache.hadoop.hbase.DoNotRetryIOExceptionIOExceptionpublic void testExtensionOfTableInputFormatBase() throws IOException
IOExceptionpublic void testDeprecatedExtensionOfTableInputFormatBase() throws IOException
IOExceptionpublic void testJobConfigurableExtensionOfTableInputFormatBase() throws IOException
IOExceptionvoid testInputFormat(Class<? extends org.apache.hadoop.mapred.InputFormat> clazz) throws IOException
IOExceptionCopyright © 2007–2020 The Apache Software Foundation. All rights reserved.