You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by yestinchen <gi...@git.apache.org> on 2017/09/14 16:08:12 UTC

[GitHub] flink pull request #4673: [hotfix] [cep] Fix afterMatchStrategy parameter mi...

GitHub user yestinchen opened a pull request:

    https://github.com/apache/flink/pull/4673

    [hotfix] [cep] Fix afterMatchStrategy parameter missing issue

    
    
    ## What is the purpose of the change
    Fix afterMatchSkipStrategy parameter missing when calling `nfa.process()` function. This issue may be introduced during merging conflicts.
    
    ## Brief change log
    
    
    ## Verifying this change
    
    This change added tests and can be verified as follows:
    append a aftermatch test case in `CEPITCase` to exam this kind of problems.
    
    ## Does this pull request potentially affect one of the following parts:
    
      - Dependencies (does it add or upgrade a dependency): (no)
      - The public API, i.e., is any changed class annotated with `@Public(Evolving)`: (no)
      - The serializers: (no)
      - The runtime per-record code paths (performance sensitive): (no)
      - Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Yarn/Mesos, ZooKeeper: (no)
    
    ## Documentation
    
      - Does this pull request introduce a new feature? (no)
      - If yes, how is the feature documented? (not applicable)
    


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/yestinchen/flink aftermatch-hotfix

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/4673.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #4673
    
----
commit 060dcde4bd9662c98ade061c1698fcff5bb702b3
Author: Yestin <87...@qq.com>
Date:   2017-09-14T16:01:53Z

    [hotfix] [cep] Fix afterMatchStrategy parameter missing issue
    
    This issue may be introduced during merging conflicts.

----


---

[GitHub] flink pull request #4673: [hotfix] [cep] Fix afterMatchStrategy parameter mi...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/flink/pull/4673


---

[GitHub] flink issue #4673: [hotfix] [cep] Fix afterMatchStrategy parameter missing i...

Posted by yestinchen <gi...@git.apache.org>.
Github user yestinchen commented on the issue:

    https://github.com/apache/flink/pull/4673
  
    Hi @dawidwys ,
    I just found this issue in after match feature, which causes AfterMatchSkipStrategy not work. This may be introduced while merging file conflicts. I addressed that in this PR and added a simple test to exam such problems. Please merge this to the repository. Thanks.


---

[GitHub] flink issue #4673: [hotfix] [cep] Fix afterMatchStrategy parameter missing i...

Posted by yestinchen <gi...@git.apache.org>.
Github user yestinchen commented on the issue:

    https://github.com/apache/flink/pull/4673
  
    Hi @dawidwys , Thanks for the tip, that's what I tried to add. Sorry for the missing times().


---

[GitHub] flink issue #4673: [hotfix] [cep] Fix afterMatchStrategy parameter missing i...

Posted by dawidwys <gi...@git.apache.org>.
Github user dawidwys commented on the issue:

    https://github.com/apache/flink/pull/4673
  
    Hi @yestinchen ,
    thanks for spotting the mistake. Good catch. However the test you provided does not prove the fix. It passes with and without the fix. Please correct it. You can e.g. extend the Pattern like this:
    
    	Pattern<Tuple2<Integer, String>, ?> pattern =
    		Pattern.<Tuple2<Integer, String>>begin("start", AfterMatchSkipStrategy.skipPastLastEvent())
    			.where(new SimpleCondition<Tuple2<Integer, String>>() {
    				@Override
    				public boolean filter(Tuple2<Integer, String> rec) throws Exception {
    					return rec.f1.equals("a");
    				}
    			}).times(2);
    
    Then the expected output would be:
    
    	expected = "(1,a)\n(3,a)";


---