You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by GitBox <gi...@apache.org> on 2020/02/13 13:28:43 UTC

[GitHub] [nifi-minifi-cpp] bakaid commented on a change in pull request #735: MINIFICPP-1158 - Event driven processors can starve each other

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

 ##########
 File path: libminifi/src/EventDrivenSchedulingAgent.cpp
 ##########
 @@ -44,16 +44,8 @@ uint64_t EventDrivenSchedulingAgent::run(const std::shared_ptr<core::Processor>
       // No work to do or need to apply back pressure
       return this->bored_yield_duration_;
     }
-
-    // Block until work is available
-
-    processor->waitForWork(1000);
-
-    if (!processor->isWorkAvailable()) {
-      return 1000;
-    }
   }
-  return 0;
+  return 10;  // Let's check back for work in 10ms or when a thread is available to execute
 
 Review comment:
   This limits the event driven processors to 100 triggers/sec, and in case they don't/can't use batching to 100 FF/s, even when we know they would have work to do. This would broke many flows out in the wild. We should find a way to solve the starvation issue without introducing a bottleneck.

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


With regards,
Apache Git Services