[hibernate-issues] [Hibernate-JIRA] Updated: (HHH-1189) interfaces for Proxies are not regonized as interfaces

Steve Ebersole (JIRA) noreply at atlassian.com
Thu Aug 26 21:26:41 EDT 2010


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

Steve Ebersole updated HHH-1189:
--------------------------------

         Priority: Major  (was: Critical)
    Fix Version/s: 3.6.0.Beta4
       Issue Type: Bug  (was: Patch)

> interfaces for Proxies are not regonized as interfaces
> ------------------------------------------------------
>
>                 Key: HHH-1189
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1189
>             Project: Hibernate Core
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 3.1 rc3
>         Environment: Discovered on Hibernate 3.0, still present in 3.1rc3
>            Reporter: Tobias
>            Assignee: Steve Ebersole
>             Fix For: 3.6.0.Beta4
>
>         Attachments: eg.zip
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> In org.hibernate.tuple.PojoEntityTuplizer line 119 reads:
>  if ( !proxyInterface.isInterface() ) {
> and should be
>   if ( !subclassClass.isInterface() ) {
> So the code then would look like this:
> 			Subclass subclass = ( Subclass ) iter.next();
> 			Class subclassProxy = subclass.getProxyInterface();
> 			Class subclassClass = subclass.getMappedClass();
> 			if ( subclassProxy!=null && !subclassClass.equals( subclassProxy ) ) {
> 				if ( !subclassProxy.isInterface() ) {  // HERE!
> 					throw new MappingException(
> 					        "proxy must be either an interface, or the class itself: " + 
> 					        subclass.getEntityName()
> 					);
> 				}
> 				proxyInterfaces.add( subclassProxy );
> 			}
> After that change the specified interfaces for subclass proxies are regonized as such. Without this patch the superclass is checked, which may not have/be an interface as proxy class.

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