public void setExitVal(int exitVal) {
    this.exitVal = exitVal;
    setRunning(false);
  }
TaskResult implementation.
Note that different threads may be reading/writing this object
ql/src/java/org/apache/hadoop/hive/ql/exec/TaskResult.java