1 Reply Latest reply on Feb 15, 2005 12:08 PM by Clive Hill

    Unable to get Topics to participate in transaction

    Clive Hill Newbie

      My application can pull a message off a JBoss 4.0.1 topic OK.
      but if the operation is wrapped in an XA transaction then it fails.

      My app gets these errors:
      Feb 11 16:51:02-Thread 1c0c: Connection failure:
      org.jboss.mq.SpyJMSException: Exiting on IOE; - nested throwable: (java.io.EOFException)
      at org.jboss.mq.Connection.asynchFailure(Connection.java:436)
      at org.jboss.mq.il.uil2.UILClientILService.asynchFailure(UILClientILService.java:145)
      at org.jboss.mq.il.uil2.SocketManager$ReadTask.handleStop(SocketManager.java:402)
      at org.jboss.mq.il.uil2.SocketManager$ReadTask.run(SocketManager.java:334)
      at java.lang.Thread.run(Thread.java:534)
      Caused by: java.io.EOFException
      at java.io.ObjectInputStream$BlockDataInputStream.readByte(ObjectInputStream.java:2603)
      at java.io.ObjectInputStream.readByte(ObjectInputStream.java:845)
      at org.jboss.mq.il.uil2.SocketManager$ReadTask.run(SocketManager.java:281)
      ... 1 more
      org.jboss.mq.SpyXAException: - nested throwable: (org.jboss.mq.SpyJMSException: Cannot process a transaction; - nested throwable: (java.io.EOFException))
      org.jboss.mq.SpyXAResource.prepare(SpyXAResource.java:135)

      and the server log shows these errors:

      2005-02-11 16:51:01,625 DEBUG [org.jboss.mq.il.uil2.SocketManager] Begin ReadTask.run
      2005-02-11 16:51:01,625 DEBUG [org.jboss.mq.il.uil2.SocketManager] Begin WriteTask.run
      2005-02-11 16:51:01,625 DEBUG [org.jboss.mq.il.uil2.SocketManager] Created ObjectOutputStream
      2005-02-11 16:51:01,705 DEBUG [org.jboss.mq.il.uil2.SocketManager] Created ObjectInputStream
      2005-02-11 16:51:01,736 DEBUG [org.jboss.mq.il.uil2.ServerSocketManagerHandler] Setting up the UILClientIL Connection
      2005-02-11 16:51:01,776 DEBUG [org.jboss.mq.il.uil2.ServerSocketManagerHandler] The UILClientIL Connection is set up
      2005-02-11 16:51:02,587 DEBUG [org.jboss.mq.il.uil2.ServerSocketManagerHandler] Exiting on IOE
      java.io.IOException: Class not found for xid.
      at org.jboss.mq.TransactionRequest.readExternal(TransactionRequest.java:68)
      at org.jboss.mq.il.uil2.msgs.TransactMsg.read(TransactMsg.java:56)
      at org.jboss.mq.il.uil2.SocketManager$ReadTask.run(SocketManager.java:292)
      at java.lang.Thread.run(Thread.java:534)
      2005-02-11 16:51:02,587 DEBUG [org.jboss.mq.server.BasicQueue] Nacked 1 messages for removed subscription Subscription[subId=-2147483648connection=ConnectionToken:DurableSubscriberExample/9592c002f1985b4b34f793f02c9dfb82 destination=TOPIC.CliveTopic.DurableSubscription[clientId=DurableSubscriberExample name=DurableSubscriberExample selector=null] messageSelector=null Local Create]
      2005-02-11 16:51:02,587 DEBUG [org.jboss.mq.il.uil2.SocketManager] End ReadTask.run
      2005-02-11 16:51:02,597 DEBUG [org.jboss.mq.il.uil2.SocketManager] End WriteTask.run
      2005-02-11 16:51:08,540 DEBUG [org.jboss.mq.il.uil2.ServerSocketManagerHandler] Exiting on IOE
      java.net.SocketException: socket closed
      at java.net.SocketInputStream.socketRead0(Native Method)
      at java.net.SocketInputStream.read(SocketInputStream.java:129)
      at java.io.BufferedInputStream.fill(BufferedInputStream.java:183)
      at java.io.BufferedInputStream.read(BufferedInputStream.java:201)
      at org.jboss.util.stream.NotifyingBufferedInputStream.read(NotifyingBufferedInputStream.java:67)
      at java.io.ObjectInputStream$PeekInputStream.peek(ObjectInputStream.java:2133)
      at java.io.ObjectInputStream$BlockDataInputStream.readBlockHeader(ObjectInputStream.java:2313)
      at java.io.ObjectInputStream$BlockDataInputStream.refill(ObjectInputStream.java:2380)
      at java.io.ObjectInputStream$BlockDataInputStream.read(ObjectInputStream.java:2452)
      at java.io.ObjectInputStream$BlockDataInputStream.readByte(ObjectInputStream.java:2601)
      at java.io.ObjectInputStream.readByte(ObjectInputStream.java:845)
      at org.jboss.mq.il.uil2.SocketManager$ReadTask.run(SocketManager.java:281)
      at java.lang.Thread.run(Thread.java:534)
      2005-02-11 16:51:08,550 DEBUG [org.jboss.mq.il.uil2.SocketManager] End WriteTask.run
      2005-02-11 16:51:08,550 DEBUG [org.jboss.mq.il.uil2.SocketManager] End ReadTask.run

      Please advise.

        • 1. Re: Unable to get Topics to participate in transaction
          Clive Hill Newbie

          I'm making progress.
          If I refer to WebLogic JMS then I see that the XA resource used is : weblogic.transaction.internal.ClientTransactionManagerImpl$ClientTMXAResource

          And this class creates it?s own weblogic.transaction.internal.XidImpl class to pass to the server.



          In JBoss, your XA resource is an org.jboss.mq.SpyXAResource, and this just passes on the Xid object it gets

          which is why my app's own Xid class is passed to the JBoss server and a failure occurs.