iOS Question NSUrlSession in background

Semen Matusovskiy

Well-Known Member
Licensed User
Does someone has experience/alive sample with NSURLSession in background ?
I need to upload groups of files (approx. 100-200 Mb) and to receive a comfirmation from server. Each file has separate parameters in URL and I need to correct header also.

I used a service in In Android and sent file by file (this works even if app is not started). In IOS I did something similar by timer, but this does not work in background mode and sometimes there are troubles, because users like to close an app.
 
Some additional seconds in foreground are not very useful for upload. As I understood, it is recommended to use NSURLSession and to send whole packet at once. IOS will send files in background and will activate your app in Completition handler. Another question that l did not see good obhective-c samples.
 
Upvote 0
Back
Top