public class HBaseStatsPublisher extends Object implements StatsPublisher
Constructor and Description |
---|
HBaseStatsPublisher() |
Modifier and Type | Method and Description |
---|---|
boolean |
closeConnection()
This method closes the connection to the temporary storage.
|
boolean |
connect(org.apache.hadoop.conf.Configuration hiveconf)
Does the necessary HBase initializations.
|
boolean |
init(org.apache.hadoop.conf.Configuration hiveconf)
Does the necessary HBase initializations.
|
boolean |
publishStat(String rowID,
Map<String,String> stats)
Writes temporary statistics into HBase;
|
public boolean connect(org.apache.hadoop.conf.Configuration hiveconf)
connect
in interface StatsPublisher
hiveconf
- HiveConf that contains the connection parameters.public boolean publishStat(String rowID, Map<String,String> stats)
publishStat
in interface StatsPublisher
rowID
- : a string identification the statistics to be published by all mappers/reducers
and then gathered. The statID is unique per output partition per task, e.g.,:
the output directory name (uniq per FileSinkOperator) +
the partition specs (only for dynamic partitions) +
taskID (last component of task file)stats
- : a map containing key-value pairs, where key is a string representing the statistic
to be published,
and value is a string representing the value for the given statisticpublic boolean closeConnection()
StatsPublisher
closeConnection
in interface StatsPublisher
public boolean init(org.apache.hadoop.conf.Configuration hiveconf)
init
in interface StatsPublisher
hiveconf
- HiveConf that contains the configurations parameters used to connect to
intermediate stats database.Copyright © 2017 The Apache Software Foundation. All rights reserved.