Skip to content

A schema wrapper and additional date-based caching option on top of Spring Cache.

Notifications You must be signed in to change notification settings

benkiefer/spring-cache

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

##Spring 3.1 Spring Cache Enhancements

Features

  • A schema wrapper on top of SpringCache.
  • Includes EntryDateTrackingCache, an additional cache that will remove an item from the cache if it is expired.
  • Supported expiration values include: SECONDS, MINUTES, HOURS

Build Status

##Usage Examples

Example 1: Use this if the ConcurrentMapCache and EntryDateTrackingCache are sufficient for your needs.

<caches:caching id="cacheManager">
    <caches:standard name="things"/>
    <caches:date-based-cache name="otherThings"
                    timeUntilExpiration="5"
                    unitOfMeasurement="MINUTES"/>
</caches:caching>

Example 2: Use this if you want to create your own cache and then reference it by id in the schema.

<bean id="cache1" class="org.springframework.cache.concurrent.ConcurrentMapCache">
    <constructor-arg index="0" value="things"/>
</bean>

<caches:caching id="cacheManager">
    <caches:cache-ref ref="cache1"/>
    <caches:date-based-cache name="otherThings"
                    timeUntilExpiration="5"
                    unitOfMeasurement="MINUTES"/>
</caches:caching>

About

A schema wrapper and additional date-based caching option on top of Spring Cache.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages