Common library + common CDN = how likely is it that the library is already cached?

50 views Asked by At

Often one hears that if one uses a common CDN like Google for common libraries like jQuery, that this might eliminate the need for the user to download the library. The idea is that by using Google to host your file, you're raising the chances the user already has it cached from some other websites. How often does that happen in practice? Any studies?

EDIT: a 2010 analysis says no! It's relatively rare for Google's CDN to save the user time. The downside of a CDN includes an extra DNS lookup and an extra TCP connection, and this isn't outweighed by Google's relative efficiency or the likelihood that other websites will have used the same library that you do. http://zoompf.com/blog/2010/01/should-you-use-javascript-library-cdns

Any more recent numbers?

0

There are 0 answers