[ https://issues.apache.org/jira/browse/BEAM-4681?focusedWorklogId=167333&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-167333 ]
ASF GitHub Bot logged work on BEAM-4681: ---------------------------------------- Author: ASF GitHub Bot Created on: 19/Nov/18 10:08 Start Date: 19/Nov/18 10:08 Worklog Time Spent: 10m Work Description: mxm commented on a change in pull request #7008: [BEAM-4681] Add support for portable timers in Flink batch mode URL: https://github.com/apache/beam/pull/7008#discussion_r234558497 ########## File path: runners/flink/src/main/java/org/apache/beam/runners/flink/translation/wrappers/streaming/DoFnOperator.java ########## @@ -927,22 +941,53 @@ public void setTimer( /** @deprecated use {@link #setTimer(StateNamespace, String, Instant, TimeDomain)}. */ @Deprecated @Override - public void setTimer(TimerData timerKey) { - long time = timerKey.getTimestamp().getMillis(); - switch (timerKey.getDomain()) { + public void setTimer(TimerData timer) { + try { + getKeyedStateBackend().setCurrentKey(getCurrentKey()); + String uniqueTimerId = getUniqueTimerId(timer); Review comment: It's because a new timer with timerId X resets the currently pending timer X in the same context. So we have to look up and remove the current timer and then set the new timer which involves adding it back to the "pending timers" map. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org Issue Time Tracking ------------------- Worklog Id: (was: 167333) Time Spent: 23h (was: 22h 50m) > Integrate support for timers using the portability APIs into Flink > ------------------------------------------------------------------ > > Key: BEAM-4681 > URL: https://issues.apache.org/jira/browse/BEAM-4681 > Project: Beam > Issue Type: Sub-task > Components: runner-flink > Reporter: Luke Cwik > Assignee: Maximilian Michels > Priority: Major > Labels: portability, portability-flink > Fix For: 2.9.0 > > Time Spent: 23h > Remaining Estimate: 0h > > Consider using the code produced in BEAM-4658 to support timers. -- This message was sent by Atlassian JIRA (v7.6.3#76005)