Re:Cloudflare’s CDNJS vs. Google Hosted Libraries
by afhof on Saturday March 23, 2013 @12:23AM
(#5427235)
Could you post the exact commands you used? That high connection time for google looks like SSL setup.
Re:Cloudflare’s CDNJS vs. Google Hosted Libraries
by DannyBee on Saturday March 23, 2013 @06:26PM
(#5430044)
Non concurrent:
ab -n 100 http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min...
ab -n 100 http://cdnjs.cloudflare.com/ajax/libs/jquery/1.9.1/jquery.mi...
Concurrent case:
ab -c 5 -n 100 http://cdnjs.cloudflare.com/ajax/libs/jquery/1.9.1/jquery.mi...
ab -c 5 -n 100 http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min...
(IE min is 496k/s, max is 895k/s, average is about 600k/s)
Using wget is a completely useless benchmark, from what I can tell. Using apache's little benchmark tool I get about 255ms vs 180ms average for 100 requests to each.
The interesting part is that for ajax.googleapis.com I get:
and for cloudflare I get: IE for google, all the time is in actually getting a connection and getting the bits, whereas, for cloudflare, there is actually some time waiting for their servers.Using 5 concurrent requests actually gives me a massive advantage for google (cloudflare takes roughly the same time, google goes 4 times faster)