Hello,
I'm trying to receive location updates on background mode but it only lasts about 10 minutes then it stops when API detected the "isStationary" is true.
Is there any way to continue receiving updates even when the device is stationary?
Btw app is not terminated by the user.
I'm using CLLocationUpdate.liveUpdates(.otherNavigation) API. CLBackgroundActivitySession is created before calling the liveUpdates.
CLLocationManager:
let manager: CLLocationManager = {
let manager = CLLocationManager()
manager.distanceFilter = kCLDistanceFilterNone
manager.desiredAccuracy = kCLLocationAccuracyThreeKilometers
manager.pausesLocationUpdatesAutomatically = false
manager.activityType = .other
manager.showsBackgroundLocationIndicator = true
manager.allowsBackgroundLocationUpdates = true
return manager
}()
Thank you!
Using location updates in order to perform arbitrary functions like trying to keep a web socket active is not a valid use case.
As explained in App Review Guidelines
2.5.4 Multitasking apps may only use background services for their intended purposes: VoIP, audio playback, location, task completion, local notifications, etc.
Argun Tekant / DTS Engineer / Core Technologies