Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 312905

Summary: orphan-removal on 1-1 is not defaulting in the 2.1 eclipselink-orm.xml
Product: [WebTools] Dali JPA Tools Reporter: Karen Butzke <karenfbutzke>
Component: GeneralAssignee: Karen Butzke <karenfbutzke>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: neil.hauge
Version: 2.3Flags: neil.hauge: review+
Target Milestone: 2.3.1   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
proposed patch against head none

Description Karen Butzke CLA 2010-05-14 09:56:58 EDT
Given the following java class, add the EmployeeHistory entity to a 2.1 eclipselink-orm.xml file.   Select the virtual employee 1-1 and notice that the orphan removal checkbox displays false.  This is working in a 2.0 orm.xml file.

@Entity
public class EmployeeHistory {
    @OneToOne(orphanRemoval = true)
    private Employee employee;
}
Comment 1 Karen Butzke CLA 2010-05-14 10:19:22 EDT
Set metadata-complete to true and cascade settings are incorrectly defaulting in to the orm.xml and eclipselink-orm.xml relationship mappings
Comment 2 Karen Butzke CLA 2010-05-14 10:22:38 EDT
The cascade issue is only for 1-1 mappings and you have to have an EclipseLink platform to see it.
Comment 3 Karen Butzke CLA 2010-06-17 15:08:13 EDT
Created attachment 172149 [details]
proposed patch against head

This patch includes a lot of new tests along with the fixes
Comment 4 Karen Butzke CLA 2010-06-24 14:54:25 EDT
resolved in HEAD for 2.3.1 maintenance
Comment 5 Karen Butzke CLA 2010-07-20 10:32:31 EDT
verified fixed in build wtp-sdk-M-3.2.1-20100717062943