public class DualUtil extends Object
| 限定符和类型 | 字段和说明 |
|---|---|
static String |
DUAL_CONFIG_GLITCH |
static String |
DUAL_CONFIG_SEP |
static String |
DUAL_TABLE |
static String |
DUALTABLE_DIR |
static String |
DUALTABLE_DIR_DEFATULT |
static String |
DUALTABLE_FILE |
static String |
DUALTABLE_FILE_DEFAULT |
| 构造器和说明 |
|---|
DualUtil() |
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
flushDualTables(List<String> dualTables,
org.apache.hadoop.conf.Configuration clientConf)
flush dual tables to user home dir, if can not dual tables from endpoint
get dual tables from disk
|
static List<String> |
getDualTablesFromXML(org.apache.hadoop.conf.Configuration conf)
if can not get dualtables from endpoint get dualtables from xml
|
static List<String> |
getDualTablesFromXML(String file)
get dualtables from xml
|
static List<String> |
getDualTablesFromZK(String endpoint,
org.apache.hadoop.conf.Configuration clientConf)
Get DualTables from zk
|
static String |
getDualTraceMetrics(byte[] data) |
static org.apache.hadoop.hbase.zookeeper.ZKWatcher |
getZookeeperWatcher(String endpoint) |
static void |
setDualTraceToZK(org.apache.hadoop.hbase.zookeeper.ZKWatcher zk,
String endpoint,
org.apache.hadoop.conf.Configuration clientConf,
String nodeName,
String metrics)
set dual trace to zk
|
static List<String> |
toDualTables(byte[] data) |
static byte[] |
toDualTablesBytes(List<String> dualTables) |
static byte[] |
toDualTraceBytes(String metrics) |
public static List<String> toDualTables(byte[] data) throws IOException
IOExceptionpublic static List<String> getDualTablesFromZK(String endpoint, org.apache.hadoop.conf.Configuration clientConf) throws IOException, org.apache.zookeeper.KeeperException
endpoint - IOExceptionorg.apache.zookeeper.KeeperExceptionpublic static List<String> getDualTablesFromXML(org.apache.hadoop.conf.Configuration conf)
public static List<String> getDualTablesFromXML(String file)
file - public static void flushDualTables(List<String> dualTables, org.apache.hadoop.conf.Configuration clientConf)
dualTables - public static void setDualTraceToZK(org.apache.hadoop.hbase.zookeeper.ZKWatcher zk,
String endpoint,
org.apache.hadoop.conf.Configuration clientConf,
String nodeName,
String metrics)
throws IOException,
org.apache.zookeeper.KeeperException
endpoint - IOExceptionorg.apache.zookeeper.KeeperExceptionpublic static org.apache.hadoop.hbase.zookeeper.ZKWatcher getZookeeperWatcher(String endpoint) throws IOException
IOExceptionpublic static byte[] toDualTraceBytes(String metrics)
public static String getDualTraceMetrics(byte[] data) throws IOException
IOExceptionCopyright © 2019. All rights reserved.