Example #1
0
 public void readFields(DataInput in) throws IOException {
   numActiveTrackers = in.readInt();
   int numTrackerNames = in.readInt();
   if (numTrackerNames > 0) {
     for (int i = 0; i < numTrackerNames; i++) {
       String name = Text.readString(in);
       activeTrackers.add(name);
     }
   }
   numBlacklistedTrackers = in.readInt();
   int blackListTrackerInfoSize = in.readInt();
   if (blackListTrackerInfoSize > 0) {
     for (int i = 0; i < blackListTrackerInfoSize; i++) {
       BlackListInfo info = new BlackListInfo();
       info.readFields(in);
       blacklistedTrackersInfo.add(info);
     }
   }
   numExcludedNodes = in.readInt();
   ttExpiryInterval = in.readLong();
   map_tasks = in.readInt();
   reduce_tasks = in.readInt();
   max_map_tasks = in.readInt();
   max_reduce_tasks = in.readInt();
   used_memory = in.readLong();
   max_memory = in.readLong();
   state = WritableUtils.readEnum(in, JobTracker.State.class);
 }
Example #2
0
 @Override
 public void readFields(DataInput input) throws IOException {
   super.readFields(input);
   formatString = WritableUtils.readString(input);
   type = WritableUtils.readEnum(input, FunctionArgumentType.class);
   formatter = type.getFormatter(formatString);
 }
Example #3
0
 public void readFields(DataInput in) throws IOException {
   this.taskid.readFields(in);
   this.progress = in.readFloat();
   this.runState = WritableUtils.readEnum(in, State.class);
   this.diagnosticInfo = Text.readString(in);
   this.stateString = Text.readString(in);
   this.phase = WritableUtils.readEnum(in, Phase.class);
   this.startTime = in.readLong();
   this.finishTime = in.readLong();
   counters = new Counters();
   this.includeCounters = in.readBoolean();
   this.outputSize = in.readLong();
   if (includeCounters) {
     counters.readFields(in);
   }
   nextRecordRange.readFields(in);
   this.runOnGPU = in.readBoolean();
 }
Example #4
0
 @Override
 public void readFields(DataInput in) throws IOException {
   queueName = StringInterner.weakIntern(Text.readString(in));
   queueState = WritableUtils.readEnum(in, QueueState.class);
   schedulingInfo = StringInterner.weakIntern(Text.readString(in));
   int length = in.readInt();
   stats = new JobStatus[length];
   for (int i = 0; i < length; i++) {
     stats[i] = new JobStatus();
     stats[i].readFields(in);
   }
   int count = in.readInt();
   children.clear();
   for (int i = 0; i < count; i++) {
     QueueInfo childQueueInfo = new QueueInfo();
     childQueueInfo.readFields(in);
     children.add(childQueueInfo);
   }
 }
Example #5
0
  public void readFields(DataInput in) throws IOException {
    this.taskid.readFields(in);
    this.progress = in.readFloat();
    this.state = Text.readString(in);
    this.startTime = in.readLong();
    this.finishTime = in.readLong();

    diagnostics = WritableUtils.readStringArray(in);
    counters = new Counters();
    counters.readFields(in);
    currentStatus = WritableUtils.readEnum(in, TIPStatus.class);
    if (currentStatus == TIPStatus.RUNNING) {
      int num = WritableUtils.readVInt(in);
      for (int i = 0; i < num; i++) {
        TaskAttemptID t = new TaskAttemptID();
        t.readFields(in);
        runningAttempts.add(t);
      }
    } else if (currentStatus == TIPStatus.COMPLETE) {
      successfulAttempt.readFields(in);
    }
  }