3 ms·
AFNetworking boasts really fast performance in the way that it makes concurrent requests and processes them asynchronously. That, in combination with careful tu
by matttthompson 15y ago
AFNetworking boasts really fast performance in the way that it makes concurrent requests and processes them asynchronously. That, in combination with careful tuning of the stock networking libraries makes.
There are no hard performance benchmarks, but you'll get a good sense of how fast it is if you download and run the example app--I've yet to see any apps match the table view image loading performance.
FWIW, people who have switched from ASI usually report an overall networking speedup of 2-3x.
- psychotik 15y ago"careful tuning of the stock networking libraries" <-- Care to expand? I am skeptical about claims that simply changing how it makes concurrent requests will make it 'insanely fast'. Bottom line is, outside of some careful tuning that uses knowledge of iOS internals, there isn't any real way a library can impact how fast bits travel over the wire. Here's some feedback - if you wish to substantiate this claim, it shouldn't be hard to write the same app using ASI and then extract some real performance numbers (bonus points for publishing your test code to get doubters like me to shut up).
- matttthompson 15y agoWell, the most perceptible tuning AF does is turning on HTTP pipelining for image requests (which are off, by default). Other than that, it's just small steps to use HTTP correctly as much as possible. </admittedly vague cop-out> I understand and respect your skepticism, since by using NSURLConnection, its performance is bound by the same thing most other libraries are (although ASI was wrapped the lower-level CFNetwork APIs, FWIW). It's the stuff around the network activity--the way the application interacts with the data that makes AF fast. I've gone out of my way to design a minimal API that is performant no matter how you (mis)use it. But you're right: I'll have to get around to writing a benchmark app at some point :)