-
Notifications
You must be signed in to change notification settings - Fork 3
Validators
Lorenzo Mangani edited this page Jan 1, 2018
·
2 revisions
A Validator takes a query result and compares it against a given expectation. This can be as easy as checking if a value equals a given constant or as complex as checking the average of a series of values against an allowed range with an explicit threshold.
The Range Validator checks a given Field for mix/max boundaries with tolerance factor.
Expects the following mandatory fields:
- fieldName: The name of the field in the result set, that is compared against the defined expectation.
- min: The minimum allowed value for all values within the query. If a series of values (as defined through the tolerance property) in the result is lower than this minimum an alarm is raised and reported.
- max: The maxmimum allowed value for all values within the query. If a series of values (as defined through the tolerance property) in the result exceed this maximum an alarm is raised and reported.
- tolerance: If a queried series of values exceeds either min or max for tolerance+1 times an alarm is raised.
"validators": {
"range": {
"fieldName": "value",
"min": 0,
"max": 500,
"tolerance": 4
}
},The Anomalies Validator can determine clusters of data and then also identify values which do not identify with any derived cluster and delcare them outliers.
Expects the following mandatory field:
- fieldName: The name of the field in the result set, that is tested for series anomalies.
"validators": {
"anomalies": {
"fieldName": "value"
}
},You can create custom validators by creating a new class that extends the Validator class (see RangeValidator for an example).