]
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: