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

    https://github.com/apache/flink/pull/2367#discussion_r75495021
  
    --- Diff: 
flink-libraries/flink-cep/src/main/java/org/apache/flink/cep/nfa/NFA.java ---
    @@ -300,17 +311,21 @@ public int hashCode() {
                                                                                
previousEvent,
                                                                                
previousTimestamp,
                                                                                
oldVersion);
    +                                                                   
validPreviousState = true;
                                                                }
     
    -                                                           // a new 
computation state is referring to the shared entry
    -                                                           
sharedBuffer.lock(newState, event, timestamp);
    +                                                           if 
(validPreviousState) {
    +                                                                   // a 
new computation state is referring to the shared entry
    +                                                                   
sharedBuffer.lock(newState, event, timestamp);
    +
    +                                                                   
resultingComputationStates.add(new ComputationState<T>(
    +                                                                           
newState,
    +                                                                           
event,
    +                                                                           
timestamp,
    +                                                                           
newComputationStateVersion,
    +                                                                           
startTimestamp));
    --- End diff --
    
    Ideally we would filtered out all computation states which referred to 
pruned computations. Then we would not have to make this case distinction here.


---
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