1 Reply Latest reply on Mar 31, 2010 11:50 AM by Dmytro Panchenko

    TestNG Integration: transaction error during renderResponse

    Dmytro Panchenko Newbie

      Hi,


      I am writing a TestNG integration test for an application that uses <tx:ejb-transaction />.
      The test accesses seam components during both FacesRequest.applyRequestValues() and FacesRequest.renderResponse(), and the components hit the database at both phases.


      applyRequestValues() is executed properly but at renderResponse(), it says that the transaction is marked for rollback:


      ERROR [org.hibernate.util.JDBCExceptionReporter] Transaction is not active: tx=TransactionImple < ac, BasicAction: a170dae:8ba:4bb238b0:69 status: ActionStatus.ABORT_ONLY >; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImple < ac, BasicAction: a170dae:8ba:4bb238b0:69 status: ActionStatus.ABORT_ONLY >)
      ERROR [org.jboss.aspects.tx.TxPolicy] javax.ejb.EJBTransactionRolledbackException: org.hibernate.exception.GenericJDBCException: Cannot open connection
      



      No exceptions are thrown before that. I am using Seam 2.1.0 and JBoss 4.2.3


      Do you know why the transaction is marked for rollback and how it can be fixed?


      Thank you in advance,


      Dmytro