control: Trace around enabling events
Add flight recorder entries before and after fan control events are
enabled on startup. This can be used for debug to tell how long the
enables take.
e.g.
```
"Jan 10 16:03:11.329067: main: Enabling events",
"Jan 10 16:03:11.385515: zone-floor0: mapped_floor-70(Fan floors) is setting floor hold to 7300",
"Jan 10 16:03:11.385534: zone-floor0: Setting new floor to 7300",
"Jan 10 16:03:13.951341: main: Done enabling events",
```
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I5753617a38972b28ab12b314576c8774ee73c37e
diff --git a/control/json/manager.cpp b/control/json/manager.cpp
index 147fe9a..8adc80c 100644
--- a/control/json/manager.cpp
+++ b/control/json/manager.cpp
@@ -217,8 +217,10 @@
// Enable events
_events = std::move(events);
+ FlightRecorder::instance().log("main", "Enabling events");
std::for_each(_events.begin(), _events.end(),
[](const auto& entry) { entry.second->enable(); });
+ FlightRecorder::instance().log("main", "Done enabling events");
_loadAllowed = false;
}