Package org.apache.hadoop.hbase.client
Class TestConnectionImplementation
java.lang.Object
org.apache.hadoop.hbase.client.TestConnectionImplementation
This class is for testing HBaseConnectionManager features
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
private static class
-
Field Summary
Modifier and TypeFieldDescriptionstatic final HBaseClassTestRule
private static final byte[]
private static final org.slf4j.Logger
org.junit.rules.TestName
private static final byte[]
private static final byte[]
private static final int
protected static final AtomicBoolean
private static final org.apache.hadoop.hbase.TableName
private static final org.apache.hadoop.hbase.TableName
private static final org.apache.hadoop.hbase.TableName
private static final org.apache.hadoop.hbase.TableName
private static final HBaseTestingUtility
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprivate static void
assertEqualsWithJitter
(long expected, long actual) private static void
assertEqualsWithJitter
(long expected, long actual, long jitterBase) private int
setNumTries
(org.apache.hadoop.hbase.client.ConnectionImplementation hci, int newVal) static void
void
tearDown()
static void
void
Naive test to check that Connection#getAdmin returns a properly constructed HBaseAdmin objectvoid
Test that stale cache updates don't override newer cached values.void
void
void
void
void
This test checks that one can connect to the cluster with only the ZooKeeper quorum set.private void
testConnectionClose
(boolean allowsInterrupt) void
Test that we can handle connection close: it will trigger a retry, but the calls will finish.void
Test that the connection to the dead server is cut immediately when we receive the notification.void
Test that connection can become idle without breaking everything.void
Test that Connection or Pool are not closed when managed externallyvoid
void
void
Trivial test to verify that nobody messes withConnectionFactory.createConnection(Configuration)
void
private void
testLocateRegionsRetrySpecialPause
(Class<? extends org.apache.hadoop.hbase.HBaseServerException> exceptionClass) void
void
void
void
void
void
Test that when we delete a location using the first row of a region that we really delete it.
-
Field Details
-
CLASS_RULE
-
LOG
-
TEST_UTIL
-
TABLE_NAME
-
TABLE_NAME1
-
TABLE_NAME2
-
TABLE_NAME3
-
FAM_NAM
-
ROW
-
ROW_X
-
RPC_RETRY
- See Also:
-
name
-
syncBlockingFilter
-
-
Constructor Details
-
TestConnectionImplementation
public TestConnectionImplementation()
-
-
Method Details
-
setUpBeforeClass
- Throws:
Exception
-
tearDownAfterClass
- Throws:
Exception
-
tearDown
- Throws:
IOException
-
testClusterConnection
- Throws:
IOException
-
testAdminFactory
Naive test to check that Connection#getAdmin returns a properly constructed HBaseAdmin object- Throws:
IOException
- Unable to construct admin
-
testClusterStatus
- Throws:
Exception
-
testConnectionCloseAllowsInterrupt
Test that we can handle connection close: it will trigger a retry, but the calls will finish.- Throws:
Exception
-
testConnectionNotAllowsInterrupt
- Throws:
Exception
-
testConnectionClose
- Throws:
Exception
-
testConnectionIdle
Test that connection can become idle without breaking everything.- Throws:
Exception
-
testConnectionCut
Test that the connection to the dead server is cut immediately when we receive the notification.- Throws:
Exception
-
testRegionCaching
Test that when we delete a location using the first row of a region that we really delete it.- Throws:
Exception
-
testConnectionManagement
Test that Connection or Pool are not closed when managed externally- Throws:
Exception
-
testCacheSeqNums
Test that stale cache updates don't override newer cached values.- Throws:
Exception
-
testClosing
- Throws:
Exception
-
testCreateConnection
Trivial test to verify that nobody messes withConnectionFactory.createConnection(Configuration)
- Throws:
Exception
-
testConnection
This test checks that one can connect to the cluster with only the ZooKeeper quorum set. Other stuff like master address will be read from ZK by the client.- Throws:
Exception
-
setNumTries
private int setNumTries(org.apache.hadoop.hbase.client.ConnectionImplementation hci, int newVal) throws Exception - Throws:
Exception
-
testMulti
- Throws:
Exception
-
testErrorBackoffTimeCalculation
- Throws:
Exception
-
assertEqualsWithJitter
-
assertEqualsWithJitter
-
testConnectionRideOverClusterRestart
- Throws:
IOException
InterruptedException
-
testLocateRegionsWithRegionReplicas
- Throws:
IOException
-
testLocateRegionsRetrySpecialPauseCQTBE
- Throws:
IOException
-
testLocateRegionsRetrySpecialPauseCDE
- Throws:
IOException
-
testLocateRegionsRetrySpecialPause
private void testLocateRegionsRetrySpecialPause(Class<? extends org.apache.hadoop.hbase.HBaseServerException> exceptionClass) throws IOException - Throws:
IOException
-
testMetaLookupThreadPoolCreated
- Throws:
Exception
-
testCancelConnectionMemoryLeak
- Throws:
IOException
InterruptedException
-