0

We have using CEP already to manipulate some events. We have been using patterns from cep to correlate the events and produce meaningful outputs. For example we have the pattern sequence that a.followedBy b followed by c. So far the events were coming in order {a1,b1,c1}, {a2,b2,c2} etc. If now the sequence of the events change and even the sequence is not completed for example {a1,b1,a2,c1,b2,a3,b3,c3} or sometimes the sequence is not complete etc, is it possible to detect this and produce correct outputs {a1,b1,c1} and {a3,b3,c3}; I have tried to enhance the patterns using iterative condition but it seems the missing events break the matching and nothing is produced as ouput.

IsidIoan
  • 403
  • 2
  • 5
  • 13

1 Answers1

0

When you use keyBy with CEP, then each key-partitioned stream is matched independently. So if, for example, you key the stream {a1,b1,a2,c1,b2,a3,b3,c3} by the digits (1, 2, and 3) then CEP will separately apply the pattern to these three streams

{a1,b1,c1}
{a2,b2}
{a3,b3,c3}

and the two streams that are complete will match.

David Anderson
  • 39,434
  • 4
  • 33
  • 60