public abstract class TestTableInputFormatScanBase
extends java.lang.Object
Tests various scan start and stop row scenarios. This is set in a scan and tested in a MapReduce job to see if that is handed over and done properly too.
This test is broken into two parts in order to side-step the test timeout period of 900, as documented in HBASE-8326.
| Modifier and Type | Class and Description |
|---|---|
static class |
TestTableInputFormatScanBase.ScanMapper
Pass the key and value to reduce.
|
static class |
TestTableInputFormatScanBase.ScanReducer
Checks the last and first key seen against the scanner boundaries.
|
| Constructor and Description |
|---|
TestTableInputFormatScanBase() |
| Modifier and Type | Method and Description |
|---|---|
static void |
setUpBeforeClass() |
static void |
tearDownAfterClass() |
void |
testAutobalanceNumOfSplit()
Run MR job to test autobalance for setting number of mappers for TIF
This does not run real MR job
|
void |
testNumOfSplits(int splitsPerRegion,
int expectedNumOfSplits)
Tests Number of inputSplits for MR job when specify number of mappers for TableInputFormatXXX
This test does not run MR job
|
void |
testNumOfSplitsMR(int splitsPerRegion,
int expectedNumOfSplits)
Run MR job to check the number of mapper = expectedNumOfSplits
|
protected void |
testScan(java.lang.String start,
java.lang.String stop,
java.lang.String last)
Tests a MR scan using specific start and stop rows.
|
protected void |
testScanFromConfiguration(java.lang.String start,
java.lang.String stop,
java.lang.String last)
Tests an MR Scan initialized from properties set in the Configuration.
|
public static void setUpBeforeClass()
throws java.lang.Exception
java.lang.Exceptionpublic static void tearDownAfterClass()
throws java.lang.Exception
java.lang.Exceptionprotected void testScanFromConfiguration(java.lang.String start,
java.lang.String stop,
java.lang.String last)
throws java.io.IOException,
java.lang.InterruptedException,
java.lang.ClassNotFoundException
java.io.IOExceptionjava.lang.ClassNotFoundExceptionjava.lang.InterruptedExceptionprotected void testScan(java.lang.String start,
java.lang.String stop,
java.lang.String last)
throws java.io.IOException,
java.lang.InterruptedException,
java.lang.ClassNotFoundException
java.io.IOExceptionjava.lang.ClassNotFoundExceptionjava.lang.InterruptedExceptionpublic void testNumOfSplits(int splitsPerRegion,
int expectedNumOfSplits)
throws java.io.IOException,
java.lang.InterruptedException,
java.lang.ClassNotFoundException
java.io.IOExceptionjava.lang.ClassNotFoundExceptionjava.lang.InterruptedExceptionpublic void testNumOfSplitsMR(int splitsPerRegion,
int expectedNumOfSplits)
throws java.io.IOException,
java.lang.InterruptedException,
java.lang.ClassNotFoundException
java.io.IOExceptionjava.lang.InterruptedExceptionjava.lang.ClassNotFoundExceptionpublic void testAutobalanceNumOfSplit()
throws java.io.IOException
java.io.IOException