Hi,
I would like to know when hibernate detaches persistent objects from session. Is it :
- session.clear()
- session.close()
- session.flush()
I am facing a problem where objects are still attached to the hibernate session even after a session.close(). The same behavior is also observed even if i set the hibernate.transaction.flush_before_completion to true.
FYI .. the transaction factory used in my application is the default JDBCTransactionFactory.
Following is my code snippet.
Code:
Transaction tx = session.beginTransaction();
xxx.....
session.save(transientObject);
tx.commit();
session.close()
Help would be greatly appreciated.
Regards,
Himadri