Description
The action manager modules’ threshold could be:
- Manual: with a set value
- Adaptive: the threshold is defined as a formula that would be evaluated for each entity during the alert check
Each module will specify the context variables that can be used in the formula. (Look at the threshold tooltip.)
Formula documentation
Read this documentation to understand the formula syntax.
How to use Formula for Adaptive Threshold
Supported context variables for Adaptive Threshold:
- site: {slug, properties}
- area: {slug, properties}
- line: {slug, properties}
- machine: {slug, properties}
- step: {attributes, substep: { attributes } }
- WARNING for this variable:
- Do not use this variable if the entity is not a line or a machine, otherwise we can't identify which
step to load. (e.g a site can have multiple steps through its lines)
- Can't be used for line/machine linked to ReactJobs that have multiple steps.
The substep field contains {attributes} from the ONE matching substep.
Access like: step.substep.attributes.some_attribute
- WARNING for substep:
- Only available when the entity being reported on IS a machine (not for line entities)
- SubstepMachineMapping is resolved by:
- machine_id equals to the machine we are reporting on (this has priority over machine_type)
- OR machine_type equals to the machine type we are reporting on
Each module could have a restricted list of variable access, read the tooltip before using the variables.