O'Reilly logo

Instant Effective Caching with Ehcache by Daniel Wind

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Hibernate second-level caching (Intermediate)

In this recipe, we will cover the following topics:

  • Ehcache as caching engine provider in a Hibernate project
  • Hibernate second-level caching and its implementation

We will examine how to implement Hibernate second-level caching by integrating Ehcache as the cache provider. We also review what configuration is required to fully extend Ehcache in Hibernate.

Getting ready

Second-level caching is associated to the session factory object. This simply means that caching can be shared across multiple sessions instead of a per-session basis (first-level caching). Implementing second-level caching with Ehcache is one of the most utilized techniques in the industry.

In this recipe we discuss Ehcache integration with ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required