Interface KeyedStateFactory

All Known Subinterfaces:
CheckpointableKeyedStateBackend<K>, KeyedStateBackend<K>, TestableKeyedStateBackend<K>
All Known Implementing Classes:
AbstractKeyedStateBackend, BatchExecutionKeyedStateBackend, HeapKeyedStateBackend

public interface KeyedStateFactory
This factory produces concrete internal state objects.
  • Method Summary

    Modifier and Type
    Method
    Description
    default <N, SV, S extends org.apache.flink.api.common.state.State, IS extends S>
    IS
    createOrUpdateInternalState(org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer, org.apache.flink.api.common.state.StateDescriptor<S,SV> stateDesc)
    Creates or updates internal state and returns a new InternalKvState.
    <N, SV, SEV, S extends org.apache.flink.api.common.state.State, IS extends S>
    IS
    createOrUpdateInternalState(org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer, org.apache.flink.api.common.state.StateDescriptor<S,SV> stateDesc, StateSnapshotTransformer.StateSnapshotTransformFactory<SEV> snapshotTransformFactory)
    Creates or updates internal state and returns a new InternalKvState.
    default <N, SV, SEV, S extends org.apache.flink.api.common.state.State, IS extends S>
    IS
    createOrUpdateInternalState(org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer, org.apache.flink.api.common.state.StateDescriptor<S,SV> stateDesc, StateSnapshotTransformer.StateSnapshotTransformFactory<SEV> snapshotTransformFactory, boolean allowFutureMetadataUpdates)
    Creates or updates internal state and returns a new InternalKvState.
  • Method Details

    • createOrUpdateInternalState

      @Nonnull default <N, SV, S extends org.apache.flink.api.common.state.State, IS extends S> IS createOrUpdateInternalState(@Nonnull org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer, @Nonnull org.apache.flink.api.common.state.StateDescriptor<S,SV> stateDesc) throws Exception
      Creates or updates internal state and returns a new InternalKvState.
      Type Parameters:
      N - The type of the namespace.
      SV - The type of the stored state value.
      S - The type of the public API state.
      IS - The type of internal state.
      Parameters:
      namespaceSerializer - TypeSerializer for the state namespace.
      stateDesc - The StateDescriptor that contains the name of the state.
      Throws:
      Exception
    • createOrUpdateInternalState

      @Nonnull <N, SV, SEV, S extends org.apache.flink.api.common.state.State, IS extends S> IS createOrUpdateInternalState(@Nonnull org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer, @Nonnull org.apache.flink.api.common.state.StateDescriptor<S,SV> stateDesc, @Nonnull StateSnapshotTransformer.StateSnapshotTransformFactory<SEV> snapshotTransformFactory) throws Exception
      Creates or updates internal state and returns a new InternalKvState.
      Type Parameters:
      N - The type of the namespace.
      SV - The type of the stored state value.
      SEV - The type of the stored state value or entry for collection types (list or map).
      S - The type of the public API state.
      IS - The type of internal state.
      Parameters:
      namespaceSerializer - TypeSerializer for the state namespace.
      stateDesc - The StateDescriptor that contains the name of the state.
      snapshotTransformFactory - factory of state snapshot transformer.
      Throws:
      Exception
    • createOrUpdateInternalState

      @Nonnull default <N, SV, SEV, S extends org.apache.flink.api.common.state.State, IS extends S> IS createOrUpdateInternalState(@Nonnull org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer, @Nonnull org.apache.flink.api.common.state.StateDescriptor<S,SV> stateDesc, @Nonnull StateSnapshotTransformer.StateSnapshotTransformFactory<SEV> snapshotTransformFactory, boolean allowFutureMetadataUpdates) throws Exception
      Creates or updates internal state and returns a new InternalKvState.
      Type Parameters:
      N - The type of the namespace.
      SV - The type of the stored state value.
      SEV - The type of the stored state value or entry for collection types (list or map).
      S - The type of the public API state.
      IS - The type of internal state.
      Parameters:
      namespaceSerializer - TypeSerializer for the state namespace.
      stateDesc - The StateDescriptor that contains the name of the state.
      snapshotTransformFactory - factory of state snapshot transformer.
      allowFutureMetadataUpdates - whether allow metadata to update in the future or not.
      Throws:
      Exception