1$id: https://openbmc-project.xyz/sdbusplus/events.schema.yaml 2$schema: https://json-schema.org/draft/2020-12/schema 3title: Event and error definitions 4type: object 5$defs: 6 base-event: 7 type: object 8 properties: 9 name: 10 type: string 11 description: 12 An identifier for the event in UpperCamelCase; used as the 13 class and Redfish Message ID. 14 deprecated: 15 type: string 16 pattern: "^[0-9]+\\.[0-9]+\\.[0-9]+$" 17 description: 18 Indicates that the event is now deprecated and should not be 19 created by any OpenBMC software, but is required to still 20 exist for generation in the Redfish Message Registry. The 21 version listed here should be the first version where the 22 error is no longer used. 23 metadata: 24 type: array 25 items: 26 type: object 27 properties: 28 name: 29 type: string 30 pattern: "^[A-Z_][A-Z0-9_]*$" 31 description: The name of the metadata field. 32 type: 33 type: string 34 pattern: "(string)|(size)|(u?int64)|(double)|(object_path)|(enum\\[.*\\])" 35 description: The type of the metadata field. 36 primary: 37 type: boolean 38 description: 39 Set to true when the metadata field is expected 40 to be part of the Redfish `MessageArgs` (and not 41 only in the extended `DiagnosticData`). 42 required: 43 - name 44 - type 45 minItems: 1 46 required: 47 - name 48 event: 49 type: object 50 allOf: 51 - $ref: "#/$defs/base-event" 52 - oneOf: 53 - $ref: "#/$defs/redfish-messages" 54 - $ref: "#/$defs/redfish-map" 55 error: 56 type: object 57 $ref: "#/$defs/event" 58 properties: 59 severity: 60 enum: 61 - emergency 62 - alert 63 - critical 64 - error 65 - warning 66 - notice 67 - informational 68 - debug 69 description: The severity using `syslog`-style nomenclature. 70 errno: 71 type: string 72 pattern: "^E[A-Z0-9]+$" 73 description: The errno used for this error. 74 required: 75 - severity 76 - errno 77 redfish-messages: 78 type: object 79 properties: 80 en: 81 $ref: "#/$defs/redfish-lang-message" 82 description: English message details. 83 required: 84 - en 85 redfish-lang-message: 86 type: object 87 description: The message details for any language. 88 properties: 89 description: 90 type: string 91 description: 92 A developer-applicable description of the error reported. 93 These form the "description" of the Redfish message. 94 message: 95 type: string 96 description: 97 The end-user message, including placeholders for arguemnts. 98 resolution: 99 type: string 100 description: The end-user resolution. 101 required: 102 - message 103 redfish-map: 104 type: object 105 properties: 106 redfish-mapping: 107 type: string 108 description: 109 Used when a `sdbusplus` event should map to a specific 110 Redfish Message rather than a generated one. This is useful 111 when an internal error has an analog in a standardized 112 registry. 113 required: 114 - redfish-mapping 115 116properties: 117 version: 118 type: string 119 pattern: "^[0-9]+\\.[0-9]+\\.[0-9]+$" 120 description: 121 The version of the file, which will be used as the Redfish Message 122 Registry version. 123 errors: 124 type: array 125 items: 126 $ref: "#/$defs/error" 127 minItems: 1 128 events: 129 type: array 130 items: 131 $ref: "#/$defs/event" 132 minItems: 1 133required: 134 - version 135