user6505882 user6505882 - 2 months ago 6
Android Question

Doze mode sleeps Google's Geofence sample application

I have an android application that uses Geofence and I'm having a hard time overcoming Doze mode. My manifest has the WAKE_LOCK permission and seven setNotificationResponsiveness to 0 for each region. I even changed PendingIntent to BroadcastReceiver but the app literally sleeps or is dead after a while with the deleted smartphone screen. I've already tried using LocationRequest

LocationRequest.setFastestInterval(1000);
LocationRequest.setInterval(2000);


Even so, I did not succeed. Has anyone managed to keep the application running with the Doze?

Answer Source

I ended up putting my application to receive push messages. Apparently the app is no longer being killed by the operating system.