Interface DispatcherGateway

All Superinterfaces:
org.apache.flink.runtime.rpc.FencedRpcGateway<DispatcherId>, RestfulGateway, org.apache.flink.runtime.rpc.RpcGateway
All Known Implementing Classes:
Dispatcher, StandaloneDispatcher

public interface DispatcherGateway extends org.apache.flink.runtime.rpc.FencedRpcGateway<DispatcherId>, RestfulGateway
Gateway for the Dispatcher component.
  • Method Details

    • submitJob

      CompletableFuture<Acknowledge> submitJob(ExecutionPlan executionPlan, Duration timeout)
      Submit a job to the dispatcher.
      Parameters:
      executionPlan - ExecutionPlan to submit
      timeout - RPC timeout
      Returns:
      A future acknowledge if the submission succeeded
    • submitFailedJob

      CompletableFuture<Acknowledge> submitFailedJob(org.apache.flink.api.common.JobID jobId, String jobName, Throwable exception)
    • listJobs

      CompletableFuture<Collection<org.apache.flink.api.common.JobID>> listJobs(Duration timeout)
      List the current set of submitted jobs.
      Parameters:
      timeout - RPC timeout
      Returns:
      A future collection of currently submitted jobs
    • getBlobServerPort

      CompletableFuture<Integer> getBlobServerPort(Duration timeout)
      Returns the port of the blob server.
      Parameters:
      timeout - of the operation
      Returns:
      A future integer of the blob server port
    • shutDownCluster

      default CompletableFuture<Acknowledge> shutDownCluster(ApplicationStatus applicationStatus)
    • triggerCheckpoint

      default CompletableFuture<String> triggerCheckpoint(org.apache.flink.api.common.JobID jobID, Duration timeout)
    • triggerSavepointAndGetLocation

      default CompletableFuture<String> triggerSavepointAndGetLocation(org.apache.flink.api.common.JobID jobId, String targetDirectory, org.apache.flink.core.execution.SavepointFormatType formatType, TriggerSavepointMode savepointMode, Duration timeout)
      Triggers a savepoint with the given savepoint directory as a target, returning a future that completes with the savepoint location when it is complete.
      Parameters:
      jobId - the job id
      targetDirectory - Target directory for the savepoint.
      formatType - Binary format of the savepoint.
      savepointMode - context of the savepoint operation
      timeout - Timeout for the asynchronous operation
      Returns:
      Future which is completed once the operation is triggered successfully
    • stopWithSavepointAndGetLocation

      default CompletableFuture<String> stopWithSavepointAndGetLocation(org.apache.flink.api.common.JobID jobId, String targetDirectory, org.apache.flink.core.execution.SavepointFormatType formatType, TriggerSavepointMode savepointMode, Duration timeout)
      Stops the job with a savepoint, returning a future that completes with the savepoint location when the savepoint is completed.
      Parameters:
      jobId - the job id
      targetDirectory - Target directory for the savepoint.
      savepointMode - context of the savepoint operation
      timeout - for the rpc call
      Returns:
      Future which is completed with the savepoint location once it is completed
    • triggerCheckpointAndGetCheckpointID

      default CompletableFuture<Long> triggerCheckpointAndGetCheckpointID(org.apache.flink.api.common.JobID jobId, org.apache.flink.core.execution.CheckpointType checkpointType, Duration timeout)
      Triggers a checkpoint, returning a future that completes with the checkpoint id when it is complete.
      Parameters:
      jobId - the job id
      checkpointType - checkpoint type of this checkpoint (configured / full / incremental)
      timeout - Timeout for the asynchronous operation
      Returns:
      Future which is completed once the operation is triggered successfully