-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Bug: Inflight configuration is ignored. V2.0.16 #2876
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I haven't had time to investigate much yet, but i seem to at least hit a similar / related bug (maybe even this) having |
In my case configuration is:
Pseudo Code client:
First message is always ok. |
Yeah, I have max_queued_messages 0, as well, and I'm seeing alllll messages dropped until I remove that from my config. I can't even do a "mosquitto_sub -t "#" -d" test, it just hangs. Removing the max queued messages 0 config fixes things... |
But in this case the configuration max_queued_messages is not 0...
|
I can confirm messages are lost if the
If you change to If you are using an ancient version of mosquitto on the sending end of the bridge, you can get around the problem by lowering your QOS from 2 to 1 |
This is a really a problem I don’t know how to work around This script:
fails with a mosquitto 2.0.16 in default configuration (max_inflight_messages default to 20) Output
|
The net effect of this problem is loosing messages when using QoS 2! |
The problem caused because the "Receive Maximum" property is not set properly in the CONNACK message. This causes even MQTTv5 clients cannot react to the limitation and run into the "quota exceeded" error. In the CONNACK the "Receive Maximum" is still indicating the configured value rather than "1" src/send_connack.c:
|
The proposed fix solves the issue. |
Problem:
That is no supported for multiple publication where queueing message is necessary. For example, when I send multiples messages in quickly succession (QoS=2)
PS: I lost my messages... 😔
Conclusion
Inflight configuration is ignored.
Version:
2.0.16
Lines:
https://github.com/eclipse/mosquitto/blob/6113eac95a9df634fbc858be542c4a0456bfe7b9/src/context.c#L86-L89
Proposed Fix:
Use 2.0.15 code lines.
https://github.com/eclipse/mosquitto/blob/b0277869d9806f6fab8e1bc11c4a4987c9a79ded/src/context.c#L86-L89
The text was updated successfully, but these errors were encountered: