I heard Background Services won't work that free on android Oreo. I'm kinda confused how I should rewrite my Code. I'm working with android for a month or so now, so please try to answer as simple as possible.
I have a Service that is called On Boot and in the onCreate() of my MainActivity.
In the service's onStartCommand it is calling a Handler.
This handler will postDelay() itself every half minute and call a function.
This function does some api requests and will push a notification when certain conditions were applied.
What is the best way to let this code work on android O+?
I thought about using a Foreground Service and display a useless ongoing notification, the user can make
invisible but that idea does not sound good.