schema: add restricted range for severity
There are 5 threshold types: Warning, Critical, PerformanceLoss,
SoftShutdown, and HardShutdown. Restrict valid severity numbers to
0 - 4 to correspond with these. We could change this to a string
enum which would be easier to understand but that would require
changing the apps that already use these numbers.
Change-Id: I801f09ddd24cacf8ae22a6a164428d08ccce7c62
Signed-off-by: Rashmica Gupta <rashmica.g@gmail.com>
diff --git a/schemas/legacy.json b/schemas/legacy.json
index 6e5a93b..6fd6ba3 100644
--- a/schemas/legacy.json
+++ b/schemas/legacy.json
@@ -677,7 +677,9 @@
"type": "string"
},
"Severity": {
- "type": "number"
+ "type": "number",
+ "minimum": 0,
+ "maximum": 4
},
"Value": {
"type": "number"