Class TtlStateFactory<K,​N,​SV,​TTLSV,​S extends org.apache.flink.api.common.state.State,​IS extends S>


  • public class TtlStateFactory<K,​N,​SV,​TTLSV,​S extends org.apache.flink.api.common.state.State,​IS extends S>
    extends Object
    This state factory wraps state objects, produced by backends, with TTL logic.
    • Method Detail

      • createStateAndWrapWithTtlIfEnabled

        public static <K,​N,​SV,​TTLSV,​S extends org.apache.flink.api.common.state.State,​IS extends S> IS createStateAndWrapWithTtlIfEnabled​(org.apache.flink.api.common.typeutils.TypeSerializer<N> namespaceSerializer,
                                                                                                                                                                        org.apache.flink.api.common.state.StateDescriptor<S,​SV> stateDesc,
                                                                                                                                                                        KeyedStateBackend<K> stateBackend,
                                                                                                                                                                        TtlTimeProvider timeProvider)
                                                                                                                                                                 throws Exception
        Throws:
        Exception