10 Golden Rules of Cocoon Caching

2,167 views

Published on

10 rules to get your caching in Apache Cocoon right.

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
2,167
On SlideShare
0
From Embeds
0
Number of Embeds
39
Actions
Shares
0
Downloads
18
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

10 Golden Rules of Cocoon Caching

  1. 1. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Hippo's 10 Golden Rules of Cocoon Caching Ard Schrijvers Bart van der Schans Niels van Kampenhout Hippo www.hippocms.org hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  2. 2. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Hippo's 10 Golden Rules of Cocoon Caching Many questions on user list ● You know <map:pipeline type=quot;caching''> ● But it's not that simple ● Best practices ● http://flickr.com/photos/st3f4n/143623934/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  3. 3. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Design For Performance Do it from the start ● Later is too late! ● Don't delay it ● http://flickr.com/photos/jacksim/16499469/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  4. 4. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Monitor Performance From The Start Check after each change ● See mistakes early ● Use real life data sets ● http://flickr.com/photos/redmann/178322027/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  5. 5. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Cache As Much As Possible But nothing more! ● Don't pollute cache ● http://flickr.com/photos/eleda/104669470/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  6. 6. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Cache As Long As Possible But not too long! ● Do not let your cache grow forever ● http://flickr.com/photos/wester/55116385/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  7. 7. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Design Your Pipelines For Caching Group pipelines by cacheability ● Avoid trigger effect ● Do non-cacheable stuff last ● http://flickr.com/photos/toni-travels/168819883/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  8. 8. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Choose The Right Type Of Caching Caching ● Expires Caching ● Event Caching ● http://flickr.com/photos/lonelyradio/83752690/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  9. 9. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Control Your Cache Keys Think about uniqueness ● Avoid duplicate cache entries ● Check Cocoon status page ● Do not use “use-request-params”! ● http://flickr.com/photos/aeroworks/90124673/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  10. 10. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Know What To Cache Where Reduce load on Cocoon ● From browser to proxy to ● Cocoon Closer to client is faster ● Cache by content type ● http://flickr.com/photos/tarantulastar/35842372/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  11. 11. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Make HTTP Headers Work For You Modified headers ● Expires headers ● Pragma and ● Cache-Control Click, F5, Ctrl+F5 ● http://flickr.com/photos/gregor_y/38130652/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  12. 12. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Do Not Trust The Outside World Proxies are out there ● Don't use browser selector ● Educate users ● http://flickr.com/photos/ianbline/96643546/ hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006
  13. 13. HIPPO OPEN SOURCE CONTENT MANAGEMENT SOFTWARE Hippo's 10 Golden Rules of Cocoon Caching Design For Performance ● Monitor Performance From The Start ● Cache As Much As Possible ● Cache As Long As Possible ● Design Your Pipelines For Caching ● Choose The Right Type Of Caching ● Control Your Cache Keys ● Know What To Cache Where ● Make HTTP Headers Work For You ● Do Not Trust The Outside World ● hippo open source content management software - www.hippocms.org Cocoon GetTogether 2006

×