[hibernate-issues] [Hibernate-JIRA] Resolved: (HHH-1722) query cache wont work with serialized/deserialized criteria due to ResultTransformer

Max Rydahl Andersen (JIRA) noreply at atlassian.com
Mon Aug 4 11:01:30 EDT 2008


     [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1722?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Max Rydahl Andersen resolved HHH-1722.
--------------------------------------

    Resolution: Duplicate

> query cache wont work with serialized/deserialized criteria due to ResultTransformer
> ------------------------------------------------------------------------------------
>
>                 Key: HHH-1722
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1722
>             Project: Hibernate3
>          Issue Type: Bug
>          Components: core
>         Environment: 3.2.0 svn head
>            Reporter: Mario Ivankovits
>            Assignee: Max Rydahl Andersen
>         Attachments: ResultTransformerIdentity.patch, ResultTransformerIdentity.patch
>
>
> A serialized/deserialized DetachedCriteria do not work correctly with
> the query cache.
> The problem is the ResultTransformer in QueryKey.
> In CriteraImpl the resultTransformer will be set to Criteria.ROOT_ENTITY.
> This makes it down into the QueryKey.
> After serialize/deserialize the instance of resultTransformer in
> CriteriaImpl has changed (not that a surprise  ;-)  ) and thus - in the
> end - the QueryKey changed.
> Subsequent lookup in the query-cache will no longer work.
> The query will be executed again and put int the query-cache.
> The cache grows - every lookup failes.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the hibernate-issues mailing list