Package org.apache.hadoop.mapred.FakeObjectUtilities

Examples of org.apache.hadoop.mapred.FakeObjectUtilities.FakeTaskInProgress


      final int numSlotsPerTask = 2;
      maps = new TaskInProgress[1];
      reduces = new TaskInProgress[1];
     
      maps[0] = new FakeTaskInProgress(getJobID(), "test"
          JobSplit.EMPTY_TASK_SPLIT,
          jobtracker, getJobConf(), this, 0, numSlotsPerTask);
      TaskAttemptID attemptId = new TaskAttemptID(maps[0].getTIPId(), 0);
     
      // make this task a taskCleanup task of a map task
      mapCleanupTasks.add(attemptId);
      TaskStatus stat = new MapTaskStatus(attemptId, 0.01f, 2,
          TaskStatus.State.FAILED_UNCLEAN, "", "", trackers[0],
          TaskStatus.Phase.MAP, new Counters());
      maps[0].updateStatus(stat);
     
      //similarly for reduce task's taskCleanup task
      reduces[0] = new FakeTaskInProgress(getJobID(), "test", 1,
          0, jobtracker, getJobConf(), this, numSlotsPerTask);
      attemptId = new TaskAttemptID(reduces[0].getTIPId(), 0);
     
      // make this task a taskCleanup task of a reduce task
      reduceCleanupTasks.add(attemptId);
View Full Code Here


      final int numSlotsPerTask = 2;
      maps = new TaskInProgress[1];
      reduces = new TaskInProgress[1];
     
      maps[0] = new FakeTaskInProgress(getJobID(), "test"
          JobSplit.EMPTY_TASK_SPLIT,
          jobtracker, getJobConf(), this, 0, numSlotsPerTask);
      TaskAttemptID attemptId = new TaskAttemptID(maps[0].getTIPId(), 0);
     
      // make this task a taskCleanup task of a map task
      mapCleanupTasks.add(attemptId);
      TaskStatus stat = new MapTaskStatus(attemptId, 0.01f, 2,
          TaskStatus.State.FAILED_UNCLEAN, "", "", trackers[0],
          TaskStatus.Phase.MAP, new Counters());
      maps[0].updateStatus(stat);
     
      //similarly for reduce task's taskCleanup task
      reduces[0] = new FakeTaskInProgress(getJobID(), "test", 1,
          0, jobtracker, getJobConf(), this, numSlotsPerTask);
      attemptId = new TaskAttemptID(reduces[0].getTIPId(), 0);
     
      // make this task a taskCleanup task of a reduce task
      reduceCleanupTasks.add(attemptId);
View Full Code Here

TOP

Related Classes of org.apache.hadoop.mapred.FakeObjectUtilities.FakeTaskInProgress

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.