You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have experienced an issue where my app delivers a message twice when the app has a disconnection/reconnection, even if I set the message QOS to 2.
I want to send a message every second and deliver all the messages even if the phone is disconnected for a while.
If I set cleanSession to True, it looks like the app cleans the queue and loses some messages.
If I set cleanSession to False, I got the issue.
I found that recoverSessionBy enqueues stored messages and can duplicate messages.
I think it should check if the mqueue already holds the same message when a stored message is appended.
Hello,
I have experienced an issue where my app delivers a message twice when the app has a disconnection/reconnection, even if I set the message QOS to 2.
I want to send a message every second and deliver all the messages even if the phone is disconnected for a while.
If I set
cleanSession
to True, it looks like the app cleans the queue and loses some messages.If I set
cleanSession
to False, I got the issue.I found that
recoverSessionBy
enqueues stored messages and can duplicate messages.I think it should check if the
mqueue
already holds the same message when a stored message is appended.CocoaMQTT/Source/CocoaMQTTDeliver.swift
Lines 78 to 94 in ff7c07b
The way to reproduce the issue
cleanSession
= falseBehavior
Expected
Thank you!
The text was updated successfully, but these errors were encountered: