You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Tomohisa Igarashi (JIRA)" <ji...@apache.org> on 2015/08/26 13:27:45 UTC

[jira] [Comment Edited] (CAMEL-9092) MQTT consumer receives duplicate messages after broker restart

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

Tomohisa Igarashi edited comment on CAMEL-9092 at 8/26/15 11:26 AM:
--------------------------------------------------------------------

I haven't yet made completely clear why that duplicates happen though, the pull request I submitted did fix the issue. As Listener.onDisconnected() is also invoked when connection recovery happens in mqtt-client internally, -invoking disconnect() due to this event triggers unnecessary connection re-initialization- not really, just doing connected = false without disconnect(), so it's even worse as the old connection is remained open.
I also added setting tracer to MQTT when trace is enabled.


was (Author: igarashitm):
I haven't yet made completely clear why that duplicates happen though, the pull request I submitted did fix the issue. As Listener.onDisconnected() is also invoked when connection recovery happens in mqtt-client internally, invoking disconnect() due to this event triggers unnecessary connection re-initialization. I also added setting tracer to MQTT when trace is enabled.

> MQTT consumer receives duplicate messages after broker restart
> --------------------------------------------------------------
>
>                 Key: CAMEL-9092
>                 URL: https://issues.apache.org/jira/browse/CAMEL-9092
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-mqtt
>    Affects Versions: 2.15.2, 2.16.0
>            Reporter: Tomohisa Igarashi
>         Attachments: MQTTDuplicatesTest.java, MQTTDuplicatesTest.java_activemq
>
>
> if clientId is specified, after ActiveMQ broker restart, camel-mqtt consumer starts to receive duplicate messages. Please see the testcase attached.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)