These are chat archives for Trinea/android-open-project

14th
Sep 2017
Chintan Mishra
@ChintanMishra_twitter
Sep 14 2017 01:03

Yes I generally use services with a thread for long living tasks. But in Android O as doze is going main stream with killing service we would be having hard time maintaining our app's features which largely rely on persistent TCP connection. Also, in my experience FCM drops some messages which is poor UX in our scenario. Using MQTT in our case allows us to maintain Quality of Service which ensures messages reach once and the client acknowledges after receiving.

My issue has been asked eclipse/paho.mqtt.android#226 and eclipse/paho.mqtt.android#195 but there is no sound solution available.

Nirmal Sarswat
@vivonk
Sep 14 2017 14:27
I did not used server pings but many of my friends worked on it, where your server tells to your device that you have to do something. Firebase is also do same work but it consume some data and make a great load. I think making a sticky service which will not take so much load on device is perfect. In such scenario, service get killed but Android O also have feature of Priority where it checks that if your service is not taking more space or data consumption then it will continue on device.
Finally I think what is need is Firebase
Chintan Mishra
@ChintanMishra_twitter
Sep 14 2017 15:14

How to solve FCM dropping the messages?

Every 120min we are supposed to get 60 values. With FCM index increments are between 55-60 however with MQTT this is 58-60