eclipse-paho / eclipse-paho/paho.mqtt.java

Broken connection during connect treated as rejected connection by client

Open
#602 1 comment 0 reactions 0 assignees View on GitHub
question
Dominant language
Java
Stars
2.3k
Forks
919
PR merge metrics
No merged PRs in 30d

Description

If a Paho client connects, then a client with the same clientid connects from a different location immediately afterwards (before the CONNACK has been sent from the server), the new client will take over the original client's state, and the original client will be disconnected. The original client seems to be treating this early disconnection as a rejection of the original connection attempt, so if the default properties are being used a 3.1.1 client will then try to step down and send a 3.1 connect instead - this 3.1 connect packet will then take over the existing client (that was the second one to connect) with a 3.1 connection.

Please fill out the form below before submitting, thank you!

- [ ] Bug exists Release Version 1.2.0 ( Master Branch)
- [ ] Bug exists in MQTTv3 Client on Snapshot Version 1.2.1-SNAPSHOT (Develop Branch)
- [ ] Bug exists in MQTTv5 Client on Snapshot Version 1.2.1-SNAPSHOT (Develop Branch)

If this is a bug regarding the Android Service, please raise the bug here instead: https://github.com/eclipse/paho.mqtt.android/issues/new

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.