Transition to simpler trigger interface
Using this simpler interface allows us to simplify the unpacking code,
and remove the use of a variant containing a variant, which has caused
bugs in the past. Splitting these apart allows us to replicate the
Redfish interfaces with less code.
Tested:
Discrete and Numeric triggers both create correctly
```
curl -k --user "root:0penBmc" -H "Content-Type: application/json" -X POST https://192.168.7.2/redfish/v1/TelemetryService/Triggers -d '{"Name": "eds", "NumericThresholds": {"LowerCritical": {"Reading": 1.0, "Activation": "Increasing", "DwellTime": "P1S"}}}'
curl -k --user "root:0penBmc" -H "Content-Type: application/json" -X POST https://192.168.7.2/redfish/v1/TelemetryService/Triggers -d '{"Name": "eds", "DiscreteTriggers": [{"DwellTime": "P1S", "Severity": "OK", "Value": "1234"}]}
```
Change-Id: If898e2285f90f78b22e47cc670e4206ba4368665
Signed-off-by: Ed Tanous <etanous@nvidia.com>
diff --git a/include/dbus_utility.hpp b/include/dbus_utility.hpp
index 50d75c5..89cda89 100644
--- a/include/dbus_utility.hpp
+++ b/include/dbus_utility.hpp
@@ -71,13 +71,8 @@
std::vector<std::tuple<sdbusplus::message::object_path, std::string>>,
std::string, std::string, uint64_t>>,
std::vector<std::pair<sdbusplus::message::object_path, std::string>>,
-
- // TODO This needs looked at. It's used in the trigger system, but a
- // variant of a variant seems really odd
- std::variant<
- std::vector<std::tuple<std::string, uint64_t, std::string, double>>,
- std::vector<std::tuple<std::string, std::string, uint64_t, std::string>>
- >
+ std::vector<std::tuple<std::string, uint64_t, std::string, double>>,
+ std::vector<std::tuple<std::string, std::string, uint64_t, std::string>>
>;
// clang-format on