I have an app which monitors battery level but I'm concern how will work on upcoming Android O version with service limitations in the background. Any hints or ideas will help me a lot.
Thanks.
You can start a foreground service to monitor the battery or you can schedule a periodic job. Periodic jobs have a min period of 15 minutes.