You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@eagle.apache.org by Grainier Perera <gr...@gmail.com> on 2019/09/12 02:11:05 UTC

Clarification on alert PolicyInterpreter

Hi Devs,

In several test scenarios[1], only the query get parsed (without stream
definitions). I wonder, is this just for testing purposes? or can there be
real scenarios where `PolicyInterpreter.parseExecutionPlan()`[2] gets
called with just a query (starting with `from fooStream ...`) instead of a
complete SiddhiApp?

Because with Siddhi 5.x.x it mandates the inputStream to be defined when
parsing the Siddhi App. Then we have to re-think, maybe to infer
definitions?

[1]
https://github.com/apache/eagle/blob/master/eagle-core/eagle-alert-parent/eagle-alert/alert-engine/src/test/java/org/apache/eagle/alert/engine/interpreter/PolicyInterpreterTest.java#L40
[2]
https://github.com/apache/eagle/blob/master/eagle-core/eagle-alert-parent/eagle-alert/alert-engine/src/main/java/org/apache/eagle/alert/engine/interpreter/PolicyInterpreter.java#L73

- Grainier