Details
-
Type:
Bug
-
Status:
In Progress
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: 2.1.3, 2.2
-
Component/s: Persistence
-
Labels:
-
Environment:NA
Description
A criteria query in a Grails service class where an eager join is expected via FetchMode.SELECT or FetchMode.EAGER (to avoid lazy loading of child objects), the query executes as expected, but when crawling the association in a view, Hibernate is executing subsequent queries as if it were lazily loading the associations.
For more details, look at the attached sample app or see original question on StackOverFlow: http://stackoverflow.com/questions/14758499/grails-gorm-criteria-query-eager-fetching
Sample application demonstrates the issue by disabling the Hibernate OSIV and a "org.hibernate.LazyInitializationException" happens when visiting: http://localhost:8080/GrailsEagerFetchingProblem/market/test
-
Hide
- GrailsEagerFetchingProblem.zip
- 08/Feb/13 12:08 PM
- 2.20 MB
- Bobby Warner
-
- GrailsEagerFetchingProblem/.classpath 7 kB
- GrailsEagerFetchingProblem/.git/config 0.3 kB
- GrailsEagerFetchingProblem/.../description 0.1 kB
- GrailsEagerFetchingProblem/.git/HEAD 0.0 kB
- GrailsEagerFetchingProblem/.../applypatch-msg.sample 0.4 kB
- GrailsEagerFetchingProblem/.../commit-msg.sample 0.9 kB
- GrailsEagerFetchingProblem/.../post-update.sample 0.2 kB
- GrailsEagerFetchingProblem/.../pre-applypatch.sample 0.4 kB
- GrailsEagerFetchingProblem/.../pre-commit.sample 2 kB
- GrailsEagerFetchingProblem/.../pre-rebase.sample 5 kB
- GrailsEagerFetchingProblem/.../prepare-commit-msg.sample 1 kB
- GrailsEagerFetchingProblem/.../update.sample 4 kB
- GrailsEagerFetchingProblem/.git/index 57 kB
- GrailsEagerFetchingProblem/.git/.../exclude 0.2 kB
- GrailsEagerFetchingProblem/.git/.../HEAD 0.2 kB
- GrailsEagerFetchingProblem/.git/.../master 0.2 kB
- GrailsEagerFetchingProblem/.git/.../HEAD 0.2 kB
- GrailsEagerFetchingProblem/.../pack-ba6303292733fc106f1bf409029f6b128c9f9cea.idx 14 kB
- GrailsEagerFetchingProblem/.../pack-ba6303292733fc106f1bf409029f6b128c9f9cea.pack 902 kB
- GrailsEagerFetchingProblem/.../packed-refs 0.1 kB
- GrailsEagerFetchingProblem/.git/.../master 0.0 kB
- GrailsEagerFetchingProblem/.git/.../HEAD 0.0 kB
- GrailsEagerFetchingProblem/.gitignore 0.2 kB
- GrailsEagerFetchingProblem/.project 0.9 kB
- GrailsEagerFetchingProblem/application.properties 0.1 kB
- GrailsEagerFetchingProblem/.../ApplicationResources.groovy 0.1 kB
- GrailsEagerFetchingProblem/.../BootStrap.groovy 0.9 kB
- GrailsEagerFetchingProblem/.../BuildConfig.groovy 2 kB
- GrailsEagerFetchingProblem/.../Config.groovy 4 kB
- GrailsEagerFetchingProblem/.../DataSource.groovy 1 kB
Activity
- All
- Comments
- Work Log
- History
- Activity
- Git Commits
This is yet another Hibernate bug https://hibernate.onjira.com/browse/HHH-3524