public class ExecutionVertex extends Object implements AccessExecutionVertex, Archiveable<ArchivedExecutionVertex>
Execution
.Modifier and Type | Field and Description |
---|---|
static long |
NUM_BYTES_UNKNOWN |
Constructor and Description |
---|
ExecutionVertex(ExecutionJobVertex jobVertex,
int subTaskIndex,
IntermediateResult[] producedDataSets,
Time timeout,
long createTimestamp,
int executionHistorySizeLimit,
int initialAttemptCount)
Creates an ExecutionVertex.
|
public static final long NUM_BYTES_UNKNOWN
@VisibleForTesting public ExecutionVertex(ExecutionJobVertex jobVertex, int subTaskIndex, IntermediateResult[] producedDataSets, Time timeout, long createTimestamp, int executionHistorySizeLimit, int initialAttemptCount)
timeout
- The RPC timeout to use for deploy / cancel callscreateTimestamp
- The timestamp for the vertex creation, used to initialize the first
Execution with.executionHistorySizeLimit
- The maximum number of historical Executions (= execution
attempts) to keep.initialAttemptCount
- The attempt number of the first execution of this vertex.public ExecutionVertexInputInfo getExecutionVertexInputInfo(IntermediateDataSetID resultId)
public void setInputBytes(long inputBytes)
public long getInputBytes()
public Execution getPartitionProducer()
public JobID getJobId()
public ExecutionJobVertex getJobVertex()
public JobVertexID getJobvertexId()
public String getTaskName()
public String getTaskNameWithSubtaskIndex()
getTaskName()
, 'x' is the parallel subtask index as returned by
getParallelSubtaskIndex()
+ 1
, and 'y' is the total number of tasks, as
returned by getTotalNumberOfParallelSubtasks()
.getTaskNameWithSubtaskIndex
in interface AccessExecutionVertex
public int getTotalNumberOfParallelSubtasks()
public int getMaxParallelism()
public ResourceProfile getResourceProfile()
public int getParallelSubtaskIndex()
AccessExecutionVertex
getParallelSubtaskIndex
in interface AccessExecutionVertex
public ExecutionVertexID getID()
public int getNumberOfInputs()
public List<ConsumedPartitionGroup> getAllConsumedPartitionGroups()
public ConsumedPartitionGroup getConsumedPartitionGroup(int input)
public Optional<InputSplit> getNextInputSplit(String host, int attemptNumber)
public Execution getCurrentExecutionAttempt()
AccessExecutionVertex
getCurrentExecutionAttempt
in interface AccessExecutionVertex
public Collection<Execution> getCurrentExecutions()
AccessExecutionVertex
getCurrentExecutions
in interface AccessExecutionVertex
public Execution getCurrentExecution(int attemptNumber)
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 Optional<ErrorInfo> getFailureInfo()
AccessExecutionVertex
getFailureInfo
in interface AccessExecutionVertex
Optional
of ErrorInfo
, or an empty
Optional
if no exception was caught.public CompletableFuture<TaskManagerLocation> getCurrentTaskManagerLocationFuture()
public LogicalSlot getCurrentAssignedResource()
public TaskManagerLocation getCurrentAssignedResourceLocation()
AccessExecutionVertex
TaskManagerLocation
for this execution vertex.getCurrentAssignedResourceLocation
in interface AccessExecutionVertex
public ExecutionHistory getExecutionHistory()
AccessExecutionVertex
getExecutionHistory
in interface AccessExecutionVertex
public Optional<TaskManagerLocation> findLastLocation()
public Optional<AllocationID> findLastAllocation()
public final InternalExecutionGraphAccessor getExecutionGraphAccessor()
public Map<IntermediateResultPartitionID,IntermediateResultPartition> getProducedPartitions()
public void addConsumedPartitionGroup(ConsumedPartitionGroup consumedPartitions)
public Optional<TaskManagerLocation> getPreferredLocationBasedOnState()
public void resetForNewExecution()
public void tryAssignResource(LogicalSlot slot)
public void deploy() throws JobException
JobException
@VisibleForTesting public void deployToSlot(LogicalSlot slot) throws JobException
JobException
public CompletableFuture<?> cancel()
public CompletableFuture<?> suspend()
public void fail(Throwable t)
public void markFailed(Throwable t)
t
- The exception that caused the task to fail.@VisibleForTesting public List<IntermediateResultPartition> finishPartitionsIfNeeded()
public ArchivedExecutionVertex archive()
archive
in interface Archiveable<ArchivedExecutionVertex>
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.