Class TaskDeploymentDescriptor
java.lang.Object
org.apache.flink.runtime.deployment.TaskDeploymentDescriptor
- All Implemented Interfaces:
Serializable
A task deployment descriptor contains all the information necessary to deploy a task on a task
manager.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classWrapper class for serialized values which may be offloaded to theBlobServeror not.static classA serialized value that is not offloaded to theBlobServer.static classReference to a serialized value that was offloaded to theBlobServer. -
Constructor Summary
ConstructorsConstructorDescriptionTaskDeploymentDescriptor(org.apache.flink.api.common.JobID jobId, TaskDeploymentDescriptor.MaybeOffloaded<JobInformation> serializedJobInformation, TaskDeploymentDescriptor.MaybeOffloaded<TaskInformation> serializedTaskInformation, ExecutionAttemptID executionAttemptId, AllocationID allocationId, JobManagerTaskRestore taskRestore, List<ResultPartitionDeploymentDescriptor> resultPartitionDeploymentDescriptors, List<InputGateDeploymentDescriptor> inputGateDeploymentDescriptors) -
Method Summary
Modifier and TypeMethodDescriptionintReturns the attempt number of the subtask.org.apache.flink.api.common.JobIDgetJobId()Returns the task's job ID.Return the sub task's job information.intReturns the task's index in the subtask group.Return the sub task's task information.voidloadBigData(PermanentBlobService blobService, GroupCache<org.apache.flink.api.common.JobID, PermanentBlobKey, JobInformation> jobInformationCache, GroupCache<org.apache.flink.api.common.JobID, PermanentBlobKey, TaskInformation> taskInformationCache, GroupCache<org.apache.flink.api.common.JobID, PermanentBlobKey, TaskDeploymentDescriptorFactory.ShuffleDescriptorGroup> shuffleDescriptorsCache) Loads externalized data from the BLOB store back to the object.toString()
-
Constructor Details
-
TaskDeploymentDescriptor
public TaskDeploymentDescriptor(org.apache.flink.api.common.JobID jobId, TaskDeploymentDescriptor.MaybeOffloaded<JobInformation> serializedJobInformation, TaskDeploymentDescriptor.MaybeOffloaded<TaskInformation> serializedTaskInformation, ExecutionAttemptID executionAttemptId, AllocationID allocationId, @Nullable JobManagerTaskRestore taskRestore, List<ResultPartitionDeploymentDescriptor> resultPartitionDeploymentDescriptors, List<InputGateDeploymentDescriptor> inputGateDeploymentDescriptors)
-
-
Method Details
-
getJobInformation
Return the sub task's job information.- Returns:
- job information (may throw
IllegalStateExceptionifloadBigData(org.apache.flink.runtime.blob.PermanentBlobService, org.apache.flink.runtime.util.GroupCache<org.apache.flink.api.common.JobID, org.apache.flink.runtime.blob.PermanentBlobKey, org.apache.flink.runtime.executiongraph.JobInformation>, org.apache.flink.runtime.util.GroupCache<org.apache.flink.api.common.JobID, org.apache.flink.runtime.blob.PermanentBlobKey, org.apache.flink.runtime.executiongraph.TaskInformation>, org.apache.flink.runtime.util.GroupCache<org.apache.flink.api.common.JobID, org.apache.flink.runtime.blob.PermanentBlobKey, org.apache.flink.runtime.deployment.TaskDeploymentDescriptorFactory.ShuffleDescriptorGroup>)is not called beforehand). - Throws:
IllegalStateException- If job information is offloaded to BLOB store.IOExceptionClassNotFoundException
-
getTaskInformation
Return the sub task's task information.- Returns:
- task information (may throw
IllegalStateExceptionifloadBigData(org.apache.flink.runtime.blob.PermanentBlobService, org.apache.flink.runtime.util.GroupCache<org.apache.flink.api.common.JobID, org.apache.flink.runtime.blob.PermanentBlobKey, org.apache.flink.runtime.executiongraph.JobInformation>, org.apache.flink.runtime.util.GroupCache<org.apache.flink.api.common.JobID, org.apache.flink.runtime.blob.PermanentBlobKey, org.apache.flink.runtime.executiongraph.TaskInformation>, org.apache.flink.runtime.util.GroupCache<org.apache.flink.api.common.JobID, org.apache.flink.runtime.blob.PermanentBlobKey, org.apache.flink.runtime.deployment.TaskDeploymentDescriptorFactory.ShuffleDescriptorGroup>)is not called beforehand)). - Throws:
IllegalStateException- If job information is offloaded to BLOB store.IOExceptionClassNotFoundException
-
getJobId
public org.apache.flink.api.common.JobID getJobId()Returns the task's job ID.- Returns:
- the job ID this task belongs to
-
getExecutionAttemptId
-
getSubtaskIndex
public int getSubtaskIndex()Returns the task's index in the subtask group.- Returns:
- the task's index in the subtask group
-
getAttemptNumber
public int getAttemptNumber()Returns the attempt number of the subtask. -
getProducedPartitions
-
getInputGates
-
getTaskRestore
-
getAllocationId
-
loadBigData
public void loadBigData(@Nullable PermanentBlobService blobService, GroupCache<org.apache.flink.api.common.JobID, PermanentBlobKey, throws IOException, ClassNotFoundExceptionJobInformation> jobInformationCache, GroupCache<org.apache.flink.api.common.JobID, PermanentBlobKey, TaskInformation> taskInformationCache, GroupCache<org.apache.flink.api.common.JobID, PermanentBlobKey, TaskDeploymentDescriptorFactory.ShuffleDescriptorGroup> shuffleDescriptorsCache) Loads externalized data from the BLOB store back to the object.- Parameters:
blobService- the blob store to use (may be null ifserializedJobInformationandserializedTaskInformationare non-null)shuffleDescriptorsCache- cache of shuffle descriptors to reduce the cost of deserialization- Throws:
IOException- during errors retrieving or reading the BLOBsClassNotFoundException- Class of a serialized object cannot be found.
-
toString
-