Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
copy to CDN - or sync uploads/ to cdn
#4
now the CDN part.
i map cdn.sitename.com to amazon cloudfront distribution, then i use a modified version of this script http://cdn.ww.ossdl.de/syncer.sh to sync only the data/uploads/ folder, using the newest version of s3cmd (available only via cvs at the moment) http://s3tools.org/s3cmd so i have support to the -rr switch

finally i manually modify my pages to link images to cdn.sitename.com

so i think a plugin has to
-- configuration part
-) have huge note telling about the risk of working with cache, far future expires and the need of using versioning
-) ask for amazon/google storage for developers access keys
-) ask for upload bucket name and the distribution domain (cdn.sitename.com)

-- hooked to changedata-save (not sure)
-) sync the data/upload/ running the script
-) modify all xml pages to link to cdn.sitename.com

additionaly I also modify the template, compress and join js using closure compiler service http://closure-compiler.appspot.com/home then join all css and encode and include background images in the files using http://duris.ru/ , finally i manually GZIP the files keeping the same name, and upload to the cdn setting the content type to gzipped and a far future expire date. Of course each time i modify the css or the js i have to redo all of that, including modify the templates to do versioning.

low server load, faster pages, better user experience and a better yslow score too.
Reply


Messages In This Thread
copy to CDN - or sync uploads/ to cdn - by marrco - 2010-08-01, 02:26:00
copy to CDN - or sync uploads/ to cdn - by marrco - 2010-08-07, 20:03:22
copy to CDN - or sync uploads/ to cdn - by marrco - 2010-08-07, 20:38:53



Users browsing this thread: 1 Guest(s)