-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Problem of sending outgoingStore data even though CONNACK sessionPresent is false #1651
Comments
I'm not sure about this. If you consider a client with a clean session that is sending lot of messages and then suddenly the connection goes down and needs to reconnect, If there were messages QoS > 1 in outgoing store I expect them to be sent on reconnection |
Sorry for the late reply. The following definitions have been added in V5.0. [MQTT V5.0] 3.2.2.1.1 Session Present
|
@ogis-yamazaki Go for a PR and I will give it a check |
I think the Store needs to implement a https://github.com/mqttjs/MQTT.js/blob/main/src/lib/store.ts In that case, the compatibility of the following libraries written in the README will be lost
Is there another good solution? For now, I will create a PR with |
We could in the meanwhile use createStream and then del functions in packages that doesn't have its support. Could you do that in a PR? |
This is an automated message to let you know that this issue has If this issue is still important, you can simply comment with a Thank you for your contribution. |
If SessionState is not present, the broker returns false to sessionPresent in CONNACK.
In this case, I don't think the client should send an in-flight message (PUBLISH, PUBREL)
Since the session is gone, retransmissions of messages that occurred in the old session should not be sent.
I think we need to distinguish between the following two. I think it is the first one that should be deleted.
It would be nice to have a
clear
function in the Store.(remarks)
The MQTT V5.0 specification has the following description.
OASIS : Session Expiry Interval https://docs.oasis-open.org/mqtt/mqtt/v5.0/os/mqtt-v5.0-os.html#_Toc3901048
The text was updated successfully, but these errors were encountered: