public class TaskExecutor extends RpcEndpoint<TaskExecutorGateway>
Task
.Modifier and Type | Field and Description |
---|---|
static int |
MAX_BLOB_PORT
Max blob port which is accepted
|
static String |
TASK_MANAGER_NAME |
log
Constructor and Description |
---|
TaskExecutor(RpcService rpcService,
TaskManagerConfiguration taskManagerConfiguration,
TaskManagerLocation taskManagerLocation,
MemoryManager memoryManager,
IOManager ioManager,
NetworkEnvironment networkEnvironment,
HighAvailabilityServices haServices,
HeartbeatServices heartbeatServices,
MetricRegistry metricRegistry,
TaskManagerMetricGroup taskManagerMetricGroup,
BroadcastVariableManager broadcastVariableManager,
FileCache fileCache,
TaskSlotTable taskSlotTable,
JobManagerTable jobManagerTable,
JobLeaderService jobLeaderService,
FatalErrorHandler fatalErrorHandler) |
Modifier and Type | Method and Description |
---|---|
Acknowledge |
cancelTask(ExecutionAttemptID executionAttemptID) |
Acknowledge |
confirmCheckpoint(ExecutionAttemptID executionAttemptID,
long checkpointId,
long checkpointTimestamp) |
void |
disconnectJobManager(JobID jobId,
Exception cause) |
void |
disconnectResourceManager(Exception cause) |
void |
failPartition(ExecutionAttemptID executionAttemptID) |
ResourceID |
getResourceID() |
void |
heartbeatFromJobManager(ResourceID resourceID) |
void |
heartbeatFromResourceManager(ResourceID resourceID) |
Acknowledge |
requestSlot(SlotID slotId,
JobID jobId,
AllocationID allocationId,
String targetAddress,
UUID rmLeaderId)
Requests a slot from the TaskManager
|
void |
shutDown()
Called to shut down the TaskManager.
|
void |
start()
Starts the rpc endpoint.
|
Acknowledge |
stopTask(ExecutionAttemptID executionAttemptID) |
Acknowledge |
submitTask(TaskDeploymentDescriptor tdd,
UUID jobManagerLeaderId) |
Acknowledge |
triggerCheckpoint(ExecutionAttemptID executionAttemptID,
long checkpointId,
long checkpointTimestamp,
CheckpointOptions checkpointOptions) |
Acknowledge |
updatePartitions(ExecutionAttemptID executionAttemptID,
Iterable<PartitionInfo> partitionInfos) |
callAsync, getAddress, getEndpointId, getMainThreadExecutor, getRpcService, getSelf, getSelfGatewayType, getTerminationFuture, runAsync, scheduleRunAsync, scheduleRunAsync, validateRunsInMainThread
public static final String TASK_MANAGER_NAME
public static final int MAX_BLOB_PORT
public TaskExecutor(RpcService rpcService, TaskManagerConfiguration taskManagerConfiguration, TaskManagerLocation taskManagerLocation, MemoryManager memoryManager, IOManager ioManager, NetworkEnvironment networkEnvironment, HighAvailabilityServices haServices, HeartbeatServices heartbeatServices, MetricRegistry metricRegistry, TaskManagerMetricGroup taskManagerMetricGroup, BroadcastVariableManager broadcastVariableManager, FileCache fileCache, TaskSlotTable taskSlotTable, JobManagerTable jobManagerTable, JobLeaderService jobLeaderService, FatalErrorHandler fatalErrorHandler)
public void start() throws Exception
RpcEndpoint
start
in class RpcEndpoint<TaskExecutorGateway>
Exception
- indicating that something went wrong while starting the RPC endpointpublic void shutDown() throws Exception
shutDown
in class RpcEndpoint<TaskExecutorGateway>
Exception
- indicating that the something went wrong while shutting the RPC endpoint downpublic Acknowledge submitTask(TaskDeploymentDescriptor tdd, UUID jobManagerLeaderId) throws TaskSubmissionException
TaskSubmissionException
public Acknowledge cancelTask(ExecutionAttemptID executionAttemptID) throws TaskException
TaskException
public Acknowledge stopTask(ExecutionAttemptID executionAttemptID) throws TaskException
TaskException
public Acknowledge updatePartitions(ExecutionAttemptID executionAttemptID, Iterable<PartitionInfo> partitionInfos) throws PartitionException
PartitionException
public void failPartition(ExecutionAttemptID executionAttemptID)
public void heartbeatFromJobManager(ResourceID resourceID)
public void heartbeatFromResourceManager(ResourceID resourceID)
public Acknowledge triggerCheckpoint(ExecutionAttemptID executionAttemptID, long checkpointId, long checkpointTimestamp, CheckpointOptions checkpointOptions) throws CheckpointException
CheckpointException
public Acknowledge confirmCheckpoint(ExecutionAttemptID executionAttemptID, long checkpointId, long checkpointTimestamp) throws CheckpointException
CheckpointException
public Acknowledge requestSlot(SlotID slotId, JobID jobId, AllocationID allocationId, String targetAddress, UUID rmLeaderId) throws SlotAllocationException
slotId
- identifying the requested slotjobId
- identifying the job for which the request is issuedallocationId
- id for the requesttargetAddress
- of the job manager requesting the slotrmLeaderId
- current leader id of the ResourceManagerSlotAllocationException
- if the slot allocation failspublic void disconnectResourceManager(Exception cause)
public ResourceID getResourceID()
Copyright © 2014–2018 The Apache Software Foundation. All rights reserved.