Class DummySpeculativeExecutionHandler
java.lang.Object
org.apache.flink.runtime.scheduler.adaptivebatch.DummySpeculativeExecutionHandler
- All Implemented Interfaces:
SpeculativeExecutionHandler
The dummy implementation of
SpeculativeExecutionHandler.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanhandleTaskFailure(Execution failedExecution, Throwable error, BiConsumer<Execution, Throwable> handleLocalExecutionAttemptFailure) Handles a task failure.voidinit(ExecutionGraph executionGraph, org.apache.flink.runtime.concurrent.ComponentMainThreadExecutor mainThreadExecutor, org.apache.flink.metrics.MetricGroup metricGroup) Initial speculative execution handler.voidnotifyTaskFailed(Execution execution) Notifies that a task has failed its execution.voidnotifyTaskFinished(Execution execution, Function<ExecutionVertexID, CompletableFuture<?>> cancelPendingExecutionsFunction) Notifies that a task has finished its execution.voidresetForNewExecution(ExecutionVertexID executionVertexId) Resets the state of the component for a new execution of a specific execution vertex.voidStops the slow task detector.
-
Constructor Details
-
DummySpeculativeExecutionHandler
public DummySpeculativeExecutionHandler()
-
-
Method Details
-
init
public void init(ExecutionGraph executionGraph, org.apache.flink.runtime.concurrent.ComponentMainThreadExecutor mainThreadExecutor, org.apache.flink.metrics.MetricGroup metricGroup) Description copied from interface:SpeculativeExecutionHandlerInitial speculative execution handler.- Specified by:
initin interfaceSpeculativeExecutionHandler
-
stopSlowTaskDetector
public void stopSlowTaskDetector()Description copied from interface:SpeculativeExecutionHandlerStops the slow task detector.- Specified by:
stopSlowTaskDetectorin interfaceSpeculativeExecutionHandler
-
notifyTaskFinished
public void notifyTaskFinished(Execution execution, Function<ExecutionVertexID, CompletableFuture<?>> cancelPendingExecutionsFunction) Description copied from interface:SpeculativeExecutionHandlerNotifies that a task has finished its execution.- Specified by:
notifyTaskFinishedin interfaceSpeculativeExecutionHandler- Parameters:
execution- the execution that has finishedcancelPendingExecutionsFunction- the function to cancel pending executions
-
notifyTaskFailed
Description copied from interface:SpeculativeExecutionHandlerNotifies that a task has failed its execution.- Specified by:
notifyTaskFailedin interfaceSpeculativeExecutionHandler- Parameters:
execution- the execution that has failed
-
handleTaskFailure
public boolean handleTaskFailure(Execution failedExecution, @Nullable Throwable error, BiConsumer<Execution, Throwable> handleLocalExecutionAttemptFailure) Description copied from interface:SpeculativeExecutionHandlerHandles a task failure.- Specified by:
handleTaskFailurein interfaceSpeculativeExecutionHandler- Parameters:
failedExecution- the execution that failederror- the error that caused the failure, if availablehandleLocalExecutionAttemptFailure- a consumer that handles local execution attempt failure- Returns:
- true if the failure was handled as a local failure, false otherwise
-
resetForNewExecution
Description copied from interface:SpeculativeExecutionHandlerResets the state of the component for a new execution of a specific execution vertex.- Specified by:
resetForNewExecutionin interfaceSpeculativeExecutionHandler- Parameters:
executionVertexId- the ID of the execution vertex to reset
-