I have been facing issue while using NSURLSession
many times and hence wanted to know does NSURLSession
internally uses CFSocket
?
Is there any reference document from Apple on this? If yes, references would be appreciated.
Asked
Active
Viewed 49 times
0
-
1See [Advances in Networking, Part 1](https://developer.apple.com/videos/play/wwdc2019/712/), which shows how to use sockets with `URLSession`. But I believe standard data, download or upload tasks are still built on top of `NSURLConnection`. – Rob Jun 22 '20 at 19:14
-
1I’m curious what sort of `URLSession` problems you’re having and how the internal implementation details are relevant... – Rob Jun 22 '20 at 19:15
-
@Rob - sometimes the request from NSURLSession does not reach the server even though valid TCP connection exits and hence wanted to know if CFSocket used. – sia Jun 23 '20 at 14:48
-
1I still don't see how knowing this helps you. Regardless, I think we can safely say that there's something else going on and that the problem is unlikely to rest with `CFSocket`. I might suggest tools like [Charles Proxy](https://charlesproxy.com) or [WireShark](https://wireshark.org) to watch the requests and responses. – Rob Jun 23 '20 at 19:58