I simplified the testcase. Just the 2 uploaded entity files Kunde.java and Betreuer.java are sufficient [together with the attached session bean file KundenverwaltungBean.java]
http://opensource.atlassian.com/project ... se/EJB-229
1) If I invoke merge() for a modified Kunde object, then it CRASHES.
2) If I invoke merge() for a modified Betreuer object, then EVERYTHING WORKS FINE.
The difference is
1) In Kunde.java [the crashing entity]
@OneToOne(mappedBy="kunde")
private Betreuer betreuer = null;
2) Betreuer.java
@OneToOne
@JoinColumn(name="kunde_fk")
private Kunde kunde = null;
Is there a problem due to the absence of @JoinColumn?