Skip to content
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

In mqttc v5, restore session only if session is resumed #863

Closed
xiaocq2001 opened this issue May 11, 2024 · 1 comment
Closed

In mqttc v5, restore session only if session is resumed #863

xiaocq2001 opened this issue May 11, 2024 · 1 comment
Assignees

Comments

@xiaocq2001
Copy link
Contributor

Current Behavior

Currently rumqttc for MQTTv5 always republish packets which aren't acked, no matter it's clean session or resume session.

Expected Behavior

For simple we can use the session_present in CONNACK returned by broker, if it's 1 the session is resumed, if it's 0 the session is new and the pending requests should be discarded.

@xiaocq2001 xiaocq2001 changed the title In v5, restore session only if session is resumed In mqttc v5, restore session only if session is resumed May 14, 2024
@de-sh
Copy link
Member

de-sh commented May 14, 2024

@swanandx does broker by default set this correctly?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants