////////////////////////////////////////////// // Writable ////////////////////////////////////////////// /// <exception cref="System.IO.IOException"/> public virtual void Write(DataOutput @out) { taskid.Write(@out); @out.WriteFloat(progress); Text.WriteString(@out, state); @out.WriteLong(startTime); @out.WriteLong(finishTime); WritableUtils.WriteStringArray(@out, diagnostics); counters.Write(@out); WritableUtils.WriteEnum(@out, currentStatus); if (currentStatus == TIPStatus.Running) { WritableUtils.WriteVInt(@out, runningAttempts.Count); TaskAttemptID[] t = new TaskAttemptID[0]; t = Sharpen.Collections.ToArray(runningAttempts, t); for (int i = 0; i < t.Length; i++) { t[i].Write(@out); } } else { if (currentStatus == TIPStatus.Complete) { successfulAttempt.Write(@out); } } }
////////////////////////////////////////////// // Writable ////////////////////////////////////////////// /// <exception cref="System.IO.IOException"/> public virtual void Write(DataOutput @out) { taskId.Write(@out); WritableUtils.WriteVInt(@out, idWithinJob); @out.WriteBoolean(isMap); WritableUtils.WriteEnum(@out, status); WritableUtils.WriteString(@out, taskTrackerHttp); WritableUtils.WriteVInt(@out, taskRunTime); WritableUtils.WriteVInt(@out, eventId); }