1 Reply Latest reply on Aug 22, 2007 6:21 AM by johnburgess

    Transactions timing out?

    greigm

      Can anyone help me figure out my problem, I basically have a simple jsp deployed in a web-app (war) which uses JNDI to lookup an EJB3 stateless Bean and execute a single method. The method loads a large amount of data from a table into memory then loops through this data, performing a select to find a related record and updating/inserting any changes.

      All done through a single xa Datasource (MSSQL2000 using jtds). I'm finding that the process can perform thousands of SQL statements then suddenly I receive:

      2007-07-12 14:06:35,841 WARN [com.arjuna.ats.arjuna.logging.arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.BasicAction_58] - Abort of action id -3f57feef:6e1:469615dd:e0 invoked while multiple threads active within it.
      2007-07-12 14:06:35,841 WARN [com.arjuna.ats.arjuna.logging.arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.CheckedAction_2] - CheckedAction::check - atomic action -3f57feef:6e1:469615dd:e0 aborting with 1 threads active!
      2007-07-12 14:06:35,857 FATAL [com.myco.dao.workauth.WorkAuthorisationSQLSDAO] SQLException caught in findByMasterReference
      org.jboss.util.NestedSQLException: Transaction is not active: tx=TransactionImple < ac, BasicAction: -3f57feef:6e1:469615dd:e0 status: ActionStatus.ABORTING >; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImple < ac, BasicAction: -3f57feef:6e1:469615dd:e0 status: ActionStatus.ABORTING >)
       at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:94)


      All SQL is performed in the old fashioned getDatasource->getConnection->getStatement old-school JDBC commands and not via Entity or other persistence tools.

      The error seems to happen after a large number of selects with no inserts/updates - my question, is there an implied transaction which times out because there have been no inserts/updates for a long time (even though there have been selects)? If so is there any way to prevent this timeout?



        • 1. Re: Transactions timing out?
          johnburgess

          We seem to be having the same problem here with a simple datasource connecting to HSQL rather than an XA datasource. If the number of actions in the transaction gets too large (> several thousand) we get a "No connection" error