Skip to main content



      Home
Home » Eclipse Projects » EclipseLink » Cache Annotation(Issue in Cache - Expire attribute)
Cache Annotation [message #1076696] Wed, 31 July 2013 14:56 Go to next message
Eclipse UserFriend
I have configured @Cache annotation in the entity class level (Refer attachment) as below and set the expire time to 7 minutes.

@Cache(type = CacheType.FULL, isolation = CacheIsolationType.SHARED, size = 64000, expiry = 420000)

First time when I tried to load data by invoking find method, the data has retrieved from shared cache. But when I attempt to retrieve the data after 5 minutes, the data has loaded from database instead of loading from shared cache. I am expecting the data to be loaded from shared cache because I set to expire the instance after 7 minutes.

Please someone let me know what could be wrong and how to resolve.
  • Attachment: cache.zip
    (Size: 9.30KB, Downloaded 213 times)
Re: Cache Annotation [message #1082441 is a reply to message #1076696] Thu, 08 August 2013 11:11 Go to previous message
Eclipse UserFriend
The expiry is from when the data was originally put into the cache, not the last find() operation.
When do you put the data into the cache? Are you sure you are timing things correctly? Try 1 minutes, etc.
Previous Topic:Problem with table generation using a converter and column length
Next Topic:Example AttributeTransformer for @Transformation
Goto Forum:
  


Current Time: Thu Jul 10 05:23:01 EDT 2025

Powered by FUDForum. Page generated in 0.47097 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top