Mobile data disconnected in Android after about 1 hour
<p>I have a issue. My application is running in the background (like a foreground service) on some android devices (Android versions from 5 to 6).
The application is connected to the server (TCP connection) and they are exchanging data at least every 45 seconds.</p>

<p>If the screen is turned off and the mobile is not used then it seems that android turn off the mobile data after 1 hour. Thereafter the application is not able to reconnect to the server. The devices are running on the battery power.
As soon as the screen is on then the mobile data is again on and the application reconnects to the server.</p>

<p>I have turned off power save options.</p>

<p>Can somebody give me some hint about what I can do in order to prevent turning off the mobile data when the phone is sleeping.
Thanks</p>