flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FLINK-6198) Update the documentation of the CEP library to include all the new features.
Date Thu, 01 Jun 2017 13:07:04 GMT

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

ASF GitHub Bot commented on FLINK-6198:

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

    --- Diff: docs/dev/libs/cep.md ---
    @@ -98,48 +128,105 @@ val result: DataStream[Alert] = patternStream.select(createAlert(_))
    -Note that we use Java 8 lambdas in our Java code examples to make them more succinct.
     ## The Pattern API
    -The pattern API allows you to quickly define complex event patterns.
    -Each pattern consists of multiple stages or what we call states.
    -In order to go from one state to the next, the user can specify conditions.
    -These conditions can be the contiguity of events or a filter condition on an event.
    -Each pattern has to start with an initial state:
    +The pattern API allows you to quickly define complex pattern sequences that you want
to extract 
    +from your input stream.
    +Each such complex pattern sequence consists of multiple simple patterns, i.e. patterns
looking for 
    +individual events with the same properties. These simple patterns are called **states**.
A complex pattern 
    +can be seen as a graph of such states, where transition from one state to the next happens
based on user-specified
    +*conditions*, e.g. `event.getName().equals("start")`. A *match* is a sequence of input
events which visit all 
    +states of the complex pattern graph, through a sequence of valid state transitions.
    +<span class="label label-danger">Attention</span> Each state must have a
unique name to identify the matched 
    +events later on. 
    +<span class="label label-danger">Attention</span> State names **CANNOT**
contain the character `:`.
    +In the remainder, we start by describing how to define [States](#states), before describing
how you can 
    +combine individual states into [Complex Patterns](#combining-states).
    +### Individual States
    +A **State** can be either a *singleton* state, or a *looping* one. Singleton states accept
a single event, 
    +while looping ones accept more than one. In pattern matching symbols, in the pattern
`a b+ c? d` (or `a`, 
    +followed by *one or more* `b`'s, optionally followed by a `c`, followed by a `d`), `a`,
`c?`, and `d` are 
    +singleton patterns, while `b+` is a looping one (see [Quantifiers](#quantifiers)). In
addition, each state 
    +can have one or more *conditions* based on which it accepts events (see [Conditions](#conditions)).
    --- End diff --
    Perhaps somewhere in this paragraph, describe that by default, states are singleton? and
to make it a looping one, use quantifiers.
    There is a sentence mentioning for looping state see quantifiers, but we can make the
information a bit more explicit.

> Update the documentation of the CEP library to include all the new features.
> ----------------------------------------------------------------------------
>                 Key: FLINK-6198
>                 URL: https://issues.apache.org/jira/browse/FLINK-6198
>             Project: Flink
>          Issue Type: Sub-task
>          Components: CEP
>    Affects Versions: 1.3.0
>            Reporter: Kostas Kloudas
>            Assignee: Kostas Kloudas
>            Priority: Critical
>             Fix For: 1.3.0
> New features to include:
> * Iterative Functions
> * Quantifiers
> * Time handling
> * Migration from FilterFunction to IterativeCondition

This message was sent by Atlassian JIRA

View raw message