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

    https://github.com/apache/storm/pull/2218#discussion_r130226994
  
    --- Diff: 
storm-client/src/jvm/org/apache/storm/windowing/WindowManager.java ---
    @@ -53,28 +61,34 @@
         public static final int EXPIRE_EVENTS_THRESHOLD = 100;
     
         private final WindowLifecycleListener<T> windowLifecycleListener;
    -    private final ConcurrentLinkedQueue<Event<T>> queue;
    +    private final Collection<Event<T>> queue;
         private final List<T> expiredEvents;
         private final Set<Event<T>> prevWindowEvents;
         private final AtomicInteger eventsSinceLastExpiry;
         private final ReentrantLock lock;
    -    private EvictionPolicy<T> evictionPolicy;
    -    private TriggerPolicy<T> triggerPolicy;
    -
    +    private final boolean stateful;
    +    private EvictionPolicy<T, ?> evictionPolicy;
    +    private TriggerPolicy<T, ?> triggerPolicy;
         public WindowManager(WindowLifecycleListener<T> lifecycleListener) {
    +        this(lifecycleListener, new ConcurrentLinkedQueue<>(), false);
    +    }
    +
    +    public WindowManager(WindowLifecycleListener<T> lifecycleListener, 
Collection<Event<T>> queue, boolean stateful) {
    --- End diff --
    
    Could you add a note here and in the API in WindowedBoltExecutor that this 
Collection has to be thread safe?


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to