Unexpected audit entries when using cascadeType.ALL

Description

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

Environment

mac os 10.6.7
java 1.6.0

Status

Assignee

AdamA

Reporter

Amin Mohammed-Coleman

Fix versions

None

Labels

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

3.6.4

Priority

Major
Configure