DMTF/Redfish-Service-Validator

Should OEM actions schema checker look in /redfish/v1/JsonSchemas?

Closed this issue · 5 comments

I have an OEM action like this:

    "@odata.id": "/redfish/v1/CompositionService",
    "Actions": {
        "Oem": {
            "#Hpe_H3_CompositionService.ComposeDefault": {
                "@Redfish.ActionInfo": "/redfish/v1/Hpe_H3_CompositionService.ComposeDefaultActionInfo",
                "target": "/redfish/v1/CompositionService/Actions/Oem/Hpe_H3_CompositionService.ComposeDefault"
            }
        }
    },

And a matching schema in /redfish/v1/JsonSchemas:

    "Members": [
        ...
        {
            "@odata.id": "/redfish/v1/JsonSchemas/Hpe_H3_CompositionService"
        }

But Redfish-Service-Validator is flagging this as an error with:

ERROR - Actions: Could not finish check on this property (Could not find any Schema with these parameters Hpe_H3_CompositionService)

When I inspect the list of schemas it is looking through (self.catalog_by_class in catalog.py), that list does not appear to use anything from the OEM schemas listed in /redfish/v1/JsonSchemas. It looks like only a list of schemas downloaded directly from DMTF.

No, this tool is entirely driven from CSDL. If you're not representing OEM definitions with CSDL, it won't be able to verify OEM extensions.

Is that a limitation of this tool, or are OEM JSON schemas linked from /redfish/v1/JsonSchemas not sufficient according to a "shall" requirement in the redfish spec? I can't find a clear answer in https://www.dmtf.org/sites/default/files/standards/documents/DSP0266_1.20.0.html, but IIRC someone told me years ago that JSON schemas for OEM is sufficient.

It's just how the tool is designed; it's not a service requirement to support CSDL per Redfish. The tool was only scoped to perform verification with CSDL.

Then shouldn't this be flagged at most as a warning rather than as an error?

Yes, it should be a warning