App standby bucket does not acknowledge user interaction

232 views Asked by At

I have a VOIP application which uses HIGH priority push notifications each time a call is performed. The push notification is message notification since I want to handle interaction myself. When I receive push I start a foreground service which starts listening to SIP communications which then opens up a custom call screen (activity) to which user interacts. For android P I have ACTION_MANAGE_OVERLAY_PERMISSION so that I can always open the call screen even from a service.

What I believe happens is that standby bucket does not detect user interaction with this flow since my high priority messages get throttled. From FCM diagnostics I can see that push notification comes to the phone but is then not broadcasted to the app itself.

I am also able to replicate this without a problem when putting phone in this state:

./adb shell dumpsys battery unplug                           
./adb shell am set-inactive package.name.com true
./adb shell dumpsys deviceidle force-idle 

How can I make sure that the opened activity counts as user interaction or if this is not possible how to change the flow so that it would work but still open custom call screen activity?

0

There are 0 answers