You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2017/06/19 15:05:00 UTC

[jira] [Commented] (FLINK-6418) Support for dynamic state changes in CEP patterns

    [ https://issues.apache.org/jira/browse/FLINK-6418?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16054160#comment-16054160 ] 

ASF GitHub Bot commented on FLINK-6418:
---------------------------------------

GitHub user dawidwys opened a pull request:

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

    [FLINK-6418][cep] Support for dynamic state changes in CEP patterns

    Thanks for contributing to Apache Flink. Before you open your pull request, please take the following check list into consideration.
    If your changes take all of the items into account, feel free to open your pull request. For more information and/or questions please refer to the [How To Contribute guide](http://flink.apache.org/how-to-contribute.html).
    In addition to going through the list, please provide a meaningful description of your changes.
    
    - [ ] General
      - The pull request references the related JIRA issue ("[FLINK-XXX] Jira title text")
      - The pull request addresses only one issue
      - Each commit in the PR has a meaningful commit message (including the JIRA id)
    
    - [ ] Documentation
      - Documentation has been added for new functionality
      - Old documentation affected by the pull request has been updated
      - JavaDoc for public methods has been added
    
    - [ ] Tests & Build
      - Functionality added by the pull request is covered by tests
      - `mvn clean verify` has been executed successfully locally or a Travis build has passed


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

    $ git pull https://github.com/dawidwys/flink cep-loop-until

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

    https://github.com/apache/flink/pull/4143.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 #4143
    
----
commit b1832af10410266cedc26654f7be1052ea244c47
Author: Dawid Wysakowicz <dw...@apache.org>
Date:   2017-06-19T14:40:02Z

    [FLINK-6418][cep] Support for dynamic state changes in CEP patterns

----


> Support for dynamic state changes in CEP patterns
> -------------------------------------------------
>
>                 Key: FLINK-6418
>                 URL: https://issues.apache.org/jira/browse/FLINK-6418
>             Project: Flink
>          Issue Type: Improvement
>          Components: CEP
>    Affects Versions: 1.3.0
>            Reporter: Elias Levy
>            Assignee: Dawid Wysakowicz
>
> Flink CEP library allows one to define event pattern to match where the match condition can be determined programmatically via the {{where}} method.  Flink 1.3 will introduce so-called iterative conditions, which allow the predicate to look up events already matched by the pattern and thus be conditional on them.
> 1.3 also introduces to the API quantifer methods which allow one to declaratively specific how many times a condition must be matched before there is a state change.
> Alas, there are use cases where the quantifier must be determined dynamically based on the events matched by the pattern so far.  Therefore, I propose the adding of a new {{Pattern}}: {{until}}.
> Like the new iterative variant of {{where}}, {{until}} would take a predicate function and a context that provides access to events already matched.  But whereas {{where}} determines if an event is accepted by the pattern, {{until}} determines whether is pattern should move on to the next state.
> In our particular use case, we have a pattern where an event is matched a number of times, but depending on the event type, the number (threshold) for the pattern to match is different.  We could decompose the pattern into multiple similar patterns, but that could be inefficient if we have many such patterns.  If the functionality of {{until}} were available, we could make do with a single pattern.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)