Age | Commit message (Collapse) | Author | Files | Lines |
|
Fixes #272
The TaskMonitor urls we create aren't correct per Redfish. Per DSP0266
section 12.2, our TaskMonitor URIs should take the form
/redfish/v1/TaskService/TaskMonitors/<id>
Note that even though this appears to be a collection, it is not, and
does not "exist" in the Redfish schema, hence why it is called out
explicitly.
Tested:
Started dump collection task with
POST
```
/redfish/v1/Managers/bmc/LogServices/Dump/Actions/LogService.CollectDiagnosticData
```
GET /redfish/v1/Tasks/0
Returned TaskMonitor = /redfish/v1/Tasks/TaskMonitors/0
GET /redfish/v1/Tasks/TaskMonitors/0 returned 200
Change-Id: I9fb1d62090f7787d7649c077b748b51ac3202f8a
Signed-off-by: Ed Tanous <ed@tanous.net>
|
|
Reorganize the existing schemas into folders under redfish core.
The existing schema system has some problems:
1. It's hard to add new schemas
2. We have to rerun the script any time we want to change what schemas
we use.
3. Adding schemas optionally takes effort
In an effort to combat this, this patchset moves all the existing
schemas into folders that represent their namespace names
dmtf/csdl represents the CSDL that dmtf publishes
oem/openbmc represents the CSDL that OpenBMC publishes
In theory, this means that in the future we can relax OEM_SCHEMAS.md,
and allow folks to possibly implement their own schemas in a way that
doesn't have to effect all other systems.
This also has the advantage of not requiring changes to
update_schemas.py when we want to add, remove, or modify what version of
a schema we use. "current" schemas are just symlinks, so they can be
updated using git, and not necessarily have merge conflicts with one
another.
Tested: Redfish service validator passes.
Change-Id: I6d4a130bba4cb874ef00a06ed579cc67f53dc7ae
Signed-off-by: Ed Tanous <ed@tanous.net>
|
|
These were found with:
codespell -w $(git ls-files | grep "\.[hc]\(pp\)\?$")
At some point in the future, we might want to get this enabled in CI.
Change-Id: Iccb57b2adfd06a2e177e99db2923fe4e8e329118
Signed-off-by: Ed Tanous <ed@tanous.net>
|
|
Utilize the new array of top level collection URIs to determine if a
given URI in the response needs to have the aggregation prefix added.
This removes the need to check for specific collections like
/redfish/v1/UpdateService/FirmwareInventory which do not fit the
generic format of /redfish/v1/<collection>.
Future patches will use this same approach to improve the logic for
initially determining if and how a request should be aggregated.
This patch also adds a series of unit tests for the function
responsible for adding a prefix to a given URI. Cases covered include
valid URIs that involve a selection of aggregated resources, top level
collection URIs, other invalid URIs, and URIs with a trailing "/".
Tested:
Unit tests pass.
Signed-off-by: Carson Labrado <clabrado@google.com>
Change-Id: I676983d3c77ae3126c04e9f57ad8698c51df2675
|
|
In aggregation we need to account for when a satellite BMC supports a
resource collection that the aggregating BMC does not. We need to
add links in responses from upstream resources to indicate that these
satellite only resources exist. These top level collections do not
always have the location format of /redfish/v1/<collection_id>. We
determine all of those from the schema rather than hardcoding a few
choice exceptions that do not fit that format such as
/redfish/v1/UpdateService/FirmwareInventory.
This patch is the first step in accomplishing this. We parse all
xml schema files in order to determine what are the top level
collection URIs. For URIs that are upstream from top level collections
we'll be able to derive what URIs could appear in the response which
are also on the same path to a top level collection.
The xml files for resources that aren't currently supported by bmcweb
are ignored when creating the schema index and later deleted once the
above parsing completes.
Later patches will use this information to make sure that we are
properly handling all schema defined top level collections.
Tested:
Compiles with aggregation enabled
Signed-off-by: Carson Labrado <clabrado@google.com>
Change-Id: Icff825f4e4e9d84c96254561350f82839abdc074
|