Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
CACHINGOldie but GoldieRaluca Breaur20th of April 2013
Cache
Sourceofdata
Advantages
“There are only two hard thingsin Computer Science:cache invalidationand naming things.”Phil Karlton
Eviction
Stale data strategyTime to liveTime to idle
Eviction algorithmsLFU – Least Frequently UsedLRU – Least Recently UsedFIFO…
Levels of cache
Loading
HITCACHESOURCEOFDATA
MISSCACHESOURCEOFDATA
Cache performance - StatisticsHitsMissesSizeAverage GetTimeEviction Count
Common Data PatternsLocality Hot Set DatachangesCatalog(Countries) Low Low LowInventory(Stocks) High High HighConversation...
Caches around usBrowser cacheUse cache control headers: max age, no cache
Database• Persistence Layer – JPA – 2 layers of cache
High computationService – Spring 3.1 Cache AbstractionJCache
Web Service / 3rd partyMultiple clients - Standalone Cache ServerService – Spring 3.1 Cache Abstraction/JCache
Cache Providers - JCACHEjava.util.Map GUAVA caches
Questions
Iasi codecamp 20 april 2013 Caching - oldie but goldie - Raluca Breaur
Iasi codecamp 20 april 2013 Caching - oldie but goldie - Raluca Breaur
Iasi codecamp 20 april 2013 Caching - oldie but goldie - Raluca Breaur
Iasi codecamp 20 april 2013 Caching - oldie but goldie - Raluca Breaur
Iasi codecamp 20 april 2013 Caching - oldie but goldie - Raluca Breaur
Iasi codecamp 20 april 2013 Caching - oldie but goldie - Raluca Breaur
Upcoming SlideShare
Loading in …5
×

Iasi codecamp 20 april 2013 Caching - oldie but goldie - Raluca Breaur

366 views

Published on

Published in: Technology
  • Be the first to comment

  • Be the first to like this

Iasi codecamp 20 april 2013 Caching - oldie but goldie - Raluca Breaur

  1. 1. CACHINGOldie but GoldieRaluca Breaur20th of April 2013
  2. 2. Cache
  3. 3. Sourceofdata
  4. 4. Advantages
  5. 5. “There are only two hard thingsin Computer Science:cache invalidationand naming things.”Phil Karlton
  6. 6. Eviction
  7. 7. Stale data strategyTime to liveTime to idle
  8. 8. Eviction algorithmsLFU – Least Frequently UsedLRU – Least Recently UsedFIFO…
  9. 9. Levels of cache
  10. 10. Loading
  11. 11. HITCACHESOURCEOFDATA
  12. 12. MISSCACHESOURCEOFDATA
  13. 13. Cache performance - StatisticsHitsMissesSizeAverage GetTimeEviction Count
  14. 14. Common Data PatternsLocality Hot Set DatachangesCatalog(Countries) Low Low LowInventory(Stocks) High High HighConversation(Shopping Cart) High High Low
  15. 15. Caches around usBrowser cacheUse cache control headers: max age, no cache
  16. 16. Database• Persistence Layer – JPA – 2 layers of cache
  17. 17. High computationService – Spring 3.1 Cache AbstractionJCache
  18. 18. Web Service / 3rd partyMultiple clients - Standalone Cache ServerService – Spring 3.1 Cache Abstraction/JCache
  19. 19. Cache Providers - JCACHEjava.util.Map GUAVA caches
  20. 20. Questions

×