示例#1
0
 /**
  * This method is called in the Driver on every task. It updates counters and calls execute(),
  * which is overridden in each task
  *
  * @return return value of execute()
  */
 public int executeTask() {
   try {
     SessionState ss = SessionState.get();
     this.setStarted();
     if (ss != null) {
       ss.getHiveHistory().logPlanProgress(queryPlan);
     }
     int retval = execute(driverContext);
     this.setDone();
     if (ss != null) {
       ss.getHiveHistory().logPlanProgress(queryPlan);
     }
     return retval;
   } catch (IOException e) {
     throw new RuntimeException("Unexpected error: " + e.getMessage(), e);
   }
 }
示例#2
0
 @Override
 public void logPlanProgress(SessionState ss) throws IOException {
   ss.getHiveHistory().logPlanProgress(queryPlan);
 }