Background download tasks intermittently stalling for 4 minutes
Background download tasks intermittently stalling for 4 minutes
- Subject: Background download tasks intermittently stalling for 4 minutes
- From: Scott Hancher <email@hidden>
- Date: Fri, 11 Jul 2014 16:44:14 -0700
On iOS, I'm running into an issue where background downloads stall for 4 minutes intermittently.
Depending on the test case, I'm downloading as few as 5 and as many as hundreds at the same time. I'm creating individual NSURLSessions for each configured with an NSURLSessionConfiguration created through [NSURLSessionConfiguration backgroundSessionConfiguration:...]. I'm creating the download tasks via [session downloadTaskWithRequest:request] and calling resume on it.
According to Charles Proxy, even though I'm resuming all these tasks at basically the same time, only 3 seem to be in flight at any one time. Roughly 25% of the time, the downloads just pause; none of my callback methods get called. When this does happen, 4 minutes later (within a second), the downloads resume without issue. The Charles Proxy clearly shows this 4 minute pause for the paused downloads.
Since Charles is showing the downloads starting before the pause, I was assuming this was a server issue, but when I use a configuration created through [NSURLSessionConfiguration ephemeralSessionConfiguration], I can't seem to repro the pause. Also, 8 to 10 downloads appear to be in flight at any one time in this scenario.
Any clues as to what might be happening? Does it sound like a system issue? Any thoughts would be appreciated.
++Scott.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden