Re: Cascade and persist issues

2009-10-01 Thread ljnelson
On Thu, Oct 1, 2009 at 12:39 PM, Laird Nelson wrote: > Here they are, simplified. I apologize for the length of this email. > And the contents of the various test cases that fail. "dao" is a simple EJB that wraps an entity manager. I'm running the whole thing in OpenEJB. final X x = new X()

Re: Cascade and persist issues

2009-10-01 Thread ljnelson
Here they are, simplified. I apologize for the length of this email. X is linked to Y by an XY instance; XY has a composite key called an XY.ID. I challenge someone to put a Y into X's bindings under the type "foo" with: (a) no flush invocations (as though in a JTA world) (b) a minimum of merge(

RE: Cascade and persist issues

2009-10-01 Thread C N Davies
Maybe just send a copy of your class definition, just the part where you define your variables, join, cascades etc. might give a clue. -Original Message- From: ljnelson [mailto:ljnel...@gmail.com] Sent: Friday, 2 October 2009 2:15 AM To: users@openjpa.apache.org Subject: Re: Cascade and p

Re: Cascade and persist issues

2009-10-01 Thread ljnelson
Thanks, but I'm using emacs (gasp) on the command line. :-( I'll see if I can reproduce this thing in a sane, trimmed down manner and send the files this way. L On Thu, Oct 1, 2009 at 11:56 AM, crispyoz (via Nabble) < ml-user+243560-833017...@n2.nabble.com > wrote: > A lot of those error mess

News from bug 673 ?

2009-10-01 Thread Jean-Baptiste BRIAUD -- Novlog
Hi, I'm encoutering that exact bug : https://issues.apache.org/jira/browse/OPENJPA-673?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12619733 #action_12619733 Apparently, it is stil open since August 2008. Any news or status about that ? Any workarou

RE: Cascade and persist issues

2009-10-01 Thread C N Davies
A lot of those error messages don't make any sense to me either. Try cleaning your project, if I change the cascade types on fields Eclipse doesn't seem to pick it up. Doing a clean then rebuild fixes the issue. Chris -Original Message- From: ljnelson [mailto:ljnel...@gmail.com] Sent: F

Re: Cascade and persist issues

2009-10-01 Thread ljnelson
Yes, I guess my point is: I am cascading the relationship with a CascadeType of ALL, but OpenJPA is telling me that I need to mark it as CascadeType.ALL, which...it is. On Thu, Oct 1, 2009 at 11:01 AM, crispyoz (via Nabble) < ml-user+243560-833017...@n2.nabble.com > wrote: > I do something simil

RE: Cascade and persist issues

2009-10-01 Thread C N Davies
I do something similar, I have a user and a user has a single address so I use like this: User: Private String name; @OneToOne cascade={CascadeType.ALL}) Private Address address; ... I construct the user, construct the address, link the address to the user and just use persist on the user w

Cascade and persist issues

2009-10-01 Thread Laird Nelson
On a field marked @OneToMany(/*...*/ cascade = CascadeType.ALL), I am getting this error at persist() time: org.apache.openjpa.persistence.ArgumentException: Encountered new object in persistent field "blox.party.jpa.PartyEntity.postalAddresses" during attach. However, this field does not allow