Package org.apache.hadoop.mapred.CoronaStateUpdate

Examples of org.apache.hadoop.mapred.CoronaStateUpdate.TaskLaunch


        new HashMap<TaskAttemptID, TaskStatus.State>();
    JTFailoverMetrics jtFailoverMetrics = new JTFailoverMetrics();
   
    for (CoronaStateUpdate update : updates) {
      if (update.getTaskLaunch() != null) {
        TaskLaunch launch = update.getTaskLaunch();
        lastLaunch.put(launch.getTaskId(), launch);
      } else if (update.getTaskStatus() != null) {
        TaskStatus status = update.getTaskStatus();
        lastKnownStatus.put(status.getTaskID(), status.getRunState());
        jtFailoverMetrics.update(status);
      }
    }
    StringBuilder result = new StringBuilder();
    result.append("CoronaJTState report");
    if (jobId != null) {
      result.append(" for job ").append(jobId);
    }
    for (CoronaStateUpdate update : updates) {
      TaskLaunch launch = update.getTaskLaunch();
      if (launch != null) {
        result.append("\n").append(launch).append(" last known ");
        result.append(lastKnownStatus.get(launch.getTaskId()));
      }
    }
    if (sessionId != null && !sessionId.isEmpty()) {
      result.append("\n Session id ").append(sessionId);
    }
View Full Code Here


      taskLookupTable.createTaskEntry(taskId, trackerName, tip, grant.getId());
      if (localJTSubmitter.canSubmit()) {
        // Push status update before actual launching to ensure that we're
        // aware of this task after restarting
        try {
          localJTSubmitter.submit(new TaskLaunch(taskId, trackerName,
              new InetSocketAddress(addr.host, addr.port), tip, grant));
        } catch (IOException e) {
          LOG.error("Failed to submit task launching update for task "
              + taskId);
        }
View Full Code Here

          jtFailoverMetrics.update(status);
          continue;
        }
        // Set non-existing grants in every attempt, prepare mapping from
        // grant to last attempt that was using this grant
        TaskLaunch launch = update.getTaskLaunch();
        if (launch != null) {
          Integer grant = launch.getGrantId();
          // assign non-existing grant, we will kill all the unfinished tasks
          launch.setGrantId(ResourceTracker.getNoneGrantId());
          taskLaunchTrackers.add(launch.getTrackerName());
          continue;
        }
        // Save tracker info for replaying task status
        TaskTrackerInfo info = update.getTrackerInfo();
        if (info != null) {
View Full Code Here

            // it is safe for us to kill more uncertain tasks
            LOG.error("Skipping status " + status + " because of null TaskTracker info");
          }
          continue;
        }
        TaskLaunch launch = update.getTaskLaunch();
        if (launch != null) {
          LOG.info("Restoring launch " + launch);
          remoteJT.restoreTaskLaunch(launch);
          continue;
        }
View Full Code Here

TOP

Related Classes of org.apache.hadoop.mapred.CoronaStateUpdate.TaskLaunch

Copyright © 2018 www.massapicom. 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.