Skip to content

Commit

Permalink
DefaultTrigger#onMerge shouldn't clean up timers for merged windows.
Browse files Browse the repository at this point in the history
The TriggerExecutor automatically cleans the trigger in all windows
that no longer exist.

----Release Notes----

[]
-------------
Created by MOE: http://code.google.com/p/moe-java
MOE_MIGRATED_REVID=90673162
  • Loading branch information
bchambers authored and davorbonaci committed Apr 9, 2015
1 parent f75542e commit a447453
Showing 1 changed file with 0 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,6 @@ public TriggerResult onElement(TriggerContext<W> c, OnElementEvent<W> e) throws

@Override
public TriggerResult onMerge(TriggerContext<W> c, OnMergeEvent<W> e) throws Exception {
for (W oldWindow : e.oldWindows()) {
c.deleteTimer(oldWindow, TimeDomain.EVENT_TIME);
}

c.setTimer(e.newWindow(), e.newWindow().maxTimestamp(), TimeDomain.EVENT_TIME);
return TriggerResult.CONTINUE;
}
Expand Down

0 comments on commit a447453

Please sign in to comment.