1 Reply Latest reply on Aug 4, 2003 2:59 PM by Adrian Brock

    LocalTransaction and ManagedConnection.getConnection call or

    Michael Pichler Newbie

      Hello,
      we are using a LocalTransaction with a connector.

      The JCA spec illustrates (ch. 6.10.3, fig. 24) that the container should call ManagedConnection.getConnection() _before_ LocalTransaction.begin(). We observed that Bea WL behaves like this and saved some data of the ConnectionRequestInfo passed to getConnection to use them inside the ltx.begin call to our native system.

      However, JBoss 3.2 does call the methods in the opposite order: Transaction.begin arrives before ManagedConnection.getConnection, and no ConnectionRequestInfo is available at this time.

      Is this a JBoss bug or just a different interpretation of the JCA spec?

        • 1. Re: LocalTransaction and ManagedConnection.getConnection cal
          Adrian Brock Master

          Interesting, the XA scenario which is
          more explicit in the text does the opposite.

          In the jboss connection manager, we actually create
          something called a LocalXAResource
          to wrap the local transaction.
          This simplifies the code, because we only have to deal
          with "XAResources" with suitable warnings when
          an attempt is made to use it with other resource
          managers in the same transaction.

          The CRI is passed to either
          ManagedConnectionFactory.createManagedConnection or
          ManagedConnectionFactory.matchManagedConnections
          before the connection is enlisted in the transaction.

          Regards,
          Adrian