<?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: Monitoring nifi queue and trigger an email when queue is 80% full in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Monitoring-nifi-queue-and-trigger-an-email-when-queue-is-80/m-p/393104#M248340</link>
    <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/112177"&gt;@NagendraKumar&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;The image you shared indicates that your PublishKafka processor is producing a bulletin.&amp;nbsp;&lt;BR /&gt;What is the nature of the exception being reported in that bulletin?&lt;BR /&gt;I also see what appears to be only one connection exiting your PublishKafka processors.&amp;nbsp; The publishKafka processor has multiple relationships. Are you auto-terminating the failure" relationship?&amp;nbsp; If so, i never recommend doing that.&lt;BR /&gt;&lt;BR /&gt;-----------&lt;BR /&gt;Now when it comes to monitoring queue sizes/thresholds, you could use the&amp;nbsp;&lt;A class="component-link" href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-standard-nar/1.27.0/org.apache.nifi.controller.ControllerStatusReportingTask/index.html" target="component-usage"&gt;ControllerStatusReportingTask&lt;/A&gt;&amp;nbsp;NiFi reporting task to output these stats for all connections to a dedicated logs (see&amp;nbsp;&lt;A href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-standard-nar/1.27.0/org.apache.nifi.controller.ControllerStatusReportingTask/additionalDetails.html" target="_blank" rel="noopener"&gt;Additional Details...&lt;/A&gt;&amp;nbsp;for how to setup dedicated logs via NiFi's logback.xml).&amp;nbsp; &amp;nbsp;You can then create a NiFi dataflow that tails the dedicated connection log and parses the ingested log entries for connections where thresholds exceed your 80% threshold and route those to a putEmail processor for yoru notification needs.&lt;BR /&gt;&lt;BR /&gt;(preferred) Another option here is to use the&amp;nbsp;&lt;A class="component-link" href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-site-to-site-reporting-nar/1.27.0/org.apache.nifi.reporting.SiteToSiteStatusReportingTask/index.html" target="component-usage"&gt;SiteToSiteStatusReportingTask&lt;/A&gt;&amp;nbsp;to report specifically on NiFi connections and feed that data in to a dataflow that parses for threshold in excess of 80% and route those to a putEmail processor.&amp;nbsp; This method has less overhead as it does not write to a NiFi log, require tailing logs, can be setup to report on connections, and reports in a more structured format (see&amp;nbsp;&lt;A href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-site-to-site-reporting-nar/1.27.0/org.apache.nifi.reporting.SiteToSiteStatusReportingTask/additionalDetails.html" target="_blank" rel="noopener"&gt;Additional Details...&lt;/A&gt;&amp;nbsp;).&lt;BR /&gt;&lt;BR /&gt;----------&lt;BR /&gt;From your image I can also see your PublishKafka processor reporting 3 actively running threads.&amp;nbsp; You mentioned the processor becomes hung?&amp;nbsp; Have you analyzed a series of thread dumps to identify where it is getting hung?&amp;nbsp;&amp;nbsp;&lt;BR /&gt;NiFi also offers a way to monitor for long running tasks:&lt;BR /&gt;&lt;A href="https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#runtime_monitoring_properties" target="_self"&gt;Runtime Monitoring Properties&lt;/A&gt;&lt;/P&gt;&lt;P&gt;You could use this in conjunction with the&amp;nbsp;&lt;A class="component-link" href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-site-to-site-reporting-nar/1.27.0/org.apache.nifi.reporting.SiteToSiteBulletinReportingTask/index.html" target="component-usage"&gt;SiteToSiteBulletinReportingTask&lt;/A&gt;&amp;nbsp;to construct a dataflow that could send an email alert when task are detected on processor that have been running in excess of the configured threshold.&amp;nbsp; This runtime monitoring does have an impact on your overall NiFi performance due to the overhead needed to run it.&amp;nbsp; So if you find it impacts your throughput performance negatively, you'll need to stop using it.&lt;/P&gt;&lt;P&gt;__________&lt;/P&gt;&lt;P&gt;Please help our community thrive. 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;</description>
    <pubDate>Thu, 05 Sep 2024 14:45:10 GMT</pubDate>
    <dc:creator>MattWho</dc:creator>
    <dc:date>2024-09-05T14:45:10Z</dc:date>
    <item>
      <title>Monitoring nifi queue and trigger an email when queue is 80% full</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Monitoring-nifi-queue-and-trigger-an-email-when-queue-is-80/m-p/390758#M247329</link>
      <description>&lt;P&gt;Good Day!&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;We have a requirement to read the TCP port data and publish it to Kafka. But at times the Kafka gets into a hung state and we need to restart the processor manually. So please help us with a way to configure the "Put Email" processor to trigger an email whenever this queue gets 80% full. Thanks in advance!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="NagendraKumar_0-1721629596750.png" style="width: 400px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/41212i5809C4ADDDAEA04F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="NagendraKumar_0-1721629596750.png" alt="NagendraKumar_0-1721629596750.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Jul 2024 06:34:11 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Monitoring-nifi-queue-and-trigger-an-email-when-queue-is-80/m-p/390758#M247329</guid>
      <dc:creator>NagendraKumar</dc:creator>
      <dc:date>2024-07-22T06:34:11Z</dc:date>
    </item>
    <item>
      <title>Re: Monitoring nifi queue and trigger an email when queue is 80% full</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Monitoring-nifi-queue-and-trigger-an-email-when-queue-is-80/m-p/392634#M248196</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/35454"&gt;@MattWho&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/80381"&gt;@SAMSAL&lt;/a&gt;&amp;nbsp;&lt;A href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/29989" target="_blank"&gt;@vaishaakb&lt;/A&gt;&amp;nbsp;- Good Day! I see most of the NiFi queries are resolved by your expertise. So please help here with your technical suggestion on the NiFi requirement. Thanks!&lt;/P&gt;</description>
      <pubDate>Tue, 27 Aug 2024 16:37:23 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Monitoring-nifi-queue-and-trigger-an-email-when-queue-is-80/m-p/392634#M248196</guid>
      <dc:creator>NagendraKumar</dc:creator>
      <dc:date>2024-08-27T16:37:23Z</dc:date>
    </item>
    <item>
      <title>Re: Monitoring nifi queue and trigger an email when queue is 80% full</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Monitoring-nifi-queue-and-trigger-an-email-when-queue-is-80/m-p/393104#M248340</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/112177"&gt;@NagendraKumar&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;The image you shared indicates that your PublishKafka processor is producing a bulletin.&amp;nbsp;&lt;BR /&gt;What is the nature of the exception being reported in that bulletin?&lt;BR /&gt;I also see what appears to be only one connection exiting your PublishKafka processors.&amp;nbsp; The publishKafka processor has multiple relationships. Are you auto-terminating the failure" relationship?&amp;nbsp; If so, i never recommend doing that.&lt;BR /&gt;&lt;BR /&gt;-----------&lt;BR /&gt;Now when it comes to monitoring queue sizes/thresholds, you could use the&amp;nbsp;&lt;A class="component-link" href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-standard-nar/1.27.0/org.apache.nifi.controller.ControllerStatusReportingTask/index.html" target="component-usage"&gt;ControllerStatusReportingTask&lt;/A&gt;&amp;nbsp;NiFi reporting task to output these stats for all connections to a dedicated logs (see&amp;nbsp;&lt;A href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-standard-nar/1.27.0/org.apache.nifi.controller.ControllerStatusReportingTask/additionalDetails.html" target="_blank" rel="noopener"&gt;Additional Details...&lt;/A&gt;&amp;nbsp;for how to setup dedicated logs via NiFi's logback.xml).&amp;nbsp; &amp;nbsp;You can then create a NiFi dataflow that tails the dedicated connection log and parses the ingested log entries for connections where thresholds exceed your 80% threshold and route those to a putEmail processor for yoru notification needs.&lt;BR /&gt;&lt;BR /&gt;(preferred) Another option here is to use the&amp;nbsp;&lt;A class="component-link" href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-site-to-site-reporting-nar/1.27.0/org.apache.nifi.reporting.SiteToSiteStatusReportingTask/index.html" target="component-usage"&gt;SiteToSiteStatusReportingTask&lt;/A&gt;&amp;nbsp;to report specifically on NiFi connections and feed that data in to a dataflow that parses for threshold in excess of 80% and route those to a putEmail processor.&amp;nbsp; This method has less overhead as it does not write to a NiFi log, require tailing logs, can be setup to report on connections, and reports in a more structured format (see&amp;nbsp;&lt;A href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-site-to-site-reporting-nar/1.27.0/org.apache.nifi.reporting.SiteToSiteStatusReportingTask/additionalDetails.html" target="_blank" rel="noopener"&gt;Additional Details...&lt;/A&gt;&amp;nbsp;).&lt;BR /&gt;&lt;BR /&gt;----------&lt;BR /&gt;From your image I can also see your PublishKafka processor reporting 3 actively running threads.&amp;nbsp; You mentioned the processor becomes hung?&amp;nbsp; Have you analyzed a series of thread dumps to identify where it is getting hung?&amp;nbsp;&amp;nbsp;&lt;BR /&gt;NiFi also offers a way to monitor for long running tasks:&lt;BR /&gt;&lt;A href="https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#runtime_monitoring_properties" target="_self"&gt;Runtime Monitoring Properties&lt;/A&gt;&lt;/P&gt;&lt;P&gt;You could use this in conjunction with the&amp;nbsp;&lt;A class="component-link" href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi/nifi-site-to-site-reporting-nar/1.27.0/org.apache.nifi.reporting.SiteToSiteBulletinReportingTask/index.html" target="component-usage"&gt;SiteToSiteBulletinReportingTask&lt;/A&gt;&amp;nbsp;to construct a dataflow that could send an email alert when task are detected on processor that have been running in excess of the configured threshold.&amp;nbsp; This runtime monitoring does have an impact on your overall NiFi performance due to the overhead needed to run it.&amp;nbsp; So if you find it impacts your throughput performance negatively, you'll need to stop using it.&lt;/P&gt;&lt;P&gt;__________&lt;/P&gt;&lt;P&gt;Please help our community thrive. 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;</description>
      <pubDate>Thu, 05 Sep 2024 14:45:10 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Monitoring-nifi-queue-and-trigger-an-email-when-queue-is-80/m-p/393104#M248340</guid>
      <dc:creator>MattWho</dc:creator>
      <dc:date>2024-09-05T14:45:10Z</dc:date>
    </item>
  </channel>
</rss>

