[ https://issues.apache.org/jira/browse/FLINK-12005?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17121272#comment-17121272 ]
Yu Li commented on FLINK-12005: ------------------------------- Hi [~lyee], sorry but I'm not actively working on this issue at the moment. We ever had a [discussion in ML|http://apache-flink-mailing-list-archive.1008284.n3.nabble.com/Discuss-Semantics-of-event-time-for-state-TTL-td28113.html] about the semantic of event time in state TTL but it seems to be no explicit conclusion. OTOH, I think it's better to look back at it after [FLIP-27|https://cwiki.apache.org/confluence/display/FLINK/FLIP-27%3A+Refactor+Source+Interface] is done. Will ping here once we revive the job, or please let me know if any suggestions. Thanks. > [State TTL] Event time support > ------------------------------ > > Key: FLINK-12005 > URL: https://issues.apache.org/jira/browse/FLINK-12005 > Project: Flink > Issue Type: New Feature > Components: API / DataStream, Runtime / State Backends > Reporter: Andrey Zagrebin > Assignee: Yu Li > Priority: Major > > The event time is opted for in StateTtlConfig by setting > TtlTimeCharacteristic.EventTime. > To enable event time support, the updated watermark needs to be passed to the > state backend, shared with TTL state wrappers and additional cleanup > strategies (snapshot transformers and compaction filter). > h3. Event time provider > Additional implementation of TtlTimeProvider, which holds current watermark, > needs to be passed to the state backend at the moment of its creation in > StreamTaskStateInitializerImpl. There several ways to update watermark in > this implementation of TtlTimeProvider: > * in InternalTimeServiceManager.advanceWatermark explicitly > * InternalTimeServiceManager/InternalTimerServiceImpl could be refactored to > use shared EventTimeService which holds current updatable watermark and > wrapped by TtlTimeProvider > The TTL state wrapping factory should create TTL state wrappers and snapshot > transformers with TtlTimeProvider selected by TtlTimeCharacteristic. > h3. RocksDB TTL compaction filter > The RocksDB TTL compaction filter factory needs to get selected > TtlTimeProvider when it gets configured. There are two ways: > * make it volatile and settable in > RocksDbTtlCompactFiltersManager.TimeProviderWrapper, track it in > RocksDbTtlCompactFiltersManager along with FlinkCompactionFilterFactory to > configure later before configuring FlinkCompactionFilterFactory. > * Move FlinkCompactionFilter.TimeProvider from FlinkCompactionFilterFactory > to ConfigHolder and set selected TtlTimeProvider with the Config. > The second option does not use volatile variable and should be more > performant but needs changing RocksDB java client and either releasing new > version FRocksDB or Flink RocksDB extensions. -- This message was sent by Atlassian Jira (v8.3.4#803005)