-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: The transaction is no longer active - 'Marked rollback.'
PostPosted: Mon Dec 15, 2003 11:23 pm 
Newbie

Joined: Wed Nov 12, 2003 7:20 am
Posts: 6
Hi,

Is there anyone out there that faced similar problem, it happened Weblogic EJB environment, the error was thrown when you try to perform
- any hibernate transaction that query of update db
- if it happened that it failed, because of e.g. duplicate key transaction, it throws an exception, and context.setRollbackOnly() is set.
- Traced the error thrown when calling session.close(), inside the code is tryting to get conn.getSQLWarnings(), this is the point where JDBC Connection is thrown.

Is there a way for hibernate not to call getSQLWarnings()? Are there other alternatives on how I should code my ejb. Basically I just set context.setRollbackOnly() for any HibernateException

Unhandled Exception:
com.xtremax.ana.exception.AnaException:
Start server side stack trace:
com.xtremax.ana.exception.AnaException
at com.xtremax.ana.ejb.UserManagerBean.closeSession(UserManagerBean.java:250)
at com.xtremax.ana.ejb.UserManagerBean.loadUsers(UserManagerBean.java:153)
at com.xtremax.ana.ejb.UserManagerBean_ymjd1a_EOImpl.loadUsers(UserManagerBean_ymjd1a_EOImpl.java:154)
at com.xtremax.ana.ejb.UserManagerBean_ymjd1a_EOImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:441)
at weblogic.rmi.cluster.ReplicaAwareServerRef.invoke(ReplicaAwareServerRef.java:114)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:382)
at weblogic.security.service.SecurityServiceManager.runAs(SecurityServiceManager.java:726)
at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:377)
at weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:30)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:234)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:210)
Caused by: net.sf.hibernate.JDBCException: Cannot close connection: The transaction is no longer active - status: 'Marked rollback. [Reason=weblogic.transaction.internal.AppSetRollbackOnlyException]'. No further JDBC access is allowed within this transaction.
at net.sf.hibernate.impl.SessionFactoryImpl.closeConnection(SessionFactoryImpl.java:409)
at net.sf.hibernate.impl.SessionImpl.disconnect(SessionImpl.java:2946)
at net.sf.hibernate.impl.SessionImpl.close(SessionImpl.java:438)
at com.xtremax.util.SessionManager.closeSession(SessionManager.java:48)
at com.xtremax.ana.ejb.UserManagerBean.closeSession(UserManagerBean.java:247)
... 11 more
Caused by: java.sql.SQLException: The transaction is no longer active - status: 'Marked rollback. [Reason=weblogic.transaction.internal.AppSetRollbackOnlyException]'. No further JDBC access is allowed within this transaction.
at weblogic.jdbc.jts.Connection.checkIfRolledBack(Connection.java:590)
at weblogic.jdbc.jts.Connection.getWarnings(Connection.java:442)
at net.sf.hibernate.impl.SessionFactoryImpl.closeConnection(SessionFactoryImpl.java:404)
... 15 more


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 15, 2003 11:41 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 12:50 pm
Posts: 5130
Location: Melbourne, Australia
Please post questions in exacty ONE forum!


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.