public interface TaskStateManager extends CheckpointListener
When a checkpoint or savepoint is triggered on a task, it will create snapshots for all stream operator instances it owns. All operator snapshots from the task are then reported via this interface. A typical implementation will dispatch and forward the reported state information to interested parties such as the checkpoint coordinator or a local state store.
This interface also offers the complementary method that provides access to previously saved state of operator instances in the task for restore purposes.
|Modifier and Type||Method and Description|
Returns the configuration for local recovery, i.e.
Returns means to restore previously reported state of an operator running in the owning task.
Report the state snapshots for the operator instances running in the owning task.
void reportTaskStateSnapshots(@Nonnull CheckpointMetaData checkpointMetaData, @Nonnull CheckpointMetrics checkpointMetrics, @Nullable TaskStateSnapshot acknowledgedState, @Nullable TaskStateSnapshot localState)
checkpointMetaData- meta data from the checkpoint request.
checkpointMetrics- task level metrics for the checkpoint.
acknowledgedState- the reported states to acknowledge to the job manager.
localState- the reported states for local recovery.
@Nonnull PrioritizedOperatorSubtaskState prioritizedOperatorState(OperatorID operatorID)
operatorID- the id of the operator for which we request state.
Copyright © 2014–2019 The Apache Software Foundation. All rights reserved.