Hi All,
I have an ehcache second level configured, but I have the following issue.
If I load objects from the database using a Query or Criteria the second level cache works just fine.
But, if I insert a record and than query (in the same session) for this record anytimes, every time the cache hit is missed and a new query to the database is performed.
The strange thing is that from the log I can see that the object was inserted into the cache, and the UpdateTimestampsCache marks the newly created object as Pre-invalidated (checking the source code, I guess because of the native generator).
I guess for the first hit is makes sense as the data was nealy created. But the next queries it should work.
Have you guys already faced anything like this?
_________________ []'s
Nadilson
|