[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-4550) Document that update-timestamps cache region should not be configured for expiry.
Gail Badner (JIRA)
noreply at atlassian.com
Thu Jan 19 18:54:10 EST 2012
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-4550?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=45184#comment-45184 ]
Gail Badner commented on HHH-4550:
----------------------------------
Adrien, please create a new issue if Hibernate docs should be updated.
> Document that update-timestamps cache region should not be configured for expiry.
> ---------------------------------------------------------------------------------
>
> Key: HHH-4550
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-4550
> Project: Hibernate ORM
> Issue Type: Improvement
> Components: documentation
> Affects Versions: 3.3.2
> Environment: 3.3.2 GA
> Reporter: Guenther Demetz
> Assignee: Steve Ebersole
> Priority: Trivial
> Fix For: 3.3.x, 3.5.0-Beta-3
>
> Attachments: TestCaseQuryCache.jar
>
>
> When using hibernate's query cache (hibernate.cache.use_query_cache),
> then it's of fundamental importance to configure the Update Timestamps cache region in
> a way that his entries survive longer than the cached result sets in the Query cache region.
> Otherwise queries could return wrong (obsolete) result sets (See attached testcase).
> This is because the current UpdateTimestampsCache#isUpToDate implementation considers a result-set also as up-to-date,
> if there are no update-timestamps cached for the interested spaces (tables) at all.
> It if therefore important to notice that:
> 1- The Update-Timestamps-Cache-Region elements max-size should be configured higher than the number of tables you have
> on the db-schema, in manner that he can remember/hold the last update-timestamp for each table.
> 2- If you use any other eviction policy in the Update-Timestamps-Cache-Region, then you must assure
> that cached result sets in the Query-cache-region are evicted before relevant update-timestamps are going to be evicted.
> This fact should be clearly documented somewhere.
> Thanks
> G.D.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list