<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Concurrent task and Max Timer Driven Thread Count in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Concurrent-task-and-Max-Timer-Driven-Thread-Count/m-p/406201#M252523</link>
    <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/35454"&gt;@MattWho&lt;/a&gt;&amp;nbsp;for your response.&lt;/P&gt;</description>
    <pubDate>Mon, 14 Apr 2025 15:12:14 GMT</pubDate>
    <dc:creator>nifier</dc:creator>
    <dc:date>2025-04-14T15:12:14Z</dc:date>
    <item>
      <title>Concurrent task and Max Timer Driven Thread Count</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Concurrent-task-and-Max-Timer-Driven-Thread-Count/m-p/405885#M252511</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;We are in the process of fine tuning the performance of our NiFi nodes.&lt;/P&gt;&lt;P&gt;1. Regarding "&lt;SPAN&gt;Max Timer Driven Thread Count" the default value is set as 10.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Is this value okay given that we have 4 core CPU ?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2. For "Concurrent task" how do we figure the optimal value ?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Also. does this value has to be same for all the Processors in the flow ?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 10 Apr 2025 18:33:59 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Concurrent-task-and-Max-Timer-Driven-Thread-Count/m-p/405885#M252511</guid>
      <dc:creator>nifier</dc:creator>
      <dc:date>2025-04-10T18:33:59Z</dc:date>
    </item>
    <item>
      <title>Re: Concurrent task and Max Timer Driven Thread Count</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Concurrent-task-and-Max-Timer-Driven-Thread-Count/m-p/405935#M252518</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/117603"&gt;@nifier&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;NiFi is flow based programming, so tuning is directly related to the dataflows you build and the volumes of data you process.&amp;nbsp; &amp;nbsp;Optimal values come from testing your "program" dataflow.&amp;nbsp; Aside from NiFi settings in NiFi you have to consider any other program running on the same server as NiFi as they will also consume CPU resources.&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;Max Timer Driven Thread Count":&lt;BR /&gt;&lt;/SPAN&gt;This is the thread pool for all your timer driven/cron driven components you add to your NiFi canvas.&amp;nbsp; The general guidance here is start with 4 X the number of cores.&amp;nbsp; So for you that would be 16.&amp;nbsp; &amp;nbsp;Then you'll need to test/monitor your server CPU load average while your dataflow(s) aer running under expected loads.&amp;nbsp; &amp;nbsp; If your load average is very close to or exceeds your core count, you'll need to back off on the size of your thread pool.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;"Concurrent task"&lt;/SPAN&gt;&lt;BR /&gt;Configurable setting on processor components that allow multiple concurrent executions of the processor.&amp;nbsp; This works in conjunction with the runs schedule set on the processor.&amp;nbsp; &amp;nbsp;When a a processor is "scheduled" the processor will need a thread from the thread pool.&amp;nbsp; Assuming concurrent task more then default 1, If there is still "work" to do at next scheduled run time and the previous concurrent task is still executing or pending execution,&amp;nbsp; the additional concurrent task will allow another concurrent execution to get scheduled.&amp;nbsp; &amp;nbsp;Scheduled i s different from execution.&amp;nbsp; You can have a bunch of scheduled tasks waiting for an available thread from the thread pool to execute.&amp;nbsp; With most processors, execution is milliseconds, so working through the pool of scheduled processors is fast and efficient.&amp;nbsp; &amp;nbsp;The general guidance with "concurrent tasks" is start with default of 1 concurrent task, monitor your dataflows and adjust in increments of 1 only where is needed.&amp;nbsp; Dataflow developers tend to make the mistake of setting some larger value from the start which is a bad idea.&amp;nbsp; &amp;nbsp; &amp;nbsp;You'll want to look at your dataflows under load and see at which processor furthest down your dataflow path is developing an ever increasing backlog of FlowFiles on its inbound connection.&amp;nbsp; A growing backlog on a connection will eventually trigger backpressure controls to kick in (connection turns red).&amp;nbsp; Once back pressure kicks in the upstream processor feeding that connection will no longer we allowed to schedule until the downstream connection backpressure is lifted.&amp;nbsp; So this a processor that is blocked will start queuing FlowFile upstream from it.&amp;nbsp; &amp;nbsp; This can lead to backpressure all the way to start of the dataflow.&amp;nbsp; So do NOT simply adjust concurrent task&amp;nbsp; on all these processors, instead only increase concurrent task on the one furthest down the dataflow to unblock back pressure there which will naturally allow upstream to get scheduled again.&amp;nbsp; &amp;nbsp;The dangers of of setting large concurrent task values is you end up with a lot more scheduled tasks all waiting for CPU time.&amp;nbsp; If you set concurrent task high on CPU intensive processor, those processor may take all your CPU preventing other processors from getting an opportunity to execute for long periods of time.&lt;BR /&gt;&lt;BR /&gt;NOTE: The embedded documentation for each NiFi processor has a resource consideration section that will highlight if the processor has MEMORY or CPU resource considerations.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Please help our community grow. If you found&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;any&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;of the suggestions/solutions provided helped you with solving your issue or answering your question, please take a moment to login and click "&lt;SPAN&gt;&lt;EM&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;Accept as Solution&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/EM&gt;" on&amp;nbsp;&lt;STRONG&gt;one or more&lt;/STRONG&gt;&amp;nbsp;of them that helped.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thank you,&lt;BR /&gt;Matt&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Apr 2025 14:03:41 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Concurrent-task-and-Max-Timer-Driven-Thread-Count/m-p/405935#M252518</guid>
      <dc:creator>MattWho</dc:creator>
      <dc:date>2025-04-11T14:03:41Z</dc:date>
    </item>
    <item>
      <title>Re: Concurrent task and Max Timer Driven Thread Count</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Concurrent-task-and-Max-Timer-Driven-Thread-Count/m-p/406201#M252523</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/35454"&gt;@MattWho&lt;/a&gt;&amp;nbsp;for your response.&lt;/P&gt;</description>
      <pubDate>Mon, 14 Apr 2025 15:12:14 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Concurrent-task-and-Max-Timer-Driven-Thread-Count/m-p/406201#M252523</guid>
      <dc:creator>nifier</dc:creator>
      <dc:date>2025-04-14T15:12:14Z</dc:date>
    </item>
  </channel>
</rss>

