bakaid commented on a change in pull request #735: WIP: MINIFICPP-1158 - Event 
driven processors can starve each other
URL: https://github.com/apache/nifi-minifi-cpp/pull/735#discussion_r381917308
 
 

 ##########
 File path: libminifi/src/core/Processor.cpp
 ##########
 @@ -268,6 +268,7 @@ void Processor::onTrigger(const 
std::shared_ptr<ProcessContext> &context, const
 
 bool Processor::isWorkAvailable() {
   // We have work if any incoming connection has work
+  std::lock_guard<std::mutex> lock(mutex_);
 
 Review comment:
   It is pretty unclear to me what protects what in `Processor`.
   The only member access in this function is for `_incomingConnections`, which 
is a member of `Connectable`.
   Are we protecting a member of a parent class with a mutex in a child class?

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

Reply via email to