org.apache.hadoop.hive.ql.history.HiveHistory.getHistFileName()方法的使用及代码示例

x33g5p2x  于2022-01-20 转载在 其他  
字(3.5k)|赞(0)|评价(0)|浏览(65)

本文整理了Java中org.apache.hadoop.hive.ql.history.HiveHistory.getHistFileName()方法的一些代码示例,展示了HiveHistory.getHistFileName()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。HiveHistory.getHistFileName()方法的具体详情如下:
包路径:org.apache.hadoop.hive.ql.history.HiveHistory
类名称:HiveHistory
方法名:getHistFileName

HiveHistory.getHistFileName介绍

暂无

代码示例

代码示例来源:origin: apache/hive

/**
 * Update the history if set hive.session.history.enabled
 *
 * @param historyEnabled
 * @param ss
 */
public void updateHistory(boolean historyEnabled, SessionState ss) {
 if (historyEnabled) {
  // Uses a no-op proxy
  if (ss.hiveHist.getHistFileName() == null) {
   ss.hiveHist = new HiveHistoryImpl(ss);
  }
 } else {
  if (ss.hiveHist.getHistFileName() != null) {
   ss.hiveHist = HiveHistoryProxyHandler.getNoOpHiveHistoryProxy();
  }
 }
}

代码示例来源:origin: apache/drill

/**
 * Update the history if set hive.session.history.enabled
 *
 * @param historyEnabled
 * @param ss
 */
public void updateHistory(boolean historyEnabled, SessionState ss) {
 if (historyEnabled) {
  // Uses a no-op proxy
  if (ss.hiveHist.getHistFileName() == null) {
   ss.hiveHist = new HiveHistoryImpl(ss);
  }
 } else {
  if (ss.hiveHist.getHistFileName() != null) {
   ss.hiveHist = HiveHistoryProxyHandler.getNoOpHiveHistoryProxy();
  }
 }
}

代码示例来源:origin: anjuke/hwi

protected boolean init() {
  hiveConf = new HiveConf(SessionState.class);
  SessionState.start(hiveConf);
  historyFile = SessionState.get().getHiveHistory().getHistFileName();
  qs = QueryStore.getInstance();
  JobDataMap map = context.getJobDetail().getJobDataMap();
  int mqueryId = map.getIntValue("mqueryId");
  mquery = QueryStore.getInstance().getById(mqueryId);
  if (mquery == null) {
    l4j.error("MQuery<" + mqueryId + "> is missing");
    return false;
  }
  
  resultDir = hiveConf.get("hive.hwi.result", "/user/hive/result");
  String initHQL = hiveConf.get("hive.hwi.inithqls", "");
  if (!"".equals(initHQL)) {
    initHQLs = initHQL.split(";");
  }
  return true;
}

代码示例来源:origin: com.github.hyukjinkwon/hive-hwi

historyFile = SessionState.get().getHiveHistory().getHistFileName();
l4j.debug("HWISessionItem itemInit Complete " + getSessionName());
status = WebSessionItemStatus.READY;

代码示例来源:origin: org.apache.hadoop.hive/hive-hwi

/**
 * This is the initialization process that is carried out for each
 * SessionItem. The goal is to emulate the startup of CLIDriver.
 */
private void itemInit() {
 l4j.debug("HWISessionItem itemInit start " + getSessionName());
 OptionsProcessor oproc = new OptionsProcessor();
 if (System.getProperty("hwi-args") != null) {
  String[] parts = System.getProperty("hwi-args").split("\\s+");
  if (!oproc.process_stage1(parts)) {
  }
 }
 SessionState.initHiveLog4j();
 conf = new HiveConf(SessionState.class);
 ss = new CliSessionState(conf);
 SessionState.start(ss);
 queries.add("set hadoop.job.ugi=" + auth.getUser() + ","
   + auth.getGroups()[0]);
 queries.add("set user.name=" + auth.getUser());
 /*
  * HiveHistoryFileName will not be accessible outside this thread. We must
  * capture this now.
  */
 historyFile = SessionState.get().getHiveHistory().getHistFileName();
 l4j.debug("HWISessionItem itemInit Complete " + getSessionName());
 status = WebSessionItemStatus.READY;
 synchronized (runnable) {
  runnable.notifyAll();
 }
}

代码示例来源:origin: edu.berkeley.cs.shark/hive-hwi

historyFile = SessionState.get().getHiveHistory().getHistFileName();
l4j.debug("HWISessionItem itemInit Complete " + getSessionName());
status = WebSessionItemStatus.READY;

代码示例来源:origin: org.spark-project.hive/hive-hwi

historyFile = SessionState.get().getHiveHistory().getHistFileName();
l4j.debug("HWISessionItem itemInit Complete " + getSessionName());
status = WebSessionItemStatus.READY;

相关文章