On Tue, 19 Jun 2007 18:24:10 -0300, Norman Franke <[EMAIL PROTECTED]> wrote:
1. As Michael noted, they aren't thread safe.
2. This really gets to a bigger issue, in that these objects aren't
valid outside of a session. Once the session closes, they are
technically invalid according to what I read in "Hibernate in Action".
This is because Hibernate may want to lazy fetch things, e.g.
relationships.
In a second request and therefore a second session, you can merge your
your detached instance using the Object merge(Object o) method of Session.
The returned object has the same values as yours detached one, but it is
associated with the session. More details here:
http://www.hibernate.org/hib_docs/v3/api/org/hibernate/Session.html#merge(java.lang.Object)
Thiago
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]