Examples of TaskAttemptStartedEvent


Examples of org.apache.hadoop.mapreduce.jobhistory.TaskAttemptStartedEvent

        int port =
            httpPort.equals("") ? DEFAULT_HTTP_PORT : Integer
                .parseInt(httpPort);

        return new TaskAttemptStartedEvent(taskAttemptID,
            that.originalTaskType, that.originalStartTime, trackerName, port, -1,
            locality, avataar);
      }

      return null;
View Full Code Here

Examples of org.apache.hadoop.mapreduce.jobhistory.TaskAttemptStartedEvent

      taskAttempt.eventHandler.handle(jce);
     
      LOG.info("TaskAttempt: [" + taskAttempt.attemptId
          + "] using containerId: [" + taskAttempt.containerID + " on NM: ["
          + taskAttempt.containerMgrAddress + "]");
      TaskAttemptStartedEvent tase =
        new TaskAttemptStartedEvent(TypeConverter.fromYarn(taskAttempt.attemptId),
            TypeConverter.fromYarn(taskAttempt.attemptId.getTaskId().getTaskType()),
            taskAttempt.launchTime,
            nodeHttpInetAddr.getHostName(), nodeHttpInetAddr.getPort(),
            taskAttempt.shufflePort, taskAttempt.containerID);
      taskAttempt.eventHandler.handle
View Full Code Here

Examples of org.apache.hadoop.mapreduce.jobhistory.TaskAttemptStartedEvent

        int port =
            httpPort.equals("") ? DEFAULT_HTTP_PORT : Integer
                .parseInt(httpPort);

        return new TaskAttemptStartedEvent(taskAttemptID,
            that.originalTaskType, that.originalStartTime, trackerName, port, -1);
      }

      return null;
    }
View Full Code Here

Examples of org.apache.hadoop.mapreduce.jobhistory.TaskAttemptStartedEvent

    eventHandler.handle(jce);

    LOG.info("TaskAttempt: [" + attemptId
        + "] using containerId: [" + containerID + " on NM: ["
        + containerMgrAddress + "]");
    TaskAttemptStartedEvent tase =
      new TaskAttemptStartedEvent(TypeConverter.fromYarn(attemptId),
          TypeConverter.fromYarn(attemptId.getTaskId().getTaskType()),
          launchTime, trackerName, httpPort, shufflePort, containerID);
    eventHandler.handle(
        new JobHistoryEvent(attemptId.getTaskId().getJobId(), tase));
  }
View Full Code Here

Examples of org.apache.hadoop.mapreduce.jobhistory.TaskAttemptStartedEvent

      taskAttempt.eventHandler.handle(jce);
     
      LOG.info("TaskAttempt: [" + taskAttempt.attemptId
          + "] using containerId: [" + taskAttempt.containerID + " on NM: ["
          + taskAttempt.containerMgrAddress + "]");
      TaskAttemptStartedEvent tase =
        new TaskAttemptStartedEvent(TypeConverter.fromYarn(taskAttempt.attemptId),
            TypeConverter.fromYarn(taskAttempt.attemptId.getTaskId().getTaskType()),
            taskAttempt.launchTime,
            nodeHttpInetAddr.getHostName(), nodeHttpInetAddr.getPort(),
            taskAttempt.shufflePort, taskAttempt.containerID,
            taskAttempt.locality.toString(), taskAttempt.avataar.toString());
View Full Code Here

Examples of org.apache.hadoop.mapreduce.jobhistory.TaskAttemptStartedEvent

        int port =
            httpPort.equals("") ? DEFAULT_HTTP_PORT : Integer
                .parseInt(httpPort);

        return new TaskAttemptStartedEvent(taskAttemptID,
            that.originalTaskType, that.originalStartTime, trackerName, port);
      }

      return null;
    }
View Full Code Here

Examples of org.apache.hadoop.mapreduce.jobhistory.TaskAttemptStartedEvent

    TaskTrackerStatus ttStatus =
      this.jobtracker.getTaskTrackerStatus(status.getTaskTracker());
    String trackerHostname = jobtracker.getNode(ttStatus.getHost()).toString();
    TaskType taskType = getTaskType(tip);

    TaskAttemptStartedEvent tse = new TaskAttemptStartedEvent(
        status.getTaskID(), taskType, status.getStartTime(),
        status.getTaskTracker(),  ttStatus.getHttpPort());
   
    jobHistory.logEvent(tse, status.getTaskID().getJobID());
   
View Full Code Here

Examples of org.apache.hadoop.mapreduce.jobhistory.TaskAttemptStartedEvent

    long finishTime = taskStatus.getFinishTime();
    List<String> taskDiagnosticInfo = tip.getDiagnosticInfo(taskid);
    String diagInfo = taskDiagnosticInfo == null ? "" :
      StringUtils.arrayToString(taskDiagnosticInfo.toArray(new String[0]));
    TaskType taskType = getTaskType(tip);
    TaskAttemptStartedEvent tse = new TaskAttemptStartedEvent(
        taskid, taskType, startTime, taskTrackerName, taskTrackerPort);
   
    jobHistory.logEvent(tse, taskid.getJobID());
  
    TaskAttemptUnsuccessfulCompletionEvent tue =
View Full Code Here

Examples of org.apache.tez.dag.history.events.TaskAttemptStartedEvent

        }
        return recoveredState;
      }
      case TASK_ATTEMPT_STARTED:
      {
        TaskAttemptStartedEvent taskAttemptStartedEvent =
            (TaskAttemptStartedEvent) historyEvent;
        TaskAttempt recoveredAttempt = createRecoveredEvent(
            taskAttemptStartedEvent.getTaskAttemptID());
        recoveredAttempt.restoreFromEvent(taskAttemptStartedEvent);
        if (LOG.isDebugEnabled()) {
          LOG.debug("Adding restored attempt into known attempts map"
              + ", taskAttemptId=" + taskAttemptStartedEvent.getTaskAttemptID());
        }
        this.attempts.put(taskAttemptStartedEvent.getTaskAttemptID(),
            recoveredAttempt);
        ++numberUncompletedAttempts;
        this.recoveredState = TaskState.RUNNING;
        return recoveredState;
      }
View Full Code Here

Examples of org.apache.tez.dag.history.events.TaskAttemptStartedEvent

  @Override
  public TaskAttemptState restoreFromEvent(HistoryEvent historyEvent) {
    switch (historyEvent.getEventType()) {
      case TASK_ATTEMPT_STARTED:
      {
        TaskAttemptStartedEvent tEvent = (TaskAttemptStartedEvent) historyEvent;
        this.launchTime = tEvent.getStartTime();
        recoveryStartEventSeen = true;
        recoveredState = TaskAttemptState.RUNNING;
        return recoveredState;
      }
      case TASK_ATTEMPT_FINISHED:
      {
        if (!recoveryStartEventSeen) {
          throw new RuntimeException("Finished Event seen but"
              + " no Started Event was encountered earlier");
        }
        TaskAttemptFinishedEvent tEvent = (TaskAttemptFinishedEvent) historyEvent;
        this.finishTime = tEvent.getFinishTime();
        this.reportedStatus.counters = tEvent.getCounters();
        this.reportedStatus.progress = 1f;
        this.reportedStatus.state = tEvent.getState();
        this.diagnostics.add(tEvent.getDiagnostics());
        this.recoveredState = tEvent.getState();
        return recoveredState;
      }
      default:
        throw new RuntimeException("Unexpected event received for restoring"
            + " state, eventType=" + historyEvent.getEventType());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.