I have a question that is specific to Hibernate internals and not so much my code. If I send an object via rmi then it becomes detached, correct? In addition, if I close the session the object becomes detached? The problem is that after I do either of the above options Hibernate attempts to reassociate the proxy in the next session I create. This is fustrating to me because I want to clear the identifier and save it again with a new one. To be more specific I need to retrieve an object, send it via rmi, and then save it on the other side. Each side of the rmi connection has its own schema, but during my testing both sides are the same jvm/machine. I guess besides all that I am just curious as to how/why Hibernate is try to reassociate the proxy for me. I don't want it to, and I am not telling it to.
Thanks, Shane
Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp
Hibernate version:
2.1.x
Mapping documents:
Code between sessionFactory.openSession() and session.close():
Full stack trace of any exception that occurs:
Caused by: net.sf.hibernate.AssertionFailure: null identifier
at net.sf.hibernate.engine.Key.<init>(Key.java:23)
at net.sf.hibernate.engine.Key.<init>(Key.java:34)
at net.sf.hibernate.impl.SessionImpl.reassociateProxy(SessionImpl.java:1025)
at net.sf.hibernate.impl.SessionImpl.unproxyAndReassociate(SessionImpl.java:1011)
at net.sf.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java:1377)
Name and version of the database you are using:
oracle 8i
The generated SQL (show_sql=true):
Debug level Hibernate log excerpt: