Fix JsonSchema indexes
JsonSchema was throwing errors in the validator, so implement changes to
the update script to add the appropiate indexes.
Tested by:
Schema validator passes on the JsonSchema Fields
Change-Id: I6cb2737901b55c1089aef744d3ce3c3dfe13f17f
Signed-off-by: Ed Tanous <ed.tanous@intel.com>
diff --git a/static/redfish/v1/JsonSchemas/Session/index.json b/static/redfish/v1/JsonSchemas/Session/index.json
index cdc5942..5c4a782 100644
--- a/static/redfish/v1/JsonSchemas/Session/index.json
+++ b/static/redfish/v1/JsonSchemas/Session/index.json
@@ -1,125 +1,21 @@
{
- "$schema": "http://redfish.dmtf.org/schemas/v1/redfish-schema.v1_2_0.json",
- "title": "#Session.v1_1_0.Session",
- "$ref": "#/definitions/Session",
- "definitions": {
- "Session": {
- "type": "object",
- "patternProperties": {
- "^([a-zA-Z_][a-zA-Z0-9_]*)?@(odata|Redfish|Message|Privileges)\\.[a-zA-Z_][a-zA-Z0-9_.]+$": {
- "type": [
- "array",
- "boolean",
- "number",
- "null",
- "object",
- "string"
- ],
- "description": "This property shall specify a valid odata or Redfish property."
- }
- },
- "additionalProperties": false,
- "properties": {
- "@odata.context": {
- "$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/context"
- },
- "@odata.id": {
- "$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/id"
- },
- "@odata.type": {
- "$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/type"
- },
- "Oem": {
- "$ref": "http://redfish.dmtf.org/schemas/v1/Resource.json#/definitions/Oem",
- "description": "This is the manufacturer/provider specific extension moniker used to divide the Oem object into sections.",
- "longDescription": "The value of this string shall be of the format for the reserved word *Oem*."
- },
- "Id": {
- "$ref": "http://redfish.dmtf.org/schemas/v1/Resource.json#/definitions/Id",
- "readonly": true
- },
- "Description": {
- "anyOf": [
- {"$ref": "http://redfish.dmtf.org/schemas/v1/Resource.json#/definitions/Description"},
- {"type": "null"}
- ],
- "readonly": true
- },
- "Name": {
- "$ref": "http://redfish.dmtf.org/schemas/v1/Resource.json#/definitions/Name",
- "readonly": true
- },
- "UserName": {
- "type": [
- "string",
- "null"
- ],
- "readonly": true,
- "description": "The UserName for the account for this session.",
- "longDescription": "The value of this property shall be the UserName that matches a registered account identified by a ManagerAccount resource registered with the Account Service."
- },
- "Password": {
- "type": [
- "string",
- "null"
- ],
- "readonly": true,
- "description": "This property is used in a POST to specify a password when creating a new session. This property is null on a GET.",
- "longDescription": "The value of this property shall be the password for this session. The value shall be null for GET requests."
- },
- "Actions": {
- "type": "object",
- "patternProperties": {
- "^([a-zA-Z_][a-zA-Z0-9_]*)?@(odata|Redfish|Message|Privileges)\\.[a-zA-Z_][a-zA-Z0-9_.]+$": {
- "type": [
- "array",
- "boolean",
- "number",
- "null",
- "object",
- "string"
- ],
- "description": "This property shall specify a valid odata or Redfish property."
- }
- },
- "additionalProperties": false,
- "properties": {
- "Oem": {
- "type": "object",
- "patternProperties": {
- "^([a-zA-Z_][a-zA-Z0-9_]*)?@(odata|Redfish|Message|Privileges)\\.[a-zA-Z_][a-zA-Z0-9_.]+$": {
- "type": [
- "array",
- "boolean",
- "number",
- "null",
- "object",
- "string"
- ],
- "description": "This property shall specify a valid odata or Redfish property."
- }
- },
- "additionalProperties": true,
- "properties": {},
- "description": "The available OEM specific actions for this resource.",
- "longDescription": "This type shall contain any additional OEM actions for this resource."
- }
- },
- "description": "The available actions for this resource.",
- "longDescription": "The Actions property shall contain the available actions for this resource."
- }
- },
- "required": [
- "Id",
- "Name"
- ],
- "requiredOnCreate": [
- "UserName",
- "Password"
- ],
- "description": "The Session resource describes a single connection (session) between a client and a Redfish service instance.",
- "longDescription": "This resource shall be used to represent a session for a Redfish implementation."
+ "@odata.context": "/redfish/v1/$metadata#JsonSchemaFile.JsonSchemaFile",
+ "@odata.id": "/redfish/v1/JSONSchemas/Session",
+ "@odata.type": "#JsonSchemaFile.v1_0_2.JsonSchemaFile",
+ "Name": "Session Schema File",
+ "Schema": "#Session.Session",
+ "Description": "Session Schema File Location",
+ "Id": "Session",
+ "Languages": [
+ "en"
+ ],
+ "Languages@odata.count": 1,
+ "Location": [
+ {
+ "Language": "en",
+ "PublicationUri": "http://redfish.dmtf.org/schemas/v1/Session.json",
+ "Uri": "/redfish/v1/JSONSchemas/Session/Session.json"
}
- },
- "copyright": "Copyright 2014-2017 Distributed Management Task Force, Inc. (DMTF). For the full DMTF copyright policy, see http://www.dmtf.org/about/policies/copyright"
-}
+ ],
+ "Location@odata.count": 1
+}
\ No newline at end of file