Daily iOS
App lifecycle and system

Background execution limits

You get a report that a save to the server never lands when the user taps save and goes straight out to the home screen. How would you fix it?

How would an interviewer hear this answer? You'll see whether they'd move on, dig in, or say no, and which sentences would trip you up. Your score doesn't change.
See the short answer

The app is suspended within a few seconds of entering the background and the request is cut off. Extend it to about 30 seconds with beginBackgroundTask, or hand the transfer to a background URLSession.

Share a question