public void logReduceTaskKilled(TaskAttemptID taskAttemptId, long timestamp,
                                  String hostName, String error,
                                  String taskType) {
    if (disableHistory) {
      return;
    }

    JobID id = taskAttemptId.getJobID();
    if (!this.jobId.equals(id)) {
      throw new RuntimeException("JobId from task: " + id +
                                 " does not match expected: " + jobId);
    }

    if (null != writers) {
      log(writers, RecordTypes.ReduceAttempt,
          new Keys[]{  Keys.TASK_TYPE, Keys.TASKID,
                       Keys.TASK_ATTEMPT_ID, Keys.TASK_STATUS,
                       Keys.FINISH_TIME, Keys.HOSTNAME,
                       Keys.ERROR },
          new String[]{ taskType,
                        taskAttemptId.getTaskID().toString(),
                        taskAttemptId.toString(),
                        Values.KILLED.name(),
                        String.valueOf(timestamp),
                        hostName, error });
    }
  }
public void logReduceTaskKilled ( TaskAttemptID taskAttemptId , long timestamp , String hostName , String error , String taskType ) { if ( disableHistory ) { return ; } JobID id = taskAttemptId . getJobID ( ) ; if ( ! this . jobId . equals ( id ) ) { throw new RuntimeException ( "JobId from task: " + id + " does not match expected: " + jobId ) ; } if ( null != writers ) { log ( writers , RecordTypes . ReduceAttempt , new Keys [ ] { Keys . TASK_TYPE , Keys . TASKID , Keys . TASK_ATTEMPT_ID , Keys . TASK_STATUS , Keys . FINISH_TIME , Keys . HOSTNAME , Keys . ERROR } , new String [ ] { taskType , taskAttemptId . getTaskID ( ) . toString ( ) , taskAttemptId . toString ( ) , Values . KILLED . name ( ) , String . valueOf ( timestamp ) , hostName , error } ) ; } }
Log killed reduce task attempt.

@param taskAttemptId task attempt id
@param timestamp time stamp when task failed
@param hostName host name of the task attempt.
@param error error message of the task.
@param taskType Whether the attempt is cleanup or setup or reduce