Wednesday 9 November 2011

How does Origin Pull work

Origin Pull is the method of transferring data to the CDN automatically from a webserver as opposed to manually uploading the content. This method of uploading data to the CDN can be used for HTTP, on demand Flash and on demand Windows Media content. Once the initial configuration is completed, the content will become available to the CDN by simply requesting the CDN URL associated with that content.


For example, CNAME “httplinux.helplines.com” is associated with the origin “http://linuxorigin.helplines.com/cdn_content”. When a request is made for “http://httplinux.helplines.com/images/example.jpg”, the CDN will check its own cache for the file. If the file does not exist or the cache has expired on the file, it will request it directly from “http://linuxorigin.helplines.com/cdn_content/images/example.jpg” and will then cache the file based on your webservers cache control configuration.

With Origin Pull, the CDN determines if content will need to be pulled from your server via the “Cache-Control” headers configured on your webserver. The CDN will honor most standard Cache-Control options such as max-age, proxy-revalidate, must-revalidate.

Please note that the use of the ”private” and “no-cache” option in the Cache-Control headers will result in the CDN pulling a new version of the content for each request it receives as the headers will instruct it not to cache that content.

We recommend not setting your max-age to less than 5 to 10 minutes as this will put excessive load on your webserver and result in less optimal performance. Be aware that if content on the webserver has been updated, each POP will continue to serve the old cached version until that cache is purged or the cache on the POP expires. If no max-age header is set, the default max-age of 24 hours will be used.

1 comment:

  1. Nice post! I found recently a very cheap CDN: www.keycdn.com

    ReplyDelete