org.apache.tez.dag.records
Class TezTaskID

java.lang.Object
  extended by org.apache.tez.dag.records.TezID
      extended by org.apache.tez.dag.records.TezTaskID
All Implemented Interfaces:
Comparable<TezID>, org.apache.hadoop.io.Writable, org.apache.hadoop.io.WritableComparable<TezID>

@InterfaceAudience.Public
@InterfaceStability.Stable
public class TezTaskID
extends TezID

TaskID represents the immutable and unique identifier for a Tez Task. Each TaskID encompasses multiple attempts made to execute the Tez Task, each of which are uniquely identified by their TezTaskAttemptID.

See Also:
TezTaskAttemptID

Field Summary
static String TASK
           
 
Fields inherited from class org.apache.tez.dag.records.TezID
id, SEPARATOR
 
Constructor Summary
TezTaskID()
           
 
Method Summary
protected  StringBuilder appendTo(StringBuilder builder)
          Add the unique string to the given builder.
 int compareTo(TezID o)
          Compare TaskInProgressIds by first jobIds, then by tip numbers and type.
 boolean equals(Object o)
           
static TezTaskID fromString(String taskIdStr)
           
static TezTaskID getInstance(TezVertexID vertexID, int id)
          Constructs a TezTaskID object from given TezVertexID.
 TezVertexID getVertexID()
          Returns the TezVertexID object that this task belongs to
 int hashCode()
           
 void readFields(DataInput in)
           
static TezTaskID readTezTaskID(DataInput in)
           
 String toString()
           
 void write(DataOutput out)
           
 
Methods inherited from class org.apache.tez.dag.records.TezID
getId, readID
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

TASK

public static final String TASK
See Also:
Constant Field Values
Constructor Detail

TezTaskID

public TezTaskID()
Method Detail

getInstance

public static TezTaskID getInstance(TezVertexID vertexID,
                                    int id)
Constructs a TezTaskID object from given TezVertexID.

Parameters:
vertexID - the vertexID object for this TezTaskID
id - the tip number

getVertexID

public TezVertexID getVertexID()
Returns the TezVertexID object that this task belongs to


equals

public boolean equals(Object o)
Overrides:
equals in class TezID

compareTo

public int compareTo(TezID o)
Compare TaskInProgressIds by first jobIds, then by tip numbers and type.

Specified by:
compareTo in interface Comparable<TezID>
Overrides:
compareTo in class TezID

toString

public String toString()
Overrides:
toString in class TezID

appendTo

protected StringBuilder appendTo(StringBuilder builder)
Add the unique string to the given builder.

Parameters:
builder - the builder to append to
Returns:
the builder that was passed in

hashCode

public int hashCode()
Overrides:
hashCode in class TezID

readFields

public void readFields(DataInput in)
                throws IOException
Specified by:
readFields in interface org.apache.hadoop.io.Writable
Overrides:
readFields in class TezID
Throws:
IOException

readTezTaskID

public static TezTaskID readTezTaskID(DataInput in)
                               throws IOException
Throws:
IOException

write

public void write(DataOutput out)
           throws IOException
Specified by:
write in interface org.apache.hadoop.io.Writable
Overrides:
write in class TezID
Throws:
IOException

fromString

public static TezTaskID fromString(String taskIdStr)


Copyright © 2014 Apache Software Foundation. All rights reserved.