dc297 / mqttclpro

MQTT Client for android with tasker support
MIT License
97 stars 30 forks source link

Disconnection/reconnection issues #85

Open blacklight opened 3 years ago

blacklight commented 3 years ago

I use MQTT Client mainly for the Tasker integration, and since day 1 it's been giving me headache with client disconnections.

After some time the connection to a broker (a Mosquito SSL instance in my case) simply terminates. I have noticed that it happens more frequently when switching from Wi-Fi to mobile data or when toggling VPNs, but it does occur sometimes even when the device is on the same network.

When it does, the client is unable to establish the connection again. It reports "Reconnecting to..." in the header of the broker panel, but it doesn't actually reconnect. The only way to get it to reconnect is by either disabling/enabling the broker, or force stop the app - and sometimes clear the cache.

I think that we agree that so much manual interaction isn't acceptable from an app that is supposed to be always active in the background and ready to deliver messages, especially when such events occur multiple times during a day.

Please let me know if I can help with debugging, otherwise I'll just fork it and try and fix the issue myself because an unstable MQTT client is really a no-go in my setup.

NewUser9 commented 3 years ago

I use MQTT Client mainly for the Tasker integration, and since day 1 it's been giving me headache with client disconnections.

After some time the connection to a broker (a Mosquito SSL instance in my case) simply terminates. I have noticed that it happens more frequently when switching from Wi-Fi to mobile data or when toggling VPNs, but it does occur sometimes even when the device is on the same network.

When it does, the client is unable to establish the connection again. It reports "Reconnecting to..." in the header of the broker panel, but it doesn't actually reconnect. The only way to get it to reconnect is by either disabling/enabling the broker, or force stop the app - and sometimes clear the cache.

I think that we agree that so much manual interaction isn't acceptable from an app that is supposed to be always active in the background and ready to deliver messages, especially when such events occur multiple times during a day.

Please let me know if I can help with debugging, otherwise I'll just fork it and try and fix the issue myself because an unstable MQTT client is really a no-go in my setup.

Please fix it yourself and publish the apk on github. I guess developer has abandoned the project.