From bf7ef9a5b2e3a6cac3f418d3c7753f29bea66913 Mon Sep 17 00:00:00 2001 From: sunitakx Date: Tue, 18 Jan 2022 11:05:05 +0000 Subject: [PATCH] [Fix]: Property PhysicalContext is invalid "none" Issue: Redfish validator is throwing error "PhysicalContext: This type is invalid none" for multiple temperature sensors Endpoint : /redfish/v1/Chassis//Thermal#/Temperatures/ Root Cause : PhysicalContext Schema was missing from redfish schema metadata Tested: Redfish validator script passed. *** /redfish/v1/Chassis//Thermal#/Temperatures/0 Type (#Thermal.v1_3_0.Temperature), GET SUCCESS (time: 0) PASS Signed-off-by: sunitakx Change-Id: Ifbfe7d96e99030c0c5ba67a1aba5080cd049e57b --- scripts/update_schemas.py | 1 + static/redfish/v1/$metadata/index.xml | 3 + .../PhysicalContext/PhysicalContext.json | 62 +++ .../v1/JsonSchemas/PhysicalContext/index.json | 22 ++ .../redfish/v1/schema/PhysicalContext_v1.xml | 357 ++++++++++++++++++ 5 files changed, 445 insertions(+) create mode 100644 static/redfish/v1/JsonSchemas/PhysicalContext/PhysicalContext.json create mode 100644 static/redfish/v1/JsonSchemas/PhysicalContext/index.json create mode 100644 static/redfish/v1/schema/PhysicalContext_v1.xml diff --git a/scripts/update_schemas.py b/scripts/update_schemas.py index eb6318f..3f0f57c 100755 --- a/scripts/update_schemas.py +++ b/scripts/update_schemas.py @@ -65,6 +65,7 @@ include_list = [ 'PCIeDeviceCollection', 'PCIeFunction', 'PCIeFunctionCollection', + 'PhysicalContext', 'Power', 'Privileges', # Used in Role 'Processor', diff --git a/static/redfish/v1/$metadata/index.xml b/static/redfish/v1/$metadata/index.xml index c925581..9b080f3 100644 --- a/static/redfish/v1/$metadata/index.xml +++ b/static/redfish/v1/$metadata/index.xml @@ -1568,6 +1568,9 @@ + + + diff --git a/static/redfish/v1/JsonSchemas/PhysicalContext/PhysicalContext.json b/static/redfish/v1/JsonSchemas/PhysicalContext/PhysicalContext.json new file mode 100644 index 0000000..c9ffeee --- /dev/null +++ b/static/redfish/v1/JsonSchemas/PhysicalContext/PhysicalContext.json @@ -0,0 +1,62 @@ +{ + "$schema": "http://redfish.dmtf.org/schemas/v1/redfish-schema.v1_3_0.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", + "definitions": { + "PhysicalContext": { + "deprecated": "This definition has been moved to the unversioned namespace so that external references can pick up changes over time.", + "enum": [ + "Room", + "Intake", + "Exhaust", + "Front", + "Back", + "Upper", + "Lower", + "CPU", + "GPU", + "Backplane", + "SystemBoard", + "PowerSupply", + "VoltageRegulator", + "StorageDevice", + "NetworkingDevice", + "ComputeBay", + "StorageBay", + "NetworkBay", + "ExpansionBay", + "PowerSupplyBay", + "Memory", + "Chassis", + "Fan" + ], + "enumDescriptions": { + "Back": "The back of the chassis.", + "Backplane": "A backplane within the chassis.", + "CPU": "A Processor (CPU).", + "Chassis": "The entire chassis.", + "ComputeBay": "Within a compute bay.", + "Exhaust": "The exhaust point of the chassis.", + "ExpansionBay": "Within an expansion bay.", + "Fan": "A fan.", + "Front": "The front of the chassis.", + "GPU": "A Graphics Processor (GPU).", + "Intake": "The intake point of the chassis.", + "Lower": "The lower portion of the chassis.", + "Memory": "A memory device.", + "NetworkBay": "Within a networking bay.", + "NetworkingDevice": "A networking device.", + "PowerSupply": "A power supply.", + "PowerSupplyBay": "Within a power supply bay.", + "Room": "The room.", + "StorageBay": "Within a storage bay.", + "StorageDevice": "A storage device.", + "SystemBoard": "The system board (PCB).", + "Upper": "The upper portion of the chassis.", + "VoltageRegulator": "A voltage regulator device." + }, + "type": "string" + } + }, + "title": "#PhysicalContext.v1_3_0" +} + diff --git a/static/redfish/v1/JsonSchemas/PhysicalContext/index.json b/static/redfish/v1/JsonSchemas/PhysicalContext/index.json new file mode 100644 index 0000000..729c0ca --- /dev/null +++ b/static/redfish/v1/JsonSchemas/PhysicalContext/index.json @@ -0,0 +1,22 @@ +{ + "@odata.context": "/redfish/v1/$metadata#JsonSchemaFile.JsonSchemaFile", + "@odata.id": "/redfish/v1/JsonSchemas/PhysicalContext", + "@odata.type": "#JsonSchemaFile.v1_0_2.JsonSchemaFile", + "Name": "PhysicalContext Schema File", + "Schema": "#PhysicalContext.PhysicalContext", + "Description": "PhysicalContext Schema File Location", + "Id": "PhysicalContext", + "Languages": [ + "en" + ], + "Languages@odata.count": 1, + "Location": [ + { + "Language": "en", + "PublicationUri": "http://redfish.dmtf.org/schemas/v1/PhysicalContext.json", + "Uri": "/redfish/v1/JsonSchemas/PhysicalContext/PhysicalContext.json" + } + ], + "Location@odata.count": 1 +} + diff --git a/static/redfish/v1/schema/PhysicalContext_v1.xml b/static/redfish/v1/schema/PhysicalContext_v1.xml new file mode 100644 index 0000000..4c54e3e --- /dev/null +++ b/static/redfish/v1/schema/PhysicalContext_v1.xml @@ -0,0 +1,357 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- 2.17.1