16

At what point is it worth adding a CDN (content delivery network) to your website? Does it make sense to use it for a relatively low traffic website that's a web application? The clients are all over the USA.

Will a CDN even offer a noticeable difference to the end user for my scenario or does it only show effectiveness once you truly have hit scalability levels?

Edit: Information about server setup, currently it's a single ASP.NET instance on a shared hosting environment. What would go into the CDN would be some image files, jquery related files (I know google provides a CDN for the core), css files, and probably some moderate size PDF files.

KPWINC
  • 11,274
  • 3
  • 36
  • 44
Chris Marisic
  • 1,404
  • 8
  • 33
  • 51

6 Answers6

22

At what point is it worth adding a CDN (content delivery network) to your website?

When one of the following occurs:

  1. You're reaching a large, international audience. Careful analysis of your audience shows that many of them are 100 - 300ms Round Trip Time (RTT) away. You do the math, and discover that a large group of you customers are getting a somewhat slow site, due to TCP/IP's so-so performance on links with high bandwidth delay product.
  2. You find that you have a lots of requests for mostly static files, i.e. streaming video, audio, PDFs, images etc. In fact, there are so many requests per second that it can't easily be handled by just setting up 2, 3, 4 or more servers dedicated to static file serving.
  3. You're a tech geek, and you set up a site using Amazon Cloudfront or Cachefly just for the fun of it. Don't feel bad, I have done it too.

I have repeatedly seen articles where SimpleCDN didn't do so great. It is really hard to objectively quantify the performance of the various CDNs, but here is one attempt. Maybe I'm being unfair to SimpleCDN here, but they wouldn't be my first choice.

Amazon Cloudfront is pretty consistenly good ... not great, but cheap and easy to get started with.

Edit: Akamai still seems to be the very best CDN, expensive but so worth it. See SmugMugs recent presentation, slide 7 in the PDF or the more detailed version in the video. I have never worked with Akamai, I have always dismissed them as obviously too expensive for the sites I have worked on. Maybe that is beginning to change, I don't know, but they are trying to lower the barrier to entry to their CDN service.

Brian
  • 303
  • 1
  • 3
  • 15
2

It depends on the application. If you're highly latency sensitive (an interactive application) then you want the fastest page loads possible. If you're a streaming app (like YouTube for example), then latency is less of an issue.

For latency sensitive applications, CDN is generally a build vs buy decisions.

If you have lots of international users, you can either build out racks near your users (most likely expensive to do) or you can pay a CDN to cache your content for you locally.

CDN pricing has gotten a lot more competitive in the last few years. Shop around, see what's out there. And if you can build and maintain several racks of caches distributed around the world for cheaper, then you don't need a CDN.

Joel K
  • 5,765
  • 2
  • 29
  • 34
  • They're all USA so international isn't a factor. It is a moderately interactive web application. SimpleCDN does seem abusrdly cheap at a few cents per GB I couldn't even imagine spend more than a few bucks a month on having the CDN at those rates. – Chris Marisic Sep 08 '09 at 17:52
  • I'll add to this one, that most shared servers take a lot of time to respond, even for just static content. Having those hosted on a cdn will bring the page load down in seconds sometimes. Like jeff says - performance is a feature. – reconbot Sep 08 '09 at 18:38
  • @Joel K: A good post, thank you, but I do not agree on the 'build a CDN yourself' part. Getting something like IP multicasting or geo load balacing to work really well, including all the corner cases and more or less broken client systems, is **hard**. See my post for another take on OPs question. –  Sep 08 '09 at 20:15
2

Obviously a CDN is worth it as soon as it's more economical than doing it yourself.

But there's one case where it's absolutely indispensable: when you can expect to have very strong bursts of traffic. Typically, when a company is launching a new product with heavy media promotion, or doing some sort of viral thingie without using existing social platforms.

Additionally, when you have to reach an international audience, you may want to have servers closer to your users. Your site will be snappier, and you could want to spend more just for that.

niXar
  • 2,023
  • 17
  • 23
  • Yes, good point, if your traffic patterns are very irregular, i.e. you have load spikes many times larger than normal load, then a CDN will at least remove the static file serving from your list of worries. –  Sep 08 '09 at 19:56
2

If your service generates large loads (not just peaks) above and beyond what your infrastructure can safely handle, then it might be worth calling in a CDN. Add in the requirement for fast round-trip times, resilience, and scaling, and you should hopefully have the revenue to pay for one.

In your case, you're just looking to grab some optimisations where you can. You might consider using Google App Engine as a mini-CDN for your static files - check this out:

Using Google App Engine as a personal CDN

0

Will a CDN even offer a noticeable difference to the end user for my scenario

The downloads may be faster than your server. You don't elaborate on your server setup, but it could be faster than a shared hosting machine.

It's easy to set up an amazon or simple cdn account to test this sort of thing out.

Sam
  • 1,990
  • 1
  • 14
  • 21
  • I did grab a free simple cdn account I saw them talked about another CDN post, at some point I'll have to play around with it. But did my server information give you any better ideas or is it still just as generic? – Chris Marisic Sep 08 '09 at 17:01
-1

Les here, saying

‘when you got a whole lot of money to spend, because the perhaps-nominal reduction of  
latency in delivering your content and assurance of your content’s availability is 
making you FAT RICH!!!’

in response to your question: when does a CDN become worth it. Having a hard time justifying the cost of even the lesser-ranked CDN services to the business people? You might wish to evaluate and price out a cloud-based CDN system, the likes of what you can home-brew cook up yourself with components from Amazon’s AWS cloud services. Geographically-close-to-the-end-requestor distribution-of-content, at a fraction-of-the-top-tier cost, compared to the big 3 CDNs.

Or call me Les Thanone. Just don’t call me human.

Les.