public class ExecutionVertex extends Object implements AccessExecutionVertex, Archiveable<ArchivedExecutionVertex>
Execution
.Constructor and Description |
---|
ExecutionVertex(ExecutionJobVertex jobVertex,
int subTaskIndex,
IntermediateResult[] producedDataSets,
Time timeout) |
ExecutionVertex(ExecutionJobVertex jobVertex,
int subTaskIndex,
IntermediateResult[] producedDataSets,
Time timeout,
int maxPriorExecutionHistoryLength) |
ExecutionVertex(ExecutionJobVertex jobVertex,
int subTaskIndex,
IntermediateResult[] producedDataSets,
Time timeout,
long createTimestamp,
int maxPriorExecutionHistoryLength) |
Modifier and Type | Method and Description |
---|---|
ArchivedExecutionVertex |
archive() |
void |
cachePartitionInfo(PartialInputChannelDeploymentDescriptor partitionInfo) |
void |
cancel() |
void |
connectSource(int inputNumber,
IntermediateResult source,
JobEdge edge,
int consumerNumber) |
void |
deployToSlot(SimpleSlot slot) |
void |
fail(Throwable t) |
SimpleSlot |
getCurrentAssignedResource() |
TaskManagerLocation |
getCurrentAssignedResourceLocation()
Returns the
TaskManagerLocation for this execution vertex. |
Execution |
getCurrentExecutionAttempt()
Returns the current execution for this execution vertex.
|
ExecutionGraph |
getExecutionGraph() |
ExecutionState |
getExecutionState()
Returns the current
ExecutionState for this execution vertex. |
Throwable |
getFailureCause() |
String |
getFailureCauseAsString()
Returns the exception that caused the job to fail.
|
ExecutionEdge[] |
getInputEdges(int input) |
JobID |
getJobId() |
ExecutionJobVertex |
getJobVertex() |
JobVertexID |
getJobvertexId() |
CoLocationConstraint |
getLocationConstraint() |
int |
getMaxParallelism() |
int |
getNumberOfInputs() |
int |
getParallelSubtaskIndex()
Returns the subtask index of this execution vertex.
|
Iterable<TaskManagerLocation> |
getPreferredLocations()
Gets the location preferences of this task, determined by the locations of the predecessors from which
it receives input data.
|
Execution |
getPriorExecutionAttempt(int attemptNumber)
Returns the execution for the given attempt number.
|
Map<IntermediateResultPartitionID,IntermediateResultPartition> |
getProducedPartitions() |
String |
getSimpleName()
Creates a simple name representation in the style 'taskname (x/y)', where
'taskname' is the name as returned by
getTaskName() , 'x' is the parallel
subtask index as returned by getParallelSubtaskIndex() + 1 , and 'y' is the total
number of tasks, as returned by getTotalNumberOfParallelSubtasks() . |
long |
getStateTimestamp(ExecutionState state)
Returns the timestamp for the given
ExecutionState . |
String |
getTaskName() |
String |
getTaskNameWithSubtaskIndex()
Returns the name of this execution vertex in the format "myTask (2/7)".
|
int |
getTotalNumberOfParallelSubtasks() |
boolean |
isScheduleLocalOnly() |
void |
resetForNewExecution() |
boolean |
scheduleForExecution(SlotProvider slotProvider,
boolean queued) |
void |
setScheduleLocalOnly(boolean scheduleLocalOnly) |
void |
stop() |
String |
toString() |
public ExecutionVertex(ExecutionJobVertex jobVertex, int subTaskIndex, IntermediateResult[] producedDataSets, Time timeout)
public ExecutionVertex(ExecutionJobVertex jobVertex, int subTaskIndex, IntermediateResult[] producedDataSets, Time timeout, int maxPriorExecutionHistoryLength)
public ExecutionVertex(ExecutionJobVertex jobVertex, int subTaskIndex, IntermediateResult[] producedDataSets, Time timeout, long createTimestamp, int maxPriorExecutionHistoryLength)
public JobID getJobId()
public ExecutionJobVertex getJobVertex()
public JobVertexID getJobvertexId()
public String getTaskName()
public String getTaskNameWithSubtaskIndex()
AccessExecutionVertex
getTaskNameWithSubtaskIndex
in interface AccessExecutionVertex
public int getTotalNumberOfParallelSubtasks()
public int getMaxParallelism()
public int getParallelSubtaskIndex()
AccessExecutionVertex
getParallelSubtaskIndex
in interface AccessExecutionVertex
public int getNumberOfInputs()
public ExecutionEdge[] getInputEdges(int input)
public CoLocationConstraint getLocationConstraint()
public Execution getCurrentExecutionAttempt()
AccessExecutionVertex
getCurrentExecutionAttempt
in interface AccessExecutionVertex
public ExecutionState getExecutionState()
AccessExecutionVertex
ExecutionState
for this execution vertex.getExecutionState
in interface AccessExecutionVertex
public long getStateTimestamp(ExecutionState state)
AccessExecutionVertex
ExecutionState
.getStateTimestamp
in interface AccessExecutionVertex
state
- state for which the timestamp should be returnedpublic String getFailureCauseAsString()
AccessExecutionVertex
getFailureCauseAsString
in interface AccessExecutionVertex
"(null)"
public Throwable getFailureCause()
public SimpleSlot getCurrentAssignedResource()
public TaskManagerLocation getCurrentAssignedResourceLocation()
AccessExecutionVertex
TaskManagerLocation
for this execution vertex.getCurrentAssignedResourceLocation
in interface AccessExecutionVertex
public Execution getPriorExecutionAttempt(int attemptNumber)
AccessExecutionVertex
getPriorExecutionAttempt
in interface AccessExecutionVertex
attemptNumber
- attempt number of execution to be returnedpublic ExecutionGraph getExecutionGraph()
public Map<IntermediateResultPartitionID,IntermediateResultPartition> getProducedPartitions()
public void connectSource(int inputNumber, IntermediateResult source, JobEdge edge, int consumerNumber)
public void setScheduleLocalOnly(boolean scheduleLocalOnly)
public boolean isScheduleLocalOnly()
public Iterable<TaskManagerLocation> getPreferredLocations()
null
to indicate no location preference.public void resetForNewExecution()
public boolean scheduleForExecution(SlotProvider slotProvider, boolean queued) throws NoResourceAvailableException
NoResourceAvailableException
public void deployToSlot(SimpleSlot slot) throws JobException
JobException
public void cancel()
public void stop()
public void fail(Throwable t)
public void cachePartitionInfo(PartialInputChannelDeploymentDescriptor partitionInfo)
public String getSimpleName()
getTaskName()
, 'x' is the parallel
subtask index as returned by getParallelSubtaskIndex()
+ 1
, and 'y' is the total
number of tasks, as returned by getTotalNumberOfParallelSubtasks()
.public ArchivedExecutionVertex archive()
archive
in interface Archiveable<ArchivedExecutionVertex>
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.