Answer the question
In order to leave comments, you need to log in
Why does file download speed drop (objective-c)?
I am uploading files in the background thread, I will immediately make a reservation that the Internet is good. Files are loading very slowly. In the debugger, the load on the network does not exceed 100 kbps. pastebin.com/0pe2Yu3d
Answer the question
In order to leave comments, you need to log in
I would be the person who, in the examples for demonstrating file uploads, initially used the dataWithContentsOfURL method: he broke off his hands. And all this has been dragging on for more than a year. What is not an example of how to upload files from the network is dataWithContentsOfURL. This is not what this method is for. It's written right in the comments.
Do not use this synchronous method to request network-based URLs. For network-based URLs, this method can block the current thread for tens of seconds on a slow network, resulting in a poor user experience, and in iOS, may cause your app to be terminated.
Instead, for non-file URLs, consider using the dataTaskWithURL:completionHandler: method of the NSSession class. See URL Loading System Programming Guide for details.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question