If you found this post it’s likely you’re interested in finding a cheap (most likely free) CDN. There are numerous posts on the net about using Googles’ App Engine as a free CDN. It’s important to understand what a true CDN is. Definition of a CDN from Wikipedia:
A content delivery network or content distribution network (CDN) is a system of computers containing copies of data, placed at various points in a network so as to maximize bandwidth for access to the data from clients throughout the network. A client accesses a copy of the data near to the client, as opposed to all clients accessing the same central server, so as to avoid bottleneck near that server.
Content types include web objects, downloadable objects (media files, software, documents), applications, real time media streams, and other components of internet delivery (DNS, routes, and database queries).
App Engine does spread files to different geographically located servers however, Google doesn’t provide any information about their content delivery network. Just Ping has a tool that ping/resolve domain names at 41 different locations in the world. Looking at this URL my App Engine domain resolves to 12 different IP addresses over the world! In this sense Google App Engine is a real content delivery network, but that is not the primary focus of the service.
Google App Engine network performance
Before jumping in head over heels, investigate if Google App Engine will actually deliver better performance than your current provider. Depending on the quality of your hosting partner using Google App Engine could potentially make your site slower. I did some tests using Test Your Host, which is actually a CDN provider that has a service that will test download speeds from different locations in the world. Locations included in the test: Dallas, Los Angeles, Phoenix, San Jose, Tustin, Atlanta, Chicago, Miami, NewYork, Reston, Amsterdam, Barcelona, Frankfurt, London, Marseille, Milan, Stockholm, Hong Kong, Seoul, Taipei, Tokyo and Sydney.
I tested performance with a zip-file weighing just below 1Mb. I placed the zip on this blog which is hosted by EPiServer Hosting, a professional Swedish hosting company, and my Google App Engine account. Here are the results:
The results are an average download time based on three downloads for each source over three days.
|Location||Avg. time EPiServer||Avg. time App Engine||Avg. time Test Your Host (CDN)|
|United States West Coast||2.264 s||0.989 s||0.43 s|
|United States East Coast||2.13 s||0.396 s||0.566 s|
|Europe||1.330 s||1.357 s||0.725 s|
|Asia||21.096 s||10.760 s||7.523 s|
|Australia||8.774 s||4.791 s||5.559 s|
Google App Engine beats my hosting provider everywhere except Europe which is where my blog is located (it’s located in Stockholm to be specific) and even then the difference isn’t huge. My analytics account tells me that over the course of one year most of my visitors (32%) come from the US. Using Google App Engine I could cut the time taken to load my blog in half for most of my visitors if I moved my content there. Not bad for being a “free” service! The “real” CDN provides better numbers in three out of five locations.
Use Google App Engine to deliver your content
Just a while ago I posted the result of quite extensive work I’ve done investigating the so far undocumented Google App Engine API. In that post you find details on how you can put your files on App Engine without using Google App Launcher. During my work I’ve managed to debunk some misinformation floating around various blogs. The current file limit is NOT 1mb, it’s actually ~10Mb. You CAN also configure the cache control header values and App Engine DOES support ETags.
If you have a custom application or want full control, take a look at my post about using the App Engine API. You can write your own custom solutions with it.
CirruxCache is an App Engine application written by Samuel Alba that is used in production for his company site. It’s a simple to use application that will pull files from your server and store in App Engine. No custom code needed on your site! This post describes how you can set up CirruxCache and use it for your WordPress blog. I haven’t tested it but it sure looks promising and easy to do.