Class TestHRegion
java.lang.Object
org.apache.hadoop.hbase.regionserver.TestHRegion
- Direct Known Subclasses:
TestHRegionWithInMemoryFlush
Basic stand-alone testing of HRegion. No clusters! A lot of the meta information for an HRegion
now lives inside other HRegions or in the HBaseMaster, so only basic testing is possible.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static classTestCase for appendprotected class(package private) classstatic classThe same as HRegion class, the only difference is that instantiateHStore will create a different HStore - HStoreForTesting.(package private) static classstatic classHStoreForTesting is merely the same as HStore, the difference is in the doCompaction method of HStoreForTesting there is a checkpoint "hbase.hstore.compaction.complete" which doesn't let hstore compaction complete.private static classTestCase for increment(package private) static classstatic classprotected class -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final HBaseClassTestRuleprivate static final Stringprivate static final byte[]static org.apache.hadoop.conf.Configurationprivate Stringprivate static org.apache.hadoop.fs.FileSystemprivate static final org.apache.hbase.thirdparty.io.netty.channel.EventLoopGroupprivate static final org.slf4j.Loggerprivate final intprotected Stringprotected final MetricsAssertHelperorg.junit.rules.TestNameprotected final byte[]protected final byte[]protected final byte[]protected final byte[](package private) org.apache.hadoop.hbase.regionserver.HRegionprotected final byte[]protected final byte[]protected org.apache.hadoop.hbase.TableNameprotected static HBaseTestingUtilityfinal org.junit.rules.ExpectedExceptionprotected final byte[]protected final byte[]protected final byte[] -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static voidassertGet(org.apache.hadoop.hbase.regionserver.HRegion r, byte[] family, byte[] k) protected voidassertScan(org.apache.hadoop.hbase.regionserver.HRegion r, byte[] fs, byte[] firstValue) private org.apache.hadoop.hbase.regionserver.InternalScannerbuildScanner(String keyPrefix, String value, org.apache.hadoop.hbase.regionserver.HRegion r) private voidcheckOneCell(org.apache.hadoop.hbase.Cell kv, byte[] cf, int rowIdx, int colIdx, long ts) Assert that the passed in Cell has expected contents for the specified row, column & timestamp.private voidcheckScan(int expectCellSize) private static org.apache.hadoop.hbase.wal.WALcreateWALCompatibleWithFaultyFileSystem(String callingMethod, org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.hbase.TableName tableName) Create a WAL outside of the usual helper inHBaseTestingUtility.createWal(Configuration, Path, RegionInfo)because that method doesn't play nicely with FaultyFileSystem.(package private) static org.apache.hadoop.hbase.wal.WALFactorycreateWALFactory(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.Path rootDir) private voiddeleteColumns(org.apache.hadoop.hbase.regionserver.HRegion r, String value, String keyPrefix) voiddoTestDelete_AndPostInsert(org.apache.hadoop.hbase.client.Delete delete) private voiddurabilityTest(String method, org.apache.hadoop.hbase.client.Durability tableDurability, org.apache.hadoop.hbase.client.Durability mutationDurability, long timeout, boolean expectAppend, boolean expectSync, boolean expectSyncFromLogSyncer) private intgetNumberOfRows(String keyPrefix, String value, org.apache.hadoop.hbase.regionserver.HRegion r) protected intSo can be overridden in subclasses.protected intSo can be overridden in subclasses.private org.apache.hadoop.hbase.regionserver.HRegioninitHRegion(org.apache.hadoop.hbase.TableName tableName, byte[] startKey, byte[] stopKey, String callingMethod, org.apache.hadoop.conf.Configuration conf, boolean isReadOnly, byte[]... families) protected org.apache.hadoop.hbase.regionserver.HRegioninitHRegion(org.apache.hadoop.hbase.TableName tableName, byte[] startKey, byte[] stopKey, org.apache.hadoop.conf.Configuration conf, boolean isReadOnly, org.apache.hadoop.hbase.client.Durability durability, org.apache.hadoop.hbase.wal.WAL wal, byte[]... families) private org.apache.hadoop.hbase.regionserver.HRegioninitHRegion(org.apache.hadoop.hbase.TableName tableName, String callingMethod, byte[]... families) private org.apache.hadoop.hbase.regionserver.HRegioninitHRegion(org.apache.hadoop.hbase.TableName tableName, String callingMethod, org.apache.hadoop.conf.Configuration conf, boolean isReadOnly, byte[]... families) protected org.apache.hadoop.hbase.regionserver.HRegioninitHRegion(org.apache.hadoop.hbase.TableName tableName, String callingMethod, org.apache.hadoop.conf.Configuration conf, byte[]... families) protected org.apache.hadoop.conf.Configurationprivate org.apache.hadoop.hbase.wal.WALmockWAL()Utility method to setup a WAL mock.private longprepareRegionForBachPut(org.apache.hadoop.hbase.client.Put[] puts, org.apache.hadoop.hbase.regionserver.wal.MetricsWALSource source, boolean slop) Returns syncs initial syncTimeNumOpsprivate voidputData(int startRow, int numRows, byte[] qf, byte[]... families) private voidputData(org.apache.hadoop.hbase.regionserver.HRegion region, int startRow, int numRows, byte[] qf, byte[]... families) (package private) static voidputData(org.apache.hadoop.hbase.regionserver.HRegion region, org.apache.hadoop.hbase.client.Durability durability, int startRow, int numRows, byte[] qf, byte[]... families) private voidvoidsetup()voidtearDown()voidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidDeprecated.voidvoidvoidvoidDeprecated.voidDeprecated.voidDeprecated.voidDeprecated.voidDeprecated.voidDeprecated.voidDeprecated.voidDeprecated.voidvoidvoidvoidvoidvoidvoidvoidDeprecated.voidDeprecated.voidvoidvoidvoidvoidvoidTest for Bug 2 of HBASE-10466.voidvoidvoidvoidvoidvoidvoidprivate static voidtestDataInMemoryWithoutWAL(org.apache.hadoop.hbase.regionserver.HRegion region, org.apache.hadoop.hbase.client.Put originalPut, org.apache.hadoop.hbase.client.Put addPut, long delta) voidvoidvoidvoidvoidvoidTestcase to cover bug-fix for HBASE-2823 Ensures correct delete when issuing delete row on columns with bloom filter set to row+col (BloomType.ROWCOL)voidvoidvoidvoidA test case of HBASE-21041voidFlushes the cache in a thread while scanning.voidvoidvoidvoidTest that we get the expected flush results backvoidTest we do not lose data if we fail a flush and then close.voidvoidvoidvoidvoidvoidvoidvoidThis method tests https://issues.apache.org/jira/browse/HBASE-2516.voidvoidvoidvoidvoidvoidvoidvoidWrite an HFile block full with Cells whose qualifier that are identical between 0 and Short.MAX_VALUE.voidvoidvoidvoidvoidvoidvoidTest case to check append function with memstore flushingvoidTest case to check increment function with memstore flushingvoidTests that the special LATEST_TIMESTAMP option for puts gets replaced by the actual timestampvoidTest case to check put function with memstore flushing for same row, same tsvoidTests that there is server-side filtering for invalid timestamp upper bound.voidvoidtestRecoveredEditsReplayCompaction(boolean mismatchedRegionName) voidVerifies that the .regioninfo file is written on region creation and that is recreated if missing during region opening.voidvoidvoidvoidvoidvoidTest RegionTooBusyException thrown when region is busyvoidvoidvoidvoidvoidvoidvoidvoidTest for HBASE-14497: Reverse Scan threw StackOverflow caused by readPt checkingvoidvoidvoidvoidvoidvoidvoidAdded for HBASE-5416 Here we test scan optimization when only subset of CFs are used in filter conditions.voidHBASE-5416 Test case when scan limits amount of KVs returned on each next() call.voidvoidvoidvoidvoidvoidTest that I can use the max flushed sequence id after the close.voidvoidvoidvoidvoidTestcase to check state of region initialization task set to ABORTED or not if any exceptions during initializationvoidvoidvoidvoidvoidWrites very wide records and gets the latest row every time..voidHBASE-16429 Make sure no stuck if roll writer when ring buffer is filled with appendsvoidWrites very wide records and scans for the latest every time..(package private) static voidverifyData(org.apache.hadoop.hbase.regionserver.HRegion newReg, int startRow, int numRows, byte[] qf, byte[]... families) private voidwaitForCounter(org.apache.hadoop.hbase.regionserver.wal.MetricsWALSource source, String metricName, long expectedCount)
-
Field Details
-
CLASS_RULE
-
LOG
-
name
-
thrown
-
COLUMN_FAMILY
- See Also:
-
COLUMN_FAMILY_BYTES
-
GROUP
-
region
org.apache.hadoop.hbase.regionserver.HRegion region -
TEST_UTIL
-
CONF
-
dir
-
FILESYSTEM
-
MAX_VERSIONS
- See Also:
-
tableName
-
method
-
qual
-
qual1
-
qual2
-
qual3
-
value
-
value1
-
value2
-
row
-
row2
-
metricsAssertHelper
-
-
Constructor Details
-
TestHRegion
public TestHRegion()
-
-
Method Details
-
setup
- Throws:
IOException
-
tearDown
- Throws:
IOException
-
testSequenceId
Test that I can use the max flushed sequence id after the close.- Throws:
IOException
-
testCloseCarryingSnapshot
Test for Bug 2 of HBASE-10466. "Bug 2: Conditions for the first flush of region close (so-called pre-flush) If memstoreSize is smaller than a certain value, or when region close starts a flush is ongoing, the first flush is skipped and only the second flush takes place. However, two flushes are required in case previous flush fails and leaves some data in snapshot. The bug could cause loss of data in current memstore. The fix is removing all conditions except abort check so we ensure 2 flushes for region close."- Throws:
IOException
-
testMemstoreSnapshotSize
- Throws:
IOException
-
createWALCompatibleWithFaultyFileSystem
private static org.apache.hadoop.hbase.wal.WAL createWALCompatibleWithFaultyFileSystem(String callingMethod, org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.hbase.TableName tableName) throws IOException Create a WAL outside of the usual helper inHBaseTestingUtility.createWal(Configuration, Path, RegionInfo)because that method doesn't play nicely with FaultyFileSystem. Call this method before overridingfs.file.impl.- Parameters:
callingMethod- a unique component for the path, probably the name of the test method.- Throws:
IOException
-
testMemstoreSizeAccountingWithFailedPostBatchMutate
- Throws:
IOException
-
testFlushAndMemstoreSizeCounting
A test case of HBASE-21041- Throws:
Exception
-
testFlushSizeAccounting
Test we do not lose data if we fail a flush and then close. Part of HBase-10466. Tests the following from the issue description: "Bug 1: Wrong calculation of HRegion.memstoreSize: When a flush fails, data to be flushed is kept in each MemStore's snapshot and wait for next flush attempt to continue on it. But when the next flush succeeds, the counter of total memstore size in HRegion is always deduced by the sum of current memstore sizes instead of snapshots left from previous failed flush. This calculation is problematic that almost every time there is failed flush, HRegion.memstoreSize gets reduced by a wrong value. If region flush could not proceed for a couple cycles, the size in current memstore could be much larger than the snapshot. It's likely to drift memstoreSize much smaller than expected. In extreme case, if the error accumulates to even bigger than HRegion's memstore size limit, any further flush is skipped because flush does not do anything if memstoreSize is not larger than 0."- Throws:
Exception
-
testCloseWithFailingFlush
- Throws:
Exception
-
testCompactionAffectedByScanners
- Throws:
Exception
-
testToShowNPEOnRegionScannerReseek
- Throws:
Exception
-
testArchiveRecoveredEditsReplay
- Throws:
Exception
-
testSkipRecoveredEditsReplay
- Throws:
Exception
-
testSkipRecoveredEditsReplaySomeIgnored
- Throws:
Exception
-
testSkipRecoveredEditsReplayAllIgnored
- Throws:
Exception
-
testSkipRecoveredEditsReplayTheLastFileIgnored
- Throws:
Exception
-
testRecoveredEditsReplayCompaction
- Throws:
Exception
-
testRecoveredEditsReplayCompaction
- Throws:
Exception
-
testFlushMarkers
- Throws:
Exception
-
testFlushMarkersWALFail
- Throws:
Exception
-
testGetWhileRegionClose
- Throws:
IOException
-
testWeirdCacheBehaviour
- Throws:
Exception
-
testAppendWithReadOnlyTable
- Throws:
Exception
-
testIncrWithReadOnlyTable
- Throws:
Exception
-
deleteColumns
private void deleteColumns(org.apache.hadoop.hbase.regionserver.HRegion r, String value, String keyPrefix) throws IOException - Throws:
IOException
-
getNumberOfRows
private int getNumberOfRows(String keyPrefix, String value, org.apache.hadoop.hbase.regionserver.HRegion r) throws Exception - Throws:
Exception
-
buildScanner
private org.apache.hadoop.hbase.regionserver.InternalScanner buildScanner(String keyPrefix, String value, org.apache.hadoop.hbase.regionserver.HRegion r) throws IOException - Throws:
IOException
-
putRows
private void putRows(org.apache.hadoop.hbase.regionserver.HRegion r, int numRows, String value, String key) throws IOException - Throws:
IOException
-
testFamilyWithAndWithoutColon
- Throws:
Exception
-
testBatchPut_whileNoRowLocksHeld
- Throws:
IOException
-
testBatchPut_whileMultipleRowLocksHeld
- Throws:
Exception
-
waitForCounter
private void waitForCounter(org.apache.hadoop.hbase.regionserver.wal.MetricsWALSource source, String metricName, long expectedCount) throws InterruptedException - Throws:
InterruptedException
-
testAtomicBatchPut
- Throws:
IOException
-
testBatchPutWithTsSlop
- Throws:
Exception
-
prepareRegionForBachPut
private long prepareRegionForBachPut(org.apache.hadoop.hbase.client.Put[] puts, org.apache.hadoop.hbase.regionserver.wal.MetricsWALSource source, boolean slop) throws IOException Returns syncs initial syncTimeNumOps- Throws:
IOException
-
testCheckAndMutate_WithEmptyRowValue
Deprecated.- Throws:
IOException
-
testCheckAndMutate_WithWrongValue
Deprecated.- Throws:
IOException
-
testCheckAndMutate_WithCorrectValue
Deprecated.- Throws:
IOException
-
testCheckAndMutate_WithNonEqualCompareOp
Deprecated.- Throws:
IOException
-
testCheckAndPut_ThatPutWasWritten
Deprecated.- Throws:
IOException
-
testCheckAndPut_wrongRowInPut
Deprecated.- Throws:
IOException
-
testCheckAndDelete_ThatDeleteWasWritten
Deprecated.- Throws:
IOException
-
testCheckAndMutate_WithFilters
Deprecated.- Throws:
Throwable
-
testCheckAndMutate_WithFiltersAndTimeRange
Deprecated.- Throws:
Throwable
-
testCheckAndMutate_wrongMutationType
Deprecated.- Throws:
Throwable
-
testCheckAndMutate_wrongRow
Deprecated.- Throws:
Throwable
-
testCheckAndMutateWithEmptyRowValue
- Throws:
IOException
-
testCheckAndMutateWithWrongValue
- Throws:
IOException
-
testCheckAndMutateWithCorrectValue
- Throws:
IOException
-
testCheckAndMutateWithNonEqualCompareOp
- Throws:
IOException
-
testCheckAndPutThatPutWasWritten
- Throws:
IOException
-
testCheckAndDeleteThatDeleteWasWritten
- Throws:
IOException
-
testCheckAndMutateWithFilters
- Throws:
Throwable
-
testCheckAndMutateWithFiltersAndTimeRange
- Throws:
Throwable
-
testCheckAndIncrement
- Throws:
Throwable
-
testCheckAndAppend
- Throws:
Throwable
-
testCheckAndIncrementAndAppend
- Throws:
Throwable
-
testCheckAndRowMutations
- Throws:
Throwable
-
testDelete_multiDeleteColumn
- Throws:
IOException
-
testDelete_CheckFamily
- Throws:
IOException
-
testDelete_mixed
- Throws:
IOExceptionInterruptedException
-
testDeleteRowWithFutureTs
- Throws:
IOException
-
testPutWithLatestTS
Tests that the special LATEST_TIMESTAMP option for puts gets replaced by the actual timestamp- Throws:
IOException
-
testPutWithTsSlop
Tests that there is server-side filtering for invalid timestamp upper bound. Note that the timestamp lower bound is automatically handled for us by the TTL field.- Throws:
IOException
-
testScanner_DeleteOneFamilyNotAnother
- Throws:
IOException
-
testDataInMemoryWithoutWAL
- Throws:
IOException
-
testDataInMemoryWithoutWAL
private static void testDataInMemoryWithoutWAL(org.apache.hadoop.hbase.regionserver.HRegion region, org.apache.hadoop.hbase.client.Put originalPut, org.apache.hadoop.hbase.client.Put addPut, long delta) throws IOException - Throws:
IOException
-
testDeleteColumns_PostInsert
- Throws:
IOExceptionInterruptedException
-
testaddFamily_PostInsert
- Throws:
IOExceptionInterruptedException
-
doTestDelete_AndPostInsert
public void doTestDelete_AndPostInsert(org.apache.hadoop.hbase.client.Delete delete) throws IOException, InterruptedException - Throws:
IOExceptionInterruptedException
-
testDelete_CheckTimestampUpdated
- Throws:
IOException
-
testGet_FamilyChecker
- Throws:
IOException
-
testGet_Basic
- Throws:
IOException
-
testGet_Empty
- Throws:
IOException
-
testGetWithFilter
- Throws:
IOExceptionInterruptedException
-
testGetScanner_WithOkFamilies
- Throws:
IOException
-
testGetScanner_WithNotOkFamilies
- Throws:
IOException
-
testGetScanner_WithNoFamilies
- Throws:
IOException
-
testGetScanner_WithRegionClosed
This method tests https://issues.apache.org/jira/browse/HBASE-2516.- Throws:
IOException
-
testRegionScanner_Next
- Throws:
IOException
-
testScanner_ExplicitColumns_FromMemStore_EnforceVersions
- Throws:
IOException
-
testScanner_ExplicitColumns_FromFilesOnly_EnforceVersions
- Throws:
IOException
-
testScanner_ExplicitColumns_FromMemStoreAndFiles_EnforceVersions
- Throws:
IOException
-
testScanner_Wildcard_FromMemStore_EnforceVersions
- Throws:
IOException
-
testScanner_Wildcard_FromFilesOnly_EnforceVersions
- Throws:
IOException
-
testScanner_StopRow1542
- Throws:
IOException
-
testScanner_Wildcard_FromMemStoreAndFiles_EnforceVersions
- Throws:
IOException
-
testScanner_JoinedScanners
Added for HBASE-5416 Here we test scan optimization when only subset of CFs are used in filter conditions.- Throws:
IOException
-
testScanner_JoinedScannersWithLimits
HBASE-5416 Test case when scan limits amount of KVs returned on each next() call.- Throws:
IOException
-
testScannerOperationId
- Throws:
IOException
-
testLongQualifier
Write an HFile block full with Cells whose qualifier that are identical between 0 and Short.MAX_VALUE. See HBASE-13329.- Throws:
Exception
-
testFlushCacheWhileScanning
Flushes the cache in a thread while scanning. The tests verify that the scan is coherent - e.g. the returned results are always of the same or later update as the previous results. scan / compact thread join- Throws:
IOExceptionInterruptedException
-
getNumQualifiersForTestWritesWhileScanning
So can be overridden in subclasses. -
getTestCountForTestWritesWhileScanning
So can be overridden in subclasses. -
testWritesWhileScanning
Writes very wide records and scans for the latest every time.. Flushes and compacts the region every now and then to keep things realistic. by flush / scan / compaction when joining threads- Throws:
IOExceptionInterruptedException
-
testCloseAndArchiveCompactedFiles
- Throws:
IOException
-
testWritesWhileGetting
Writes very wide records and gets the latest row every time.. Flushes and compacts the region aggressivly to catch issues. by flush / scan / compaction when joining threads- Throws:
Exception
-
testHolesInMeta
- Throws:
Exception
-
testIndexesScanWithOneDeletedRow
- Throws:
IOException
-
testBloomFilterSize
- Throws:
IOException
-
testAllColumnsWithBloomFilter
- Throws:
IOException
-
testDeleteRowWithBloomFilter
Testcase to cover bug-fix for HBASE-2823 Ensures correct delete when issuing delete row on columns with bloom filter set to row+col (BloomType.ROWCOL)- Throws:
IOException
-
testgetHDFSBlocksDistribution
- Throws:
Exception
-
testStatusSettingToAbortIfAnyExceptionDuringRegionInitilization
Testcase to check state of region initialization task set to ABORTED or not if any exceptions during initialization- Throws:
Exception
-
testRegionInfoFileCreation
Verifies that the .regioninfo file is written on region creation and that is recreated if missing during region opening.- Throws:
IOException
-
testParallelIncrementWithMemStoreFlush
Test case to check increment function with memstore flushing- Throws:
Exception
-
testParallelAppendWithMemStoreFlush
Test case to check append function with memstore flushing- Throws:
Exception
-
testPutWithMemStoreFlush
Test case to check put function with memstore flushing for same row, same ts- Throws:
Exception
-
testDurability
- Throws:
Exception
-
durabilityTest
private void durabilityTest(String method, org.apache.hadoop.hbase.client.Durability tableDurability, org.apache.hadoop.hbase.client.Durability mutationDurability, long timeout, boolean expectAppend, boolean expectSync, boolean expectSyncFromLogSyncer) throws Exception - Throws:
Exception
-
testRegionReplicaSecondary
- Throws:
IOException
-
testRegionReplicaSecondaryIsReadOnly
- Throws:
IOException
-
createWALFactory
static org.apache.hadoop.hbase.wal.WALFactory createWALFactory(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.Path rootDir) throws IOException - Throws:
IOException
-
testCompactionFromPrimary
- Throws:
IOException
-
putData
- Throws:
IOException
-
putData
private void putData(org.apache.hadoop.hbase.regionserver.HRegion region, int startRow, int numRows, byte[] qf, byte[]... families) throws IOException - Throws:
IOException
-
putData
static void putData(org.apache.hadoop.hbase.regionserver.HRegion region, org.apache.hadoop.hbase.client.Durability durability, int startRow, int numRows, byte[] qf, byte[]... families) throws IOException - Throws:
IOException
-
verifyData
static void verifyData(org.apache.hadoop.hbase.regionserver.HRegion newReg, int startRow, int numRows, byte[] qf, byte[]... families) throws IOException - Throws:
IOException
-
assertGet
static void assertGet(org.apache.hadoop.hbase.regionserver.HRegion r, byte[] family, byte[] k) throws IOException - Throws:
IOException
-
assertScan
protected void assertScan(org.apache.hadoop.hbase.regionserver.HRegion r, byte[] fs, byte[] firstValue) throws IOException - Throws:
IOException
-
testFlushResult
Test that we get the expected flush results back- Throws:
IOException
-
initSplit
-
initHRegion
protected org.apache.hadoop.hbase.regionserver.HRegion initHRegion(org.apache.hadoop.hbase.TableName tableName, String callingMethod, org.apache.hadoop.conf.Configuration conf, byte[]... families) throws IOException - Returns:
- A region on which you must call
HBaseTestingUtility.closeRegionAndWAL(HRegion)when done. - Throws:
IOException
-
initHRegion
private org.apache.hadoop.hbase.regionserver.HRegion initHRegion(org.apache.hadoop.hbase.TableName tableName, String callingMethod, org.apache.hadoop.conf.Configuration conf, boolean isReadOnly, byte[]... families) throws IOException - Returns:
- A region on which you must call
HBaseTestingUtility.closeRegionAndWAL(HRegion)when done. - Throws:
IOException
-
initHRegion
private org.apache.hadoop.hbase.regionserver.HRegion initHRegion(org.apache.hadoop.hbase.TableName tableName, byte[] startKey, byte[] stopKey, String callingMethod, org.apache.hadoop.conf.Configuration conf, boolean isReadOnly, byte[]... families) throws IOException - Throws:
IOException
-
initHRegion
protected org.apache.hadoop.hbase.regionserver.HRegion initHRegion(org.apache.hadoop.hbase.TableName tableName, byte[] startKey, byte[] stopKey, org.apache.hadoop.conf.Configuration conf, boolean isReadOnly, org.apache.hadoop.hbase.client.Durability durability, org.apache.hadoop.hbase.wal.WAL wal, byte[]... families) throws IOException - Returns:
- A region on which you must call
HBaseTestingUtility.closeRegionAndWAL(HRegion)when done. - Throws:
IOException
-
checkOneCell
private void checkOneCell(org.apache.hadoop.hbase.Cell kv, byte[] cf, int rowIdx, int colIdx, long ts) Assert that the passed in Cell has expected contents for the specified row, column & timestamp. -
testReverseScanner_FromMemStore_SingleCF_Normal
- Throws:
IOException
-
testReverseScanner_FromMemStore_SingleCF_LargerKey
- Throws:
IOException
-
testReverseScanner_FromMemStore_SingleCF_FullScan
- Throws:
IOException
-
testReverseScanner_moreRowsMayExistAfter
- Throws:
IOException
-
testReverseScanner_smaller_blocksize
- Throws:
IOException
-
testReverseScanner_FromMemStoreAndHFiles_MultiCFs1
- Throws:
IOException
-
testReverseScanner_FromMemStoreAndHFiles_MultiCFs2
- Throws:
IOException
-
testReverseScanner_StackOverflow
Test for HBASE-14497: Reverse Scan threw StackOverflow caused by readPt checking- Throws:
IOException
-
testReverseScanShouldNotScanMemstoreIfReadPtLesser
- Throws:
Exception
-
testReverseScanWhenPutCellsAfterOpenReverseScan
- Throws:
Exception
-
testWriteRequestsCounter
- Throws:
IOException
-
testOpenRegionWrittenToWAL
- Throws:
Exception
-
testFlushedFileWithNoTags
- Throws:
Exception
-
mockWAL
Utility method to setup a WAL mock. Needs to do the bit where we close latch on the WALKeyImpl on append else test hangs.- Returns:
- a mock WAL
- Throws:
IOException
-
testCloseRegionWrittenToWAL
- Throws:
Exception
-
testRegionTooBusy
Test RegionTooBusyException thrown when region is busy- Throws:
IOException
-
testCellTTLs
- Throws:
IOException
-
testTTLsUsingSmallHeartBeatCells
- Throws:
IOException
-
checkScan
- Throws:
IOException
-
testIncrementTimestampsAreMonotonic
- Throws:
IOException
-
testAppendTimestampsAreMonotonic
- Throws:
IOException
-
testCheckAndMutateTimestampsAreMonotonic
- Throws:
IOException
-
testBatchMutateWithWrongRegionException
- Throws:
Exception
-
testBatchMutateWithZeroRowLockWait
- Throws:
Exception
-
testCheckAndRowMutateTimestampsAreMonotonic
- Throws:
IOException
-
initHRegion
private org.apache.hadoop.hbase.regionserver.HRegion initHRegion(org.apache.hadoop.hbase.TableName tableName, String callingMethod, byte[]... families) throws IOException - Throws:
IOException
-
testWritesWhileRollWriter
HBASE-16429 Make sure no stuck if roll writer when ring buffer is filled with appends- Throws:
IOException- if IO error occurred during test
-
testMutateRow
- Throws:
Exception
-
testMutateRowInParallel
- Throws:
Exception
-
testMutateRow_WriteRequestCount
- Throws:
Exception
-
testBulkLoadReplicationEnabled
- Throws:
IOException
-
testCloseNoInterrupt
- Throws:
Exception
-
testCloseInterrupt
- Throws:
Exception
-
testCloseAbort
- Throws:
Exception
-
testInterruptProtection
- Throws:
Exception
-
testRegionOnCoprocessorsChange
- Throws:
IOException
-
testRegionOnCoprocessorsWithoutChange
- Throws:
IOException
-