Hibernate version: 2.1
Name and version of the database you are using: MySQL
Hi,
I have 2 EJBs:
The 1st EJB creates a large graph of objects (my domain model).
The 2nd EJB needs to use this graph of objects, should i:
A) Pass the root object of the graph - but risk a lot of serializing & de-serializing as the EJBs could be in different servers.
B) Get EJB1 to save the data, and then EJB2 to load the data back before using it? (Is session.flush() enough?)
Answer B seems better, but just wanted to know if there was another, better way of passing a large graph of persistable objects between EJBs.
Thanks.
|