@PublicEvolving public interface JobClient
Modifier and Type | Method and Description |
---|---|
CompletableFuture<Void> |
cancel()
Cancels the associated job.
|
CompletableFuture<Map<String,Object>> |
getAccumulators()
Requests the accumulators of the associated job.
|
CompletableFuture<JobExecutionResult> |
getJobExecutionResult()
Returns the
result of the job execution of the submitted job. |
JobID |
getJobID()
Returns the
JobID that uniquely identifies the job this client is scoped to. |
CompletableFuture<JobStatus> |
getJobStatus()
Requests the
JobStatus of the associated job. |
default void |
reportHeartbeat(long expiredTimestamp)
The client reports the heartbeat to the dispatcher for aliveness.
|
default CompletableFuture<String> |
stopWithSavepoint(boolean advanceToEndOfEventTime,
String savepointDirectory)
Deprecated.
pass the format explicitly
|
CompletableFuture<String> |
stopWithSavepoint(boolean advanceToEndOfEventTime,
String savepointDirectory,
SavepointFormatType formatType)
Stops the associated job on Flink cluster.
|
default CompletableFuture<String> |
triggerSavepoint(String savepointDirectory)
Deprecated.
pass the format explicitly
|
CompletableFuture<String> |
triggerSavepoint(String savepointDirectory,
SavepointFormatType formatType)
Triggers a savepoint for the associated job.
|
JobID getJobID()
JobID
that uniquely identifies the job this client is scoped to.CompletableFuture<JobStatus> getJobStatus()
JobStatus
of the associated job.CompletableFuture<Void> cancel()
@Deprecated default CompletableFuture<String> stopWithSavepoint(boolean advanceToEndOfEventTime, @Nullable String savepointDirectory)
Stopping works only for streaming programs. Be aware, that the job might continue to run for a while after sending the stop command, because after sources stopped to emit data all operators need to finish processing.
advanceToEndOfEventTime
- flag indicating if the source should inject a MAX_WATERMARK
in the pipelinesavepointDirectory
- directory the savepoint should be written toCompletableFuture
containing the path where the savepoint is locatedCompletableFuture<String> stopWithSavepoint(boolean advanceToEndOfEventTime, @Nullable String savepointDirectory, SavepointFormatType formatType)
Stopping works only for streaming programs. Be aware, that the job might continue to run for a while after sending the stop command, because after sources stopped to emit data all operators need to finish processing.
advanceToEndOfEventTime
- flag indicating if the source should inject a MAX_WATERMARK
in the pipelinesavepointDirectory
- directory the savepoint should be written toformatType
- binary format of the savepointCompletableFuture
containing the path where the savepoint is located@Deprecated default CompletableFuture<String> triggerSavepoint(@Nullable String savepointDirectory)
CheckpointingOptions.SAVEPOINT_DIRECTORY
if it is null.savepointDirectory
- directory the savepoint should be written toCompletableFuture
containing the path where the savepoint is locatedCompletableFuture<String> triggerSavepoint(@Nullable String savepointDirectory, SavepointFormatType formatType)
CheckpointingOptions.SAVEPOINT_DIRECTORY
if it is null.savepointDirectory
- directory the savepoint should be written toformatType
- binary format of the savepointCompletableFuture
containing the path where the savepoint is locatedCompletableFuture<Map<String,Object>> getAccumulators()
CompletableFuture<JobExecutionResult> getJobExecutionResult()
result of the job execution
of the submitted job.default void reportHeartbeat(long expiredTimestamp)
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.