summaryrefslogtreecommitdiff
path: root/redfish-core
diff options
context:
space:
mode:
authorGunnar Mills <gmills@us.ibm.com>2020-02-14 20:56:41 +0300
committerGunnar Mills <gmills@us.ibm.com>2020-02-19 21:55:08 +0300
commit9440096005902d13e27fdb8911d33c657f8c7b77 (patch)
tree3f40001c2a66958928f0d5728f948bdd95b71942 /redfish-core
parent890c10164e8c25f8276bc25b95e810fa30646769 (diff)
downloadbmcweb-9440096005902d13e27fdb8911d33c657f8c7b77.tar.xz
Account Service: Remove odata.context
Redfish made odata.context optional (1.6.0 of DSP0266). Redfish has removed odata.context from example payloads in the specification (1.7.0 of DSP0266), removed it from the mockups, and Redfish recommended not using. The reason for making optional and removing from mockups/examples, "no one could figure out how to use it and it did not add value". Don't see value in it for our implementation. From the Redfish issue removing it: "@odata.context provides little/no value. The common format we use provides no value/guidance. A generic odata client cannot use it because we don't return the specific version nor do we require it be changed with a query parameter. Between @odata.type and the metadata document and service document/service root, clients get all of the information they need. And the case where it is helpful (joins, etc) is something we never do." https://github.com/DMTF/Redfish-Service-Conformance-Check/pull/171 removes from Redfish-Service-Conformance-Check. Tested: Ran service validator. No errors. Ran Redfish-Service-Conformance-Check. No additional errors. Change-Id: Ic2c33080604ea275cf487e5cd5b9f7948af07db9 Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
Diffstat (limited to 'redfish-core')
-rw-r--r--redfish-core/lib/account_service.hpp10
1 files changed, 1 insertions, 9 deletions
diff --git a/redfish-core/lib/account_service.hpp b/redfish-core/lib/account_service.hpp
index 600c1a2eba..055a37b9fc 100644
--- a/redfish-core/lib/account_service.hpp
+++ b/redfish-core/lib/account_service.hpp
@@ -1138,8 +1138,6 @@ class AccountService : public Node
auto asyncResp = std::make_shared<AsyncResp>(res);
res.jsonValue = {
- {"@odata.context", "/redfish/v1/"
- "$metadata#AccountService.AccountService"},
{"@odata.id", "/redfish/v1/AccountService"},
{"@odata.type", "#AccountService."
"v1_4_0.AccountService"},
@@ -1347,11 +1345,7 @@ class AccountsCollection : public Node
const std::vector<std::string>& params) override
{
auto asyncResp = std::make_shared<AsyncResp>(res);
- res.jsonValue = {{"@odata.context",
- "/redfish/v1/"
- "$metadata#ManagerAccountCollection."
- "ManagerAccountCollection"},
- {"@odata.id", "/redfish/v1/AccountService/Accounts"},
+ res.jsonValue = {{"@odata.id", "/redfish/v1/AccountService/Accounts"},
{"@odata.type", "#ManagerAccountCollection."
"ManagerAccountCollection"},
{"Name", "Accounts Collection"},
@@ -1561,8 +1555,6 @@ class ManagerAccount : public Node
}
asyncResp->res.jsonValue = {
- {"@odata.context",
- "/redfish/v1/$metadata#ManagerAccount.ManagerAccount"},
{"@odata.type", "#ManagerAccount.v1_0_3.ManagerAccount"},
{"Name", "User Account"},
{"Description", "User Account"},