James Sutton
James Sutton
I'm not 100% sure what you're question is, but if you're asking what the purpose of connectionLost is.. You can use connectionLost to notify your main application / user that...
Assuming that you have enabled the automatic reconnect functionality in the MqttConnectOptions: ``` MqttConnectOptions mqttConnectOptions = new MqttConnectOptions(); mqttConnectOptions.setAutomaticReconnect(true); ``` Then you don't have to do anything, the client will...
This is interesting, I've got a barebones application that I use to test things like this (It's the paho.mqtt.android.example app in the repository). I just started it up and it...
Ok, here is some more info on this as I was having trouble recreating this: I tried this on my Nexus 5 whilst tethered to look at the logs and...
When forced into idle mode, this is the current behaviour: ``` 07-25 14:13:37.769 5798-5898/paho.mqtt.java.example D/AlarmPingSender: Register alarmreceiver to MqttServiceMqttService.pingSender.ExampleAndroidClient1469452417189 07-25 14:13:37.770 5798-5898/paho.mqtt.java.example D/AlarmPingSender: Schedule next alarm at 1469452477770 07-25 14:13:37.770...
Thanks, I've found this article that gives more background on the changes: https://developer.android.com/preview/behavior-changes.html?utm_campaign=android_launch_developerpreview5_071816&utm_source=anddev&utm_medium=blog#perm From this article, it looks like we might be an acceptable use case for being added to...
Furthermore, using setExactAndAllowWhilstIdle will only allow the alarm to be called once every 9 minutes. So the Alarm will trigger once and then the connection will likely fail. https://plus.google.com/+JamesSutton42/posts/GQFy9QZEUqb The...
It's looking more and more like there isn't much of a way around Doze. Here is what I've been able to gather: - Doze is activated when the device is...
@binarybucks Good idea, I'll have a play and see if this can be added to the automatic reconnect behaviour. It might already just work as I believe that any deferred...
Hi, I don't really understand what you're asking for? Could you explain what you want to achieve please?