[hibernate-issues] [Hibernate-JIRA] Created: (HHH-2985) Patch to HHH-952 should propagate enabledFilters

Céline Launay (JIRA) noreply at atlassian.com
Mon Dec 3 06:01:56 EST 2007


Patch to HHH-952 should propagate enabledFilters
------------------------------------------------

                 Key: HHH-2985
                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-2985
             Project: Hibernate3
          Issue Type: Bug
          Components: core
    Affects Versions: 3.2.5
            Reporter: Céline Launay


The patch submitted for issue HHH-952 reads like so :
		// patch to generate joins on subqueries stolen from CriteriaLoader
		CriteriaJoinWalker walker = new CriteriaJoinWalker(persister,
				innerQuery, factory, criteriaImpl, criteriaImpl
						.getEntityOrClassName(), new HashMap()) {
			// need to override default of "this_" to whatever the innerQuery is using
			protected String generateRootAlias(final String description) {
				return innerQuery.getRootSQLALias();
			}
		};

Note how it passes a new HashMap as filters. Wouldn't it be better to propagate session.getEnabledFilters(), like so :
		// patch to generate joins on subqueries stolen from CriteriaLoader
		CriteriaJoinWalker walker = new CriteriaJoinWalker(persister,
				innerQuery, factory, criteriaImpl, criteriaImpl
						.getEntityOrClassName(), session.getEnabledFilters()) {
			// need to override default of "this_" to whatever the innerQuery is using
			protected String generateRootAlias(final String description) {
				return innerQuery.getRootSQLALias();
			}
		};


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