]
Steve Ebersole commented on HHH-5295:
-------------------------------------
Thanks Sergey!
Rendered JPAQL query shall be the same all the times, aliases shall
not have random indexes
-------------------------------------------------------------------------------------------
Key: HHH-5295
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-5295
Project: Hibernate Core
Issue Type: Improvement
Components: entity-manager
Affects Versions: 3.5.0-Final
Reporter: Sergey Vladimirov
Assignee: Steve Ebersole
Priority: Trivial
Fix For: 3.6.0.Beta2, 3.5.5
Original Estimate: 1h
Time Spent: 13m
Remaining Estimate: 47m
Each time JPAQL query is rendered from CriteriaQuery it has new aliases for table
aliases. It should be the same for same CriteriaQuery (or CriteriaQueries that builded in
the same way) all the times.
Reason: QueryStructure uses HashSet to store roots.
Solution: replace HashSet with LinkedHashSet:
from
private Set<Root<?>> roots = new HashSet<Root<?>>();
to
private Set<Root<?>> roots = new LinkedHashSet<Root<?>>();
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: