Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » JBoss User Help »

[jboss-user] [Persistence, JBoss/CMP, Hibernate,
 Database] - Is there any reason to hard-code
 AUTO_CLOSE_SESSION in JBoss

scott.stark@jboss.org

2007-06-14


Hi,

We are running into the problem that after a transaction is committed, the hibernate session is closed right away. Tracing the problem to the root, we found the in class

| org.jboss.hibernate.jmx.Hibernate
|
there are these lines:

| settings.setProperty(Environment.FLUSH_BEFORE_COMPLETION, "true");
| settings.setProperty(Environment.AUTO_CLOSE_SESSION, "true");
|

Why is it hard-coded to auto-close the session here? Is there a reason to do this? Where can I set this property to false without going to change it in the code?

I'm using 4.2.0GA. Thanks

ak


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4054357#4054357

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4054357
_______________________________________________
jboss-user mailing list
jboss-user@(protected)
https://lists.jboss.org/mailman/listinfo/jboss-user
©2008 junlu.com - Jax Systems, LLC, U.S.A.