Update fan added / removed to use string
Fan names aren't always fan %d, sometimes there are numbers
too, or identifiers like CPU Fan 1. Change the argument to
a string.
Tested: Launched bmcweb and saw:
{
"@odata.context": "/redfish/v1/$metadata#LogEntry.LogEntry",
"@odata.id": "/redfish/v1/Systems/system/LogServices/EventLog/Entries/#1556037042",
"@odata.type": "#LogEntry.v1_4_0.LogEntry",
"Created": "2019-04-23T16:30:42+00:00",
"EntryType": "Event",
"Id": "1556037042",
"Message": "Fan 1 removed.",
"MessageArgs": [
"Fan 1"
],
"MessageId": "OpenBMC.0.1.FanRemoved",
"Name": "System Event Log Entry",
"Severity": "OK"
},
{
"@odata.context": "/redfish/v1/$metadata#LogEntry.LogEntry",
"@odata.id": "/redfish/v1/Systems/system/LogServices/EventLog/Entries/#1556037055",
"@odata.type": "#LogEntry.v1_4_0.LogEntry",
"Created": "2019-04-23T16:30:55+00:00",
"EntryType": "Event",
"Id": "1556037055",
"Message": "Fan 1 inserted.",
"MessageArgs": [
"Fan 1"
],
"MessageId": "OpenBMC.0.1.FanInserted",
"Name": "System Event Log Entry",
"Severity": "OK"
},
Change-Id: Ic0d07ea1c96ee6a61caa912ecd091c2783f1d963
Signed-off-by: James Feist <james.feist@linux.intel.com>
diff --git a/redfish-core/include/registries/openbmc_message_registry.hpp b/redfish-core/include/registries/openbmc_message_registry.hpp
index 662aa88..319f663 100644
--- a/redfish-core/include/registries/openbmc_message_registry.hpp
+++ b/redfish-core/include/registries/openbmc_message_registry.hpp
@@ -129,10 +129,10 @@
"FanInserted",
{
.description = "Indicates that a system fan has been inserted.",
- .message = "Fan %1 inserted.",
+ .message = "%1 inserted.",
.severity = "OK",
.numberOfArgs = 1,
- .paramTypes = {"number"},
+ .paramTypes = {"string"},
.resolution = "None.",
}},
MessageEntry{"FanRedundancyLost",
@@ -160,10 +160,10 @@
"FanRemoved",
{
.description = "Indicates that a system fan has been removed.",
- .message = "Fan %1 removed.",
- .severity = "Warning",
+ .message = "%1 removed.",
+ .severity = "OK",
.numberOfArgs = 1,
- .paramTypes = {"number"},
+ .paramTypes = {"string"},
.resolution = "None.",
}},
MessageEntry{