Saturday, August 11, 2007

Caching the result of methods using Spring and EHCache


Caching the result of methods using Spring and EHCache

Spring 1.1.1 introduced integration for EHCache for general cache use.

I will show here a sample Interceptor that allows for declarative caching of methods results.

Configure EHCache using Spring IoC

Creating our MethodCacheInterceptor

Using MethodCacheInterceptor

0 comments: