Update Trigger Actions implementation

Dbus trigger action names were modified to reflect separation of
Telemetry Service from Redfish:
- LogToLogService is renamed to LogToJournal,
- RedfishEvent was renamed to LogToRedfishEventLog

Both of those logging actions, now also include trigger id and threshold
name. Threshold naming logic:
- For discrete triggers, it can be specified by user, if left empty it
  will be changed to "{Severity} condition".
- Numeric triggers have no way of naming threshold, instead its type
  will be converted to string, example "UpperWarning"
- Discrete OnChange threshold will always be named "OnChange"

Additionally, defect was found with timestamp attached to Trigger Logs:
it was a steady_clock timestamp instead of system_clock. The function
which was supposed to format it was also working incorrectly, and was
improved to work with milliseconds. This change required major refactor
of unit tests, especially for numeric threshold.

Testing done:
- LogToJournal action is working properly,
- LogToRedfishEventLog action is working properly,
- UTs are passing.

Signed-off-by: Szymon Dompke <szymon.dompke@intel.com>
Change-Id: Iae2490682f0e9e2a610b45fd8af5cc5e21e66f35
diff --git a/src/on_change_threshold.hpp b/src/on_change_threshold.hpp
index 1d4a4d0..a19a86f 100644
--- a/src/on_change_threshold.hpp
+++ b/src/on_change_threshold.hpp
@@ -1,5 +1,6 @@
 #pragma once
 
+#include "interfaces/clock.hpp"
 #include "interfaces/sensor.hpp"
 #include "interfaces/sensor_listener.hpp"
 #include "interfaces/threshold.hpp"
@@ -19,8 +20,9 @@
 {
   public:
     OnChangeThreshold(
-        Sensors sensors,
-        std::vector<std::unique_ptr<interfaces::TriggerAction>> actions);
+        const std::string& triggerId, Sensors sensors,
+        std::vector<std::unique_ptr<interfaces::TriggerAction>> actions,
+        std::unique_ptr<interfaces::Clock> clock);
     ~OnChangeThreshold()
     {}
 
@@ -30,10 +32,12 @@
     void updateSensors(Sensors newSensors) override;
 
   private:
+    const std::string& triggerId;
     Sensors sensors;
     const std::vector<std::unique_ptr<interfaces::TriggerAction>> actions;
     bool initialized = false;
     bool isFirstReading = true;
+    std::unique_ptr<interfaces::Clock> clock;
 
-    void commit(const std::string&, Milliseconds, double);
+    void commit(const std::string&, double);
 };