[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-971) ConcurrentModificationException with <many-to-one property_ref="..."/> in a set of composite elements

Ghadi Audi (JIRA) noreply at atlassian.com
Wed Jul 28 05:45:36 EDT 2010


    [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-971?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=37942#action_37942 ] 

Ghadi Audi commented on HHH-971:
--------------------------------

"A many-to-one association with a property-ref outside a composite element didn't cause this exception."
How did you manage to use a many-to-one inside <set> but outside composite element?

> ConcurrentModificationException with <many-to-one property_ref="..."/> in a set of composite elements
> -----------------------------------------------------------------------------------------------------
>
>                 Key: HHH-971
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-971
>             Project: Hibernate Core
>          Issue Type: Bug
>          Components: core
>         Environment: Hibernate 3.1 beta 3, Java 1.4.2_08
>            Reporter: Emmanuel Bourg
>            Assignee: Diego Plentz
>
> I tried to drop the latest 3.1-beta3 jar in my application currently working with hibernate 3.0.5 to test the new features and found out that an exception is now thrown when the SessionFactory is build :
> java.util.ConcurrentModificationException
>         at java.util.AbstractList$Itr.checkForComodification(AbstractList.java:448)
>         at java.util.AbstractList$Itr.remove(AbstractList.java:433)
>         at org.hibernate.cfg.Configuration.secondPassCompile(Configuration.java:1006)
>         at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1120)
>         at myapp.dao.impl.hibernate.SessionManager.init(SessionManager.java:74)
> I tracked down the issue to the mapping of a many-to-one association using a property-ref inside a set of composite elements. The mapping generating this error looks like this:
> <set name="children" table="CHILD">
>   <key column="PARENT_ID"/>
>   <composite-element class="Child">
>     <many-to-one name="foo" column="FOO" property-ref="alternateId"/>
>   </composite-element>
> </set>
> A many-to-one association with a property-ref outside a composite element didn't cause this exception.

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