Interface StreamOperatorStateContext
-
public interface StreamOperatorStateContextThis interface represents a context from which a stream operator can initialize everything connected to state such as e.g. backends, raw state, and timer service manager.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description AsyncKeyedStateBackendasyncKeyedStateBackend()Returns the async keyed state backend for the stream operator.OptionalLonggetRestoredCheckpointId()Returns non-empty if the states provided by this context are restored from a checkpoint/savepoint.InternalTimeServiceManager<?>internalTimerServiceManager()Returns the internal timer service manager for the stream operator.default booleanisRestored()Returns true if the states provided by this context are restored from a checkpoint/savepoint.CheckpointableKeyedStateBackend<?>keyedStateBackend()Returns the keyed state backend for the stream operator.OperatorStateBackendoperatorStateBackend()Returns the operator state backend for the stream operator.org.apache.flink.util.CloseableIterable<KeyGroupStatePartitionStreamProvider>rawKeyedStateInputs()Returns an iterable to obtain input streams for previously stored keyed state partitions that are assigned to this operator.org.apache.flink.util.CloseableIterable<StatePartitionStreamProvider>rawOperatorStateInputs()Returns an iterable to obtain input streams for previously stored operator state partitions that are assigned to this stream operator.
-
-
-
Method Detail
-
isRestored
default boolean isRestored()
Returns true if the states provided by this context are restored from a checkpoint/savepoint.
-
getRestoredCheckpointId
OptionalLong getRestoredCheckpointId()
Returns non-empty if the states provided by this context are restored from a checkpoint/savepoint.
-
operatorStateBackend
OperatorStateBackend operatorStateBackend()
Returns the operator state backend for the stream operator.
-
keyedStateBackend
CheckpointableKeyedStateBackend<?> keyedStateBackend()
Returns the keyed state backend for the stream operator. This method returns null for non-keyed operators.
-
asyncKeyedStateBackend
AsyncKeyedStateBackend asyncKeyedStateBackend()
Returns the async keyed state backend for the stream operator. This method returns null for operators which don't support async keyed state backend.
-
internalTimerServiceManager
InternalTimeServiceManager<?> internalTimerServiceManager()
Returns the internal timer service manager for the stream operator. This method returns null for non-keyed operators.
-
rawOperatorStateInputs
org.apache.flink.util.CloseableIterable<StatePartitionStreamProvider> rawOperatorStateInputs()
Returns an iterable to obtain input streams for previously stored operator state partitions that are assigned to this stream operator.
-
rawKeyedStateInputs
org.apache.flink.util.CloseableIterable<KeyGroupStatePartitionStreamProvider> rawKeyedStateInputs()
Returns an iterable to obtain input streams for previously stored keyed state partitions that are assigned to this operator. This method returns null for non-keyed operators.
-
-