Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[eclipselink-users] Outdated documentation

Hi all,

I think the documentation of the Query Result Cache on the following pages isn't correct anymore: http://www.eclipse.org/eclipselink/documentation/2.6/concepts/cache008.htm and https://wiki.eclipse.org/EclipseLink/UserGuide/JPA/Basic_JPA_Development/Caching/Query_Cache.

The section in question is this one:

"The query results cache does not pick up committed changes from the application as the object cache does. It should only be used to cache read-only objects, or should use an invalidation policy to avoid caching stale results. Committed changes to the objects in the result set will still be picked up, but changes that affect the results set (such as new or changed objects that should be added/removed from the result set) will not be picked up."

According to http://java-persistence-performance.blogspot.de/2013/06/cool-performance-features-of.html, "In EclipseLink 2.5 automatic invalidation of the query cache was added.". This is consistent with my observation that *any* update to an entity on which a Named Query with the Query Result Rache will invalidate the cache. In particular also INSERTs, unlike the documentation above says.

James Sutherland also writes "[...] as by default any insert to customer will invalidate the query result cache", taken from here: http://java-persistence-performance.blogspot.com/2011/06/how-to-improve-jpa-performance-by-1825.html?showComment=1374157706288#c7265127414915647943 

Since the text is the same for 2.4, 2.5 and 2.6, it should probably be fixed both for 2.5 and 2.6, and also in the wiki? I hope someone on the mailing list has the rights to do this.


Best regards,
Joachim Kanbach


Back to the top