eclipse-paho / eclipse-paho/paho.mqtt.java
Paho leaves messages in unacked state when starting up
- Dominant language
- Java
- Stars
- 2.3k
- Forks
- 919
- PR merge metrics
- No merged PRs in 30d
Description
- [ x ] Bug exists Release Version 1.2.0 ( Master Branch)
When the application that uses paho library is starting up, it has successfully connected to the broker, but has not got a chance to subscribe any topics yet. The broker (RabbitMQ MQTT) will send the retained messages to this client, and paho simply ignores these messages causing the messages to stay in unacked state in the broker and the client is unable to process these messages.
This is the condition when a given message arrives
```
if (mqttCallback != null || callbacks.size() > 0) {
....
}
```
Anyone has any suggestions how to handle this?
Thanks
Thinh
Contributor guide
Assessment
This issue has not been assessed yet.