Skip to content

Commit

Permalink
Merge pull request #690 from telefonicaid/AlvaroVega-patch-3
Browse files Browse the repository at this point in the history
Update plain_rules.md
  • Loading branch information
fgalan committed Jun 22, 2022
2 parents 36874c7 + e3dc497 commit 3604ad4
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions docs/API/plain_rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
- [EPL text](#epl-text)
- [Pre-SELECT clauses](#pre-select-clauses)
- [No signal conditions](#no-signal-conditions)
- [No signal actions](#no-signal-actions)
- [Actions](#actions)
- [String substitution syntax](#string-substitution-syntax)
- [SMS action](#sms-action)
Expand Down Expand Up @@ -170,17 +171,29 @@ fields:
- **checkInterval**: _mandatory_, time in minutes for checking the attribute. Min value is 0.5 and max is 35791, other
values are truncated to them (a warning log message is generated if such truncation occurs)
- **attribute**: _mandatory_, attribute for watch
- **reportInterval**: _mandatory_, time in seconds to see an entity as silent
- **reportInterval**: _mandatory_, time in seconds to see an entity as silent (in other words, how much time has to pass since last entity update to consider that entity is in "no signal" situation so the rule is triggered)
- **id** or **idRegexp**: _mandatory_ (but not both at the same time), ID or regular expression of the entity to watch
- type: _optional_, type of entities to watch

Is recommended to set checkInterval at least double of reportInterval. Howeer, note that a very demanding value of
checkInterval could impact on performance.

<a name="actions"></a>
## Non signal actions

The following virtual attributes are available to be used in non signal template actions:
- **service**: service of rule
- **subservice**: subservice of rule
- **ruleName**: name of the rule
- **reportInterval**: time to see an entity as silent (in other words, how much time has to pass since last entity update to consider that entity is in "no signal" situation so the rule is triggered)
- **id**: entity id
- **type**: entity type
- **internalCurrentTime**: current time
- **lastTime**: lastTime rule was executed as well as all entity attributes

## Actions

<a name="actions"></a>

When a rule is fired, the "complex event" generated by the select clause is sent to perseo (front-end) which executes
the action using the generated event as parameter to the action.

Expand Down

0 comments on commit 3604ad4

Please sign in to comment.