The complicated life of a backgrounded iOS app
summary
Background transfer uses URLSession background configuration handed to a daemon so files download outside the app process, which requires moving off completion handlers to delegate callbacks, persisting session identifiers and the completion handler, and batching work to avoid the exponential backoff of the resume rate limiter. Silent push gives ~30 second work windows but can be throttled or turned off. Custom auth callbacks break background auth so prefer short-lived server tokens instead of certificate pinning. Debug with Console and nsurlsessiond logs plus DSD traces; watch APNs device‑token environment mismatches.
AI-written summary · about
chapters (17)
- 0:00Intro
- 3:43App states
- 5:02URL Session API
- 7:11Surprises
- 8:59isDiscretionary
- 11:20Silent push
- 13:41What counts?
- 14:42Client trust validation
- 16:09Certificate pinning A
- 18:20Authentication challenges A
- 18:57Custom authentication scheme
- 20:39nsurlsessiond
- 22:29No custom authentication challenge
- 24:24How to make the rate limiter happy?
- 29:44Console app
- 35:33Why Must Not Proceed?
- 36:49Tips for implementing background transfer
related talks
51mQ&A Session
33mFirebase iOS Deep Dive
45mUncovering breaking changes behind UI on mobile applications
02h 42mSwift Structured Concurrency
37miOS Parallel Automation: Run Faster Than Fast
36mTesting: how hard can it be?
34mIt worked on my iPhone 15 Pro Max…
50mAn Exploration of Debugging Techniques and Tools
