[ 
https://issues.apache.org/jira/browse/NIFI-9410?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17448461#comment-17448461
 ] 

ASF subversion and git services commented on NIFI-9410:
-------------------------------------------------------

Commit 2dcff09f7f97539fdf1ffd9e7b3fe75670a5adf2 in nifi's branch 
refs/heads/main from Peter Gyori
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=2dcff09 ]

NIFI-9410: Fix for ConsumeMQTT processor in stateless environment

NIFI-9410: Added displayName to the QoS processor property

This closes #5549.

Signed-off-by: Peter Turcsanyi <[email protected]>


> ConsumeMQTT does not work in stateless flows
> --------------------------------------------
>
>                 Key: NIFI-9410
>                 URL: https://issues.apache.org/jira/browse/NIFI-9410
>             Project: Apache NiFi
>          Issue Type: Bug
>          Components: Extensions
>            Reporter: Peter Gyori
>            Assignee: Peter Gyori
>            Priority: Major
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> When ConsumeMQTT is executed in stateless environment, the 
> {{transferQueue()}} method gets into an endless loop ({{{}while 
> (!mqttQueue.isEmpty()){}}}). At the end of each iteration of this loop
> {code:java}
> session.commitAsync(() -> mqttQueue.remove(mqttMessage));{code}
> is supposed to remove the message from the queue. but since the commit is 
> async, the method is already processing the same message in the next 
> iteration by the time it would execute. The session cannot commit so it does 
> a rollback, and the message is never removed from the queue.
> The endless loop consumes all resources and NiFi needs to be restarted to 
> break the loop.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to