bakaid 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_r396393474
 
 

 ##########
 File path: libminifi/include/c2/C2Agent.h
 ##########
 @@ -52,39 +55,28 @@ namespace c2 {
  *   0 HeartBeat --  RESERVED
  *   1-255 Defined by the configuration file.
  */
-class C2Agent : public state::UpdateController, public 
state::response::ResponseNodeSink, public std::enable_shared_from_this<C2Agent> 
{
+class C2Agent : public state::UpdateController {
  public:
 
-  C2Agent(const std::shared_ptr<core::controller::ControllerServiceProvider> 
&controller, const std::shared_ptr<state::StateMonitor> &updateSink, const 
std::shared_ptr<Configure> &configure);
+  C2Agent(const std::shared_ptr<core::controller::ControllerServiceProvider> 
&controller,
+          const std::shared_ptr<state::StateMonitor> &updateSink,
+          const std::shared_ptr<Configure> &configure,
+          utils::ThreadPool<utils::TaskRescheduleInfo> &pool);
 
 Review comment:
   Using the `FlowController`'s thread pool for this can be dangerous.
   I do not want Processors to potentially starve C2. For example, if a 
processor gets stuck in a long onTrigger, I want to be able to reload the 
configuration (or at least restart the agent) through C2. This way Processors 
and the C2 has to share resources.
   I would prefer this to remain more like it was, with C2 owning its own 
threadpool, not sharing it (for the time being, with some refactor not even a 
threadpool would be needed).
   @arpadboda what's your take on this?

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to