1 Reply Latest reply on Feb 8, 2008 10:38 AM by Cory Dahlstrom

    Multiple JMS sessions inside 1 XA transaction

    Cory Dahlstrom Newbie

      We are having a situation where we are getting random "javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted]" failures.

      The situation occurs randomly, but when it does occur, we are always doing multiple JMS publishes within 1 XA transaction.

      For each message we do this:
      1) Get the connection factory "java:JmsXA"
      2) Create a connection from the factory
      3) Create a non-transacted JMS session
      4) Create a queue sender
      5) Create an ObjectMessage
      6) Set the Serializable into the ObjectMessage
      7) Send the ObjectMessage with the sender
      8) Close the sender / session / queue connection

      Does anyone see a problem with this?

      Thanks in advance.

      Cory.