Github user srdo commented on a diff in the pull request:

    https://github.com/apache/storm/pull/2090#discussion_r117826059
  
    --- Diff: 
storm-client/src/jvm/org/apache/storm/windowing/TimeTriggerPolicy.java ---
    @@ -62,7 +62,9 @@ public void reset() {
     
         @Override
         public void start() {
    -        executorFuture = executor.scheduleAtFixedRate(newTriggerTask(), 
duration, duration, TimeUnit.MILLISECONDS);
    +        // initial delay is slightly less than the duration so that the 
initial tuples wont't expire due to time drift
    +        long initialDelay = duration - Math.min((long) (duration * .1), 
10);
    +        executorFuture = executor.scheduleAtFixedRate(newTriggerTask(), 
initialDelay, duration, TimeUnit.MILLISECONDS);
    --- End diff --
    
    Also since this is likely going to rely on in-bolt state to avoid expiring 
tuples before the user sees them, I think we should add to the documentation 
that this set of policies don't guarantee at-least-once processing.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to