I have an app in which I am tracking user location like Uber. It works fine in the foreground. But in the background it works only for few minutes. After that, it gets stop.
But it starts send location information when I open the app again.
It's been two days I was searching for a reason. Today I suddenly found this in the google docs
In an effort to reduce power consumption, Android 8.0 (API level 26) limits how frequently an app can retrieve the user's current location while the app is running in the background. Under these conditions, apps can receive location updates only a few times each hour.
It's mean that I can watch user location few times? How other apps are working like Uber