Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] Cascade.PERSIST marked List is not getting persited when Parent Object is persisted

Hello!

What i'am trying to do is the following:

(App is a Java SE Netbeans RCP Application)

- a fresh EntityManager is generated when the customer management form is
opened (this is the only EM used in that context)

- Customer is opened (therefore it get's read by the EntityManager)

- a new Transaction is started --> EntityTransaction t =
em.getTransaction(); t.begin();

- A Vendingmachine is added to the Customer

- the Vendingmachine generates the VendingmachineEvent

- The customer is saved: em.persist(customer); t.commit();



As i'm using only one Entity Manager i assume the object is read through
this EM's context.
It is absolutely strange to me, that i am doing nearby the same things in
other parts of my application and there they are working a normally. If i
iterate through the whole ArrayList of Events prior to persist the Customer
object everything works fine. It seems to me that the Entity Manager isn't
taking notice of the changed contents of the ArrayList containing the
VendingmachineEvents.

Best Regards, 
christian

-- 
View this message in context: http://www.nabble.com/Cascade.PERSIST-marked-List-is-not-getting-persited-when-Parent-Object-is-persisted-tp22717289p22724876.html
Sent from the EclipseLink - Users mailing list archive at Nabble.com.



Back to the top