James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 1 | { |
Brad Bishop | 64d7cec | 2020-05-01 10:00:23 -0400 | [diff] [blame] | 2 | "$schema": "http://json-schema.org/draft-07/schema#", |
Brad Bishop | 8e659b5 | 2020-05-07 17:31:04 -0400 | [diff] [blame] | 3 | "definitions": { |
Brad Bishop | ada40c5 | 2020-05-07 19:32:05 -0400 | [diff] [blame] | 4 | "EMExposesElement": { |
| 5 | "description": [ |
| 6 | "The exposes property element schema. An element of the exposes ", |
| 7 | "property is always an array where elements are of type exposes ", |
| 8 | "entry." |
| 9 | ], |
| 10 | "oneOf": [ |
| 11 | { |
Brad Bishop | 4afe708 | 2020-10-01 09:59:26 -0400 | [diff] [blame^] | 12 | "$ref": "IBM.json#/definitions/IBMCFFPSConnector" |
| 13 | }, |
| 14 | { |
Brad Bishop | dc10828 | 2020-09-24 19:01:28 -0400 | [diff] [blame] | 15 | "$ref": "Intel.json#/definitions/IntelFanConnector" |
| 16 | }, |
| 17 | { |
Brad Bishop | 4fa1d39 | 2020-05-07 20:27:15 -0400 | [diff] [blame] | 18 | "$ref": "Pid.json#/definitions/Pid" |
| 19 | }, |
| 20 | { |
| 21 | "$ref": "Pid.Zone.json#/definitions/PidZone" |
| 22 | }, |
| 23 | { |
| 24 | "$ref": "Stepwise.json#/definitions/Stepwise" |
| 25 | }, |
| 26 | { |
Brad Bishop | ada40c5 | 2020-05-07 19:32:05 -0400 | [diff] [blame] | 27 | "$ref": "legacy.json#/definitions/Aggregate" |
| 28 | }, |
| 29 | { |
| 30 | "description": [ |
| 31 | "Ensure the parent oneOf schema does not validate ", |
| 32 | "when an element does not define a type property." |
| 33 | ], |
| 34 | "not": { |
| 35 | "required": [ |
| 36 | "Type" |
| 37 | ] |
| 38 | }, |
| 39 | "title": "Missing Type" |
| 40 | }, |
| 41 | { |
| 42 | "description": [ |
| 43 | "Ensure the parent oneOf schema does not validate ", |
| 44 | "when an element does not define a name property." |
| 45 | ], |
| 46 | "not": { |
| 47 | "required": [ |
| 48 | "Name" |
| 49 | ] |
| 50 | }, |
| 51 | "title": "Missing Name" |
| 52 | } |
| 53 | ], |
| 54 | "title": "Exposes Property Element" |
| 55 | }, |
Brad Bishop | 8e659b5 | 2020-05-07 17:31:04 -0400 | [diff] [blame] | 56 | "EMConfig": { |
Brad Bishop | 2189d61 | 2020-05-07 19:27:44 -0400 | [diff] [blame] | 57 | "title": "Entity Manager Configuration", |
| 58 | "description": [ |
| 59 | "The schema for an entity manager configuration. An entity ", |
| 60 | "manager configuration describes an association between a ", |
| 61 | "match condition, also known as a probe, and an array of ", |
| 62 | "heterogeneous configuration data. When a probe match ", |
| 63 | "occurs, the configuration data is exported to DBus." |
| 64 | ], |
Brad Bishop | 9453a68 | 2020-05-07 19:12:46 -0400 | [diff] [blame] | 65 | "additionalProperties": false, |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 66 | "type": "object", |
| 67 | "properties": { |
Brad Bishop | 9453a68 | 2020-05-07 19:12:46 -0400 | [diff] [blame] | 68 | "Bus": { |
| 69 | "type": "string" |
| 70 | }, |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 71 | "Exposes": { |
Brad Bishop | 2189d61 | 2020-05-07 19:27:44 -0400 | [diff] [blame] | 72 | "description": [ |
| 73 | "The schema for the exposes property. The exposes ", |
| 74 | "property must be an array where elements are of ", |
| 75 | "type EMExposesElement. The exposes property is the ", |
| 76 | "heterogeneous configuration data exported to DBus ", |
| 77 | "upon a probe match." |
| 78 | ], |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 79 | "type": "array", |
| 80 | "items": { |
Brad Bishop | ada40c5 | 2020-05-07 19:32:05 -0400 | [diff] [blame] | 81 | "$ref": "#/definitions/EMExposesElement" |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 82 | } |
| 83 | }, |
Brad Bishop | 9453a68 | 2020-05-07 19:12:46 -0400 | [diff] [blame] | 84 | "Logging": { |
| 85 | "enum": [ |
| 86 | "Off" |
| 87 | ] |
| 88 | }, |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 89 | "Name": { |
Brad Bishop | 2189d61 | 2020-05-07 19:27:44 -0400 | [diff] [blame] | 90 | "description": [ |
| 91 | "The schema for the name property. The name property ", |
| 92 | "identifies the configuration. When exported, the ", |
| 93 | "configuration will be instantiated at: ", |
| 94 | "/xyz/openbmc_project/configuration/<Type>/<Name>" |
| 95 | ], |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 96 | "type": "string" |
| 97 | }, |
| 98 | "Probe": { |
Brad Bishop | 2189d61 | 2020-05-07 19:27:44 -0400 | [diff] [blame] | 99 | "description": [ |
| 100 | "The schema for an entity manager probe statement. ", |
| 101 | "Probes can be a single string or an array. Probes ", |
| 102 | "describe a match condition, for example when a DBus ", |
| 103 | "property has a specific value. When the match condition", |
| 104 | " occurs, the information described by the Exposes ", |
| 105 | "property is exported onto the DBus." |
| 106 | ], |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 107 | "anyOf": [ |
| 108 | { |
| 109 | "type": "string" |
| 110 | }, |
| 111 | { |
| 112 | "type": "array", |
| 113 | "items": { |
| 114 | "type": "string" |
| 115 | } |
| 116 | } |
| 117 | ] |
| 118 | }, |
James Feist | 60d93d2 | 2019-07-10 15:08:35 -0700 | [diff] [blame] | 119 | "Type": { |
Brad Bishop | 2189d61 | 2020-05-07 19:27:44 -0400 | [diff] [blame] | 120 | "title": "Configuration Type", |
| 121 | "description": [ |
| 122 | "The schema for the type property. The type property", |
| 123 | "identifies the type of the configuration. When exported,", |
| 124 | "configurations will be instantiated as children of: ", |
| 125 | "/xyz/openbmc_project/configuration/<Type>" |
| 126 | ], |
Brad Bishop | 45d42a5 | 2020-05-07 19:19:49 -0400 | [diff] [blame] | 127 | "enum": [ |
| 128 | "Board", |
| 129 | "Chassis", |
| 130 | "NVMe", |
| 131 | "PowerSupply" |
| 132 | ] |
James Feist | 60d93d2 | 2019-07-10 15:08:35 -0700 | [diff] [blame] | 133 | }, |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 134 | "xyz.openbmc_project.Inventory.Decorator.Asset": { |
Brad Bishop | b980991 | 2020-05-07 17:15:31 -0400 | [diff] [blame] | 135 | "$ref": "openbmc-dbus.json#/definitions/xyz/openbmc_project/Inventory/Decorator/Asset" |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 136 | }, |
James Feist | 60d93d2 | 2019-07-10 15:08:35 -0700 | [diff] [blame] | 137 | "ProductId": { |
| 138 | "type": "number" |
| 139 | }, |
| 140 | "xyz.openbmc_project.Inventory.Decorator.AssetTag": { |
Brad Bishop | b980991 | 2020-05-07 17:15:31 -0400 | [diff] [blame] | 141 | "$ref": "openbmc-dbus.json#/definitions/xyz/openbmc_project/Inventory/Decorator/AssetTag" |
James Feist | 60d93d2 | 2019-07-10 15:08:35 -0700 | [diff] [blame] | 142 | }, |
Brad Bishop | 9453a68 | 2020-05-07 19:12:46 -0400 | [diff] [blame] | 143 | "xyz.openbmc_project.Inventory.Item.Board.Motherboard": { |
| 144 | "$ref": "openbmc-dbus.json#/definitions/xyz/openbmc_project/Inventory/Item/Board/Motherboard" |
| 145 | }, |
| 146 | "xyz.openbmc_project.Inventory.Item.Chassis": { |
| 147 | "$ref": "openbmc-dbus.json#/definitions/xyz/openbmc_project/Inventory/Item/Chassis" |
| 148 | }, |
| 149 | "xyz.openbmc_project.Inventory.Item.Panel": { |
| 150 | "$ref": "openbmc-dbus.json#/definitions/xyz/openbmc_project/Inventory/Item/Panel" |
| 151 | }, |
James Feist | 60d93d2 | 2019-07-10 15:08:35 -0700 | [diff] [blame] | 152 | "xyz.openbmc_project.Inventory.Item.System": { |
Brad Bishop | b980991 | 2020-05-07 17:15:31 -0400 | [diff] [blame] | 153 | "$ref": "openbmc-dbus.json#/definitions/xyz/openbmc_project/Inventory/Item/System" |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 154 | } |
| 155 | }, |
| 156 | "required": [ |
| 157 | "Exposes", |
| 158 | "Name", |
Brad Bishop | 45d42a5 | 2020-05-07 19:19:49 -0400 | [diff] [blame] | 159 | "Probe", |
| 160 | "Type" |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 161 | ] |
| 162 | } |
Brad Bishop | 8e659b5 | 2020-05-07 17:31:04 -0400 | [diff] [blame] | 163 | }, |
Brad Bishop | 2189d61 | 2020-05-07 19:27:44 -0400 | [diff] [blame] | 164 | "title": "Entity Manager Configuration File", |
| 165 | "description": [ |
| 166 | "The schema for an entity manager configuration file. An entity ", |
| 167 | "mananger configuration file can consist of a single object, or an ", |
| 168 | "array of objects. Objects must be of type EMConfig." |
| 169 | ], |
Brad Bishop | 8e659b5 | 2020-05-07 17:31:04 -0400 | [diff] [blame] | 170 | "anyOf": [ |
| 171 | { |
| 172 | "type": "array", |
| 173 | "items": { |
| 174 | "$ref": "#/definitions/EMConfig" |
| 175 | } |
| 176 | }, |
| 177 | { |
| 178 | "$ref": "#/definitions/EMConfig" |
| 179 | } |
James Feist | 1e3e698 | 2018-08-03 16:09:28 -0700 | [diff] [blame] | 180 | ] |
| 181 | } |