Reputation: 1781
I am running an app in the background with significant location change and monitor regions, the app works well but if the user don't use the app for a couple of days then the app gets terminated. Is there a way to prevent the app from being terminated ? like maybe triggering an alert to remind the user to open the app every 2 days ? does anyone knows how to get the app to run continually, and not to be terminated/suspended ?
Upvotes: 0
Views: 525
Reputation: 3324
I think it is not possible for an app to run continuously, and not to be terminated/suspended. You can use push notification to remind user to open app in every two days.
Upvotes: 1
Reputation: 43330
"significant location changes" over 4 days means your app is not only draining the battery (a no-no since iOS 4.x), but it is taking resources away from the system in the background. Apps cannot process forever in the background, so the OS makes the choice to kill it. Just turn off background processing and only update the user's location when they open the app. And do you want to know the best part: It's all fairly random! The OS could have killed Mail or YouTube or some such other app to make room for yours, but it didn't, it killed your app. There is no documented way around it, sorry.
Upvotes: 3