[hibernate-issues] [Hibernate-JIRA] Assigned: (HHH-6275) Unexpected audit entries when using cascadeType.ALL

Gail Badner (JIRA) noreply at atlassian.com
Mon Aug 15 20:58:04 EDT 2011


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

Gail Badner reassigned HHH-6275:
--------------------------------

    Assignee: Adam Warski

Adam, please assign as appropriate.
Thanks,
Gail

> Unexpected audit entries when using cascadeType.ALL
> ---------------------------------------------------
>
>                 Key: HHH-6275
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-6275
>             Project: Hibernate Core
>          Issue Type: Bug
>          Components: envers
>    Affects Versions: 3.6.4
>         Environment: mac os 10.6.7
> java 1.6.0
>            Reporter: Amin Mohammed-Coleman
>            Assignee: Adam Warski
>         Attachments: hibernate-envers-test.zip
>
>
> I have the following object model
>  
> Class A {
> @OneToMany (cascade=CascadeType.ALL)
>   Set<B> setOfClassB = new HashSet<B>();
>  
> }
>  
> @Audited
> Class B {
>   String name;
>    String value;
>   @ManyToOne(cascade=CascadeType.ALL)
>    @Audited(targetAuditMode = RelationTargetAuditMode.NOT_AUDITED)
>    ClassA belongsTo;
> }
>  
>  
> Everything is ok. I can create an instance of classA with a set of audited classB's.  WHat is interesting is that if i update ClassA with any other data I get an entry update in the audit table for each entity classB saying an update occurred which is not correct as I only updated classA which is not audited.
> Please see http://community.jboss.org/thread/166827?tstart=0, also I have attached a small test case

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