public class TestZKUtil extends Object
Modifier and Type | Class and Description |
---|---|
private static class |
TestZKUtil.WarnOnlyAbortable |
Modifier and Type | Field and Description |
---|---|
static HBaseClassTestRule |
CLASS_RULE |
private static org.slf4j.Logger |
LOG |
private static HBaseZKTestingUtility |
UTIL |
private static org.apache.hadoop.hbase.zookeeper.ZKWatcher |
ZKW |
Constructor and Description |
---|
TestZKUtil() |
Modifier and Type | Method and Description |
---|---|
private int |
getZNodeDataVersion(String znode) |
static void |
setUp() |
static void |
tearDown() |
void |
testCreateSilentIsReallySilent()
A test for HBASE-3238
|
void |
testCreateWithParents()
Create a znode with data
|
void |
testGetChildDataAndWatchForNewChildrenShouldNotThrowNPE()
Test should not fail with NPE when getChildDataAndWatchForNewChildren invoked with wrongNode
|
void |
testSetDataWithVersion() |
void |
testZNodeDeletes()
Create a bunch of znodes in a hierarchy, try deleting one that has childs (it will fail), then
delete it recursively, then delete the last znode
|
public static final HBaseClassTestRule CLASS_RULE
private static final org.slf4j.Logger LOG
private static HBaseZKTestingUtility UTIL
private static org.apache.hadoop.hbase.zookeeper.ZKWatcher ZKW
public TestZKUtil()
public static void tearDown() throws IOException
IOException
public void testCreateWithParents() throws org.apache.zookeeper.KeeperException, InterruptedException
org.apache.zookeeper.KeeperException
InterruptedException
public void testZNodeDeletes() throws Exception
Exception
private int getZNodeDataVersion(String znode) throws org.apache.zookeeper.KeeperException
org.apache.zookeeper.KeeperException
public void testSetDataWithVersion() throws Exception
Exception
public void testCreateSilentIsReallySilent() throws InterruptedException, org.apache.zookeeper.KeeperException, IOException
IOException
- A connection attempt to zk failedInterruptedException
- One of the non ZKUtil actions was interruptedorg.apache.zookeeper.KeeperException
- Any of the zookeeper connections had a KeeperExceptionpublic void testGetChildDataAndWatchForNewChildrenShouldNotThrowNPE() throws Exception
Exception
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.