[hibernate-issues] [Hibernate-JIRA] Updated: (HSEARCH-546) ProjectionLoader ignores FetchMode.JOIN set via a Criteria

Emmanuel Bernard (JIRA) noreply at atlassian.com
Fri Oct 8 11:05:57 EDT 2010


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

Emmanuel Bernard updated HSEARCH-546:
-------------------------------------

         Assignee: Emmanuel Bernard
    Fix Version/s:     (was: 3.3.0)
                   3.3.0.Beta2

> ProjectionLoader ignores FetchMode.JOIN set via a Criteria
> ----------------------------------------------------------
>
>                 Key: HSEARCH-546
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-546
>             Project: Hibernate Search
>          Issue Type: Bug
>          Components: engine
>    Affects Versions: 3.2.0.Final
>            Reporter: Hardy Ferentschik
>            Assignee: Emmanuel Bernard
>             Fix For: 3.3.0.Beta2
>
>
> Hibernate Search allows you to optimize the fetching strategy for association by setting an optional {{Criteria}}:
> {code}
> Criteria fetchingStrategy = fullTextSession.createCriteria(Foo.class);
> fetchingStrategy.setFetchMode("foos", FetchMode.JOIN);
> fullTextQuery.setCriteriaQuery(fetchingStrategy);
> {code}
> This works fine for normal queries, however, in the case of projection queries and the use of {{FullTextQuery.THIS}} the fetch mode gets ignored. This is due to the fact that the {{ProjectionLoader}} internally uses {{MultiClassesQueryLoader}} in case {{FullTextQuery.THIS}} is projected. The logic from {{FullTextQueryImpl}} deciding which entity loader to use should really also be used within {{ProjectionLoader}}.
> See also {{FullTextQueryImpl.getLoader}}

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