Recipes Overview

The recipes here are concise examples for specific use cases that will help you get started with Ehcache.

The following sections provide a documentation Table of Contents and additional information about Recipes.

Recipes Table of Contents

Recipe Description
Web Page and Fragment Caching How to use the included Servlet Filters to cache web pages and web page fragments.
Configure a Grails App for Clustering How to configure a Grails Application for clustered Hibernate 2nd Level Cache.
Data Freshness and Expiration How to maintain cache \\\"freshness\\\" by configuring TTL and data expiration properly.
WAN Replication Three strategies for configuring WAN replication.
Caching Empty Values Why caching empty values can be desirable to deflect load from the database.
Database Read Overload When many readers simultaneously request the same data element, it is called the \\\"Thundering Herd\\\" problem. How to prevent it in a single JVM or a clustered configuration.
Database Write Overload Writing to the database is a bottleneck. Configure the Ehcach Write-behind feature to offload database writes.
Caching methods with Spring Annotations Adding caching to methods using the Ehcache Annotations for Spring project.
Cache Wrapper A simple class to make accessing Ehcache easier for simple use cases.


Let's Add More

If you have suggestions or ideas for more recipes, please tell us about them using the forums.