arpadboda commented on a change in pull request #743: Minificpp 1169 - Simplify
C2 metrics collection and reporting
URL: https://github.com/apache/nifi-minifi-cpp/pull/743#discussion_r389967670
##########
File path: libminifi/include/c2/C2Agent.h
##########
@@ -171,13 +159,20 @@ class C2Agent : public state::UpdateController, public
state::response::Response
*/
bool update_property(const std::string &property_name, const std::string
&property_value, bool persist = false);
+ /**
+ * Creates configuration options C2 payload for response
+ */
+ C2Payload prepareConfigurationOptions(const C2ContentResponse &resp) const;
+
+ void execute(const std::function<state::Update()>& function);
+
std::timed_mutex metrics_mutex_;
std::map<std::string, std::shared_ptr<state::response::ResponseNode>>
metrics_map_;
/**
- * Device information stored in the metrics format
- */
- std::map<std::string, std::shared_ptr<state::response::ResponseNode>>
root_response_nodes_;
+ * Device information stored in the metrics format
+ */
+ std::map<std::string, std::shared_ptr<state::response::ResponseNode>>
root_response_nodes_;
Review comment:
Wonder if we could store unique ptrs in this as well? I know this is old
code, so in case it has a bigger impact, I'm ok with a follow-up as well.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services