public class TaskAttemptID extends TaskAttemptID
TaskID, that this TaskAttemptID belongs to.
Second part is the task attempt number. attempt_200707121733_0003_m_000005_0 , which represents the
zeroth task attempt for the fifth map task in the third job
running at the jobtracker started at 200707121733.
Applications should never construct or parse TaskAttemptID strings
, but rather use appropriate constructors or forName(String)
method.
ATTEMPT| Constructor and Description |
|---|
TaskAttemptID() |
TaskAttemptID(java.lang.String jtIdentifier,
int jobId,
boolean isMap,
int taskId,
int id)
Constructs a TaskId object from given parts.
|
TaskAttemptID(TaskID taskId,
int id)
Constructs a TaskAttemptID object from given
TaskID. |
| Modifier and Type | Method and Description |
|---|---|
static TaskAttemptID |
downgrade(TaskAttemptID old)
Downgrade a new TaskAttemptID to an old one
|
static TaskAttemptID |
forName(java.lang.String str)
Construct a TaskAttemptID object from given string
|
JobID |
getJobID()
Returns the
JobID object that this task attempt belongs to |
static java.lang.String |
getTaskAttemptIDsPattern(java.lang.String jtIdentifier,
java.lang.Integer jobId,
java.lang.Boolean isMap,
java.lang.Integer taskId,
java.lang.Integer attemptId)
Deprecated.
|
TaskID |
getTaskID()
Returns the
TaskID object that this task attempt belongs to |
static TaskAttemptID |
read(java.io.DataInput in)
Deprecated.
|
appendTo, compareTo, equals, getTaskType, hashCode, isMap, readFields, toString, writepublic TaskAttemptID(TaskID taskId, int id)
TaskID.taskId - TaskID that this task belongs toid - the task attempt numberpublic TaskAttemptID(java.lang.String jtIdentifier,
int jobId,
boolean isMap,
int taskId,
int id)
jtIdentifier - jobTracker identifierjobId - job numberisMap - whether the tip is a maptaskId - taskId numberid - the task attempt numberpublic TaskAttemptID()
public static TaskAttemptID downgrade(TaskAttemptID old)
old - the new idpublic TaskID getTaskID()
TaskAttemptIDTaskID object that this task attempt belongs togetTaskID in class TaskAttemptIDpublic JobID getJobID()
TaskAttemptIDJobID object that this task attempt belongs togetJobID in class TaskAttemptID@Deprecated public static TaskAttemptID read(java.io.DataInput in) throws java.io.IOException
java.io.IOExceptionpublic static TaskAttemptID forName(java.lang.String str) throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException - if the given string is malformed@Deprecated
public static java.lang.String getTaskAttemptIDsPattern(java.lang.String jtIdentifier,
java.lang.Integer jobId,
java.lang.Boolean isMap,
java.lang.Integer taskId,
java.lang.Integer attemptId)
TaskAttemptID.getTaskAttemptIDsPattern(null, null, true, 1, null);which will return :
"attempt_[^_]*_[0-9]*_m_000001_[0-9]*"
jtIdentifier - jobTracker identifier, or nulljobId - job number, or nullisMap - whether the tip is a map, or nulltaskId - taskId number, or nullattemptId - the task attempt number, or nullCopyright © 2009 The Apache Software Foundation