[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-7247) Bug on flushing context with modified non initialized lazy collection ( It works fine on hibernate 3.5.6 )

Hood Wilson Gusso Silva (JIRA) noreply at atlassian.com
Mon Apr 16 10:08:50 EDT 2012


    [ https://hibernate.onjira.com/browse/HHH-7247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=46304#comment-46304 ] 

Hood Wilson Gusso Silva commented on HHH-7247:
----------------------------------------------

Oh I forgot to inform that this error occurs only when we have cascade DELETE_ORPHAN.
( the exception is thrown from AbstractPersistentCollection.getOrphans() when trying to run a ForeignKeys.getEntityIdentifierIfNotUnsaved() )

> Bug on flushing context with modified non initialized lazy collection ( It works fine on hibernate 3.5.6 )
> ----------------------------------------------------------------------------------------------------------
>
>                 Key: HHH-7247
>                 URL: https://hibernate.onjira.com/browse/HHH-7247
>             Project: Hibernate ORM
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 3.3.2
>         Environment: This problem occurs on hibernate 3.3.2 and 3.3.1 
> ( The latest JPA1 hibernate implementations I've found )
>            Reporter: Hood Wilson Gusso Silva
>         Attachments: hibernateTc1.zip
>
>
> This is a quite trick problem that only occurs on modified lazy collections that aren't initialized
> ( Like when you do a add() operation without any previous size() or get() or toString() ... )
> I think that it will be easier to show it by a commented source.
> I made a little database (with only 3 simple tables to make possible to reproduce the error.) + a maven project 
> The maven project have 2 file called pom33.xml and pom35.xml so it's possible to easily see how the error occurs on 3.3.2 but not on 3.5.6
> the script to recreate the problem is available within the project too.
> BTW the source do a rollback ( So it won't change the database ).
> If you want changes on db it will be necessary to change the rollback() to commit()

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list