public class MiniDispatcher extends Dispatcher
JobClusterEntrypoint.
The mini dispatcher is initialized with a single JobGraph which it runs.
Depending on the ClusterEntrypoint.ExecutionMode, the mini dispatcher will directly
terminate after job completion if its execution mode is ClusterEntrypoint.ExecutionMode#DETACHED.
Dispatcher.ExecutionTypeCLIENT_ALIVENESS_CHECK_DURATION, DISPATCHER_NAME, shutDownFuture| Constructor and Description |
|---|
MiniDispatcher(org.apache.flink.runtime.rpc.RpcService rpcService,
DispatcherId fencingToken,
DispatcherServices dispatcherServices,
JobGraph jobGraph,
JobResult recoveredDirtyJob,
DispatcherBootstrapFactory dispatcherBootstrapFactory,
ClusterEntrypoint.ExecutionMode executionMode) |
MiniDispatcher(org.apache.flink.runtime.rpc.RpcService rpcService,
DispatcherId fencingToken,
DispatcherServices dispatcherServices,
JobGraph jobGraph,
JobResult recoveredDirtyJob,
DispatcherBootstrapFactory dispatcherBootstrapFactory,
JobManagerRunnerRegistry jobManagerRunnerRegistry,
ResourceCleanerFactory resourceCleanerFactory,
ClusterEntrypoint.ExecutionMode executionMode) |
| Modifier and Type | Method and Description |
|---|---|
CompletableFuture<Acknowledge> |
cancelJob(org.apache.flink.api.common.JobID jobId,
org.apache.flink.api.common.time.Time timeout)
Cancel the given job.
|
CompletableFuture<JobResult> |
requestJobResult(org.apache.flink.api.common.JobID jobId,
org.apache.flink.api.common.time.Time timeout)
Requests the
JobResult of a job specified by the given jobId. |
protected void |
runPostJobGloballyTerminated(org.apache.flink.api.common.JobID jobId,
org.apache.flink.api.common.JobStatus jobStatus) |
CompletableFuture<Acknowledge> |
submitJob(JobGraph jobGraph,
org.apache.flink.api.common.time.Time timeout)
Submit a job to the dispatcher.
|
deliverCoordinationRequestToCoordinator, disposeSavepoint, getBlobServerPort, getShutDownFuture, getTriggeredCheckpointStatus, getTriggeredSavepointStatus, jobReachedTerminalState, listJobs, onFatalError, onRemovedJobGraph, onStart, onStop, reportJobClientHeartbeat, requestCheckpointStats, requestClusterOverview, requestExecutionGraphInfo, requestJobResourceRequirements, requestJobStatus, requestMetricQueryServiceAddresses, requestMultipleJobDetails, requestTaskManagerMetricQueryServiceAddresses, requestThreadDump, shutDownCluster, shutDownCluster, stopWithSavepoint, stopWithSavepointAndGetLocation, submitFailedJob, triggerCheckpoint, triggerCheckpoint, triggerCheckpointAndGetCheckpointID, triggerSavepoint, triggerSavepointAndGetLocation, updateJobResourceRequirementscallAsync, closeAsync, getAddress, getEndpointId, getHostname, getMainThreadExecutor, getRpcService, getSelfGateway, getTerminationFuture, internalCallOnStart, internalCallOnStop, isRunning, registerResource, runAsync, scheduleRunAsync, scheduleRunAsync, start, stop, unregisterResource, validateRunsInMainThreadclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitrequestJobpublic MiniDispatcher(org.apache.flink.runtime.rpc.RpcService rpcService,
DispatcherId fencingToken,
DispatcherServices dispatcherServices,
@Nullable
JobGraph jobGraph,
@Nullable
JobResult recoveredDirtyJob,
DispatcherBootstrapFactory dispatcherBootstrapFactory,
ClusterEntrypoint.ExecutionMode executionMode)
throws Exception
Exception@VisibleForTesting
public MiniDispatcher(org.apache.flink.runtime.rpc.RpcService rpcService,
DispatcherId fencingToken,
DispatcherServices dispatcherServices,
@Nullable
JobGraph jobGraph,
@Nullable
JobResult recoveredDirtyJob,
DispatcherBootstrapFactory dispatcherBootstrapFactory,
JobManagerRunnerRegistry jobManagerRunnerRegistry,
ResourceCleanerFactory resourceCleanerFactory,
ClusterEntrypoint.ExecutionMode executionMode)
throws Exception
Exceptionpublic CompletableFuture<Acknowledge> submitJob(JobGraph jobGraph, org.apache.flink.api.common.time.Time timeout)
DispatcherGatewaysubmitJob in interface DispatcherGatewaysubmitJob in class DispatcherjobGraph - JobGraph to submittimeout - RPC timeoutpublic CompletableFuture<JobResult> requestJobResult(org.apache.flink.api.common.JobID jobId, org.apache.flink.api.common.time.Time timeout)
RestfulGatewayJobResult of a job specified by the given jobId.requestJobResult in interface RestfulGatewayrequestJobResult in class DispatcherjobId - identifying the job for which to retrieve the JobResult.timeout - for the asynchronous operationJobResult once the job has finishedpublic CompletableFuture<Acknowledge> cancelJob(org.apache.flink.api.common.JobID jobId, org.apache.flink.api.common.time.Time timeout)
RestfulGatewaycancelJob in interface RestfulGatewaycancelJob in class DispatcherjobId - identifying the job to canceltimeout - of the operationprotected void runPostJobGloballyTerminated(org.apache.flink.api.common.JobID jobId,
org.apache.flink.api.common.JobStatus jobStatus)
runPostJobGloballyTerminated in class DispatcherCopyright © 2014–2024 The Apache Software Foundation. All rights reserved.