0 Replies Latest reply on Mar 14, 2002 3:25 AM by Matthias Lakämper

    Problem with JBossMQ JDBC-Persistence Manager

    Matthias Lakämper Newbie

      Hi,

      i want to use the JDBC-Persistence-Manager for JMS. The Tables TABLE JMS_MESSAGES and
      TABLE JMS_TRANSACTIONS are created on the DB-Server.

      The Messages are Generated with a
      Stateless-Session-Bean which has the TransactionType container.
      JBoss-Server-Version: JBoss-2.4.4.

      In JBoss.jcml i have set the following:

      <!-- The PersistenceManager is used to store messages to disk. -->

      java:/DefaultDS


      <!-- For Message Driven Beans -->

      DefaultJMSProvider
      org.jboss.jms.jndi.JBossMQProvider
      java:/XAConnectionFactory
      java:/XAConnectionFactory


      When i send a Message with the Stateless-Session-Bean the JBoss-Server shows the Following Messages.

      //----------------------------------Messages-----------------------------------------------------------------------------
      [INFO,Default] Sending message My Message !
      [INFO,JmsXA] FINE: Closing session
      [INFO,JmsXA] FINE: Sending connection event: 1
      [WARN,TxCapsule] XAException: tx=XidImpl [FormatId=257, GlobalId=pcdv007//1, BranchQual=] errorCode=XAER_RMERR
      javax.transaction.xa.XAException
      at org.jboss.mq.SpyXAResource.commit(SpyXAResource.java:102)
      at org.jboss.tm.TxCapsule.commitResources(TxCapsule.java:1490)
      at org.jboss.tm.TxCapsule.commit(TxCapsule.java:324)
      at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:76)
      at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:406)
      at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:100)
      at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:127)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:170)
      at org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.java:286)
      at org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invoke(JRMPContainerInvoker.java:410)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
      at sun.rmi.transport.Transport$1.run(Transport.java:148)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
      at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
      at java.lang.Thread.run(Thread.java:536)
      //----------------------------------Messages-----------------------------------------------------------------------------


      The same error is produced when i use the RMIXAConnectionFactory.

      When i use XAConnectionFactory (OIL. Supports XA transaction) i receive the following Messages:

      //----------------------------------Messages-----------------------------------------------------------------------------
      [INFO,Default] SendToQueueBean start von SendMessage !
      [INFO,JmsLogger] FINE: created connection: org.jboss.mq.SpyXAConnection@6d3536
      [INFO,JmsLogger] FINE: xaQueueSession: org.jboss.mq.SpyQueueSession@6b9e62
      [INFO,JmsLogger] FINE: queueSession: org.jboss.mq.SpyQueueSession@6b9e62
      [INFO,JmsLogger] FINE: transacted: true
      [INFO,JmsLogger] FINE: ack mode: 1
      [INFO,JmsXA] FINE: Setting LogWriter: org.jboss.logging.log4j.CategoryWriter@295fe8
      [INFO,JmsXA] FINE: Leaving out XAResource
      [INFO,JmsXA] FINE: ConnectionEvent listener added
      [INFO,Default] Sending message Nasenbõr !
      [INFO,JmsXA] FINE: Closing session
      [INFO,JmsXA] FINE: Sending connection event: 1
      [INFO,OILServerILService] Client request resulted in a server exception:
      java.lang.NullPointerException
      at org.jboss.mq.server.JMSServer.transact(JMSServer.java:298)
      at org.jboss.mq.il.oil.OILServerILService.run(OILServerILService.java:295)
      at java.lang.Thread.run(Thread.java:536)
      [WARN,TxCapsule] XAException: tx=XidImpl [FormatId=257, GlobalId=pcdv007//1, BranchQual=] errorCode=XAER_RMERR
      javax.transaction.xa.XAException
      at org.jboss.mq.SpyXAResource.commit(SpyXAResource.java:102)
      at org.jboss.tm.TxCapsule.commitResources(TxCapsule.java:1490)
      at org.jboss.tm.TxCapsule.commit(TxCapsule.java:324)
      at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:76)
      at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:406)
      at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:100)
      at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:127)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:170)
      at org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.java:286)
      at org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invoke(JRMPContainerInvoker.java:410)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
      at sun.rmi.transport.Transport$1.run(Transport.java:148)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
      at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
      at java.lang.Thread.run(Thread.java:536)

      //----------------------------------Messages-----------------------------------------------------------------------------


      I would be glad to get Help on this Problem.

      Regards Matthias