1 Reply Latest reply on Aug 21, 2008 6:50 AM by XX XX

    XAException javax.jms.IllegalStateException: The connection

    XX XX Newbie

      We're using JBoss 4.03SP1 with JBossMQ under Linux. An application with EJBs and an MDB waits for incoming messages from a queue and sends out messages on other queues and works on database's data.

      From time to time we get following warning in the log file. Currently in test environment a restart is needed for further testability.

      11:34:39,063 TRACE [TransactionImpl ] [JMS SessionPool Worker-0] Committing resource org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource@9d3079 state=5
      11:34:39,067 TRACE [TransactionImpl ] [JMS SessionPool Worker-0] Committing resource SpyXAResource[session=SpySession@10724997[tx=true txid=null XA RUNNING CLOSED connection=Connection@2555167[token=ConnectionToken:ID:188/ac387145ff7cf1a282110c035c3461ef CLOSED rcvstate=STOPPED]]] state=5
      11:34:39,067 TRACE [SpyXAResource ] [JMS SessionPool Worker-0] Commit xid=XidImpl[FormatId=257, GlobalId=batchfb01/36634, BranchQual=2, localId=36634], onePhase=false SpyXAResource[session=SpySession@10724997[tx=true txid=null XA RUNNING CLOSED connection=Connection@2555167[token=ConnectionToken:ID:188/ac387145ff7cf1a282110c035c3461ef CLOSED rcvstate=STOPPED]]]
      11:34:39,067 WARN [TransactionImpl ] [JMS SessionPool Worker-0] XAException: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=batchfb01/36634, BranchQual=, localId=36634] errorCode=XAER_RMERR
      org.jboss.mq.SpyXAException: - nested throwable: (javax.jms.IllegalStateException: The connection is closed)
       at org.jboss.mq.SpyXAResource.commit(SpyXAResource.java:87)
       at org.jboss.tm.TransactionImpl$Resource.commit(TransactionImpl.java:2233)
       at org.jboss.tm.TransactionImpl.commitResources(TransactionImpl.java:1764)
       at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:340)
       at org.jboss.ejb.plugins.TxInterceptorCMT.endTransaction(TxInterceptorCMT.java:486)
       at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:396)
       at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:166)
       at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:153)
       at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:192)
       at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
       at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:624)
       at org.jboss.ejb.Container.invoke(Container.java:873)
       at org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invoke(BaseLocalProxyFactory.java:415)
       at org.jboss.ejb.plugins.local.StatelessSessionProxy.invoke(StatelessSessionProxy.java:88)
       at $Proxy54.start(Unknown Source)
       at com.company.ejb.ReceiverMdb.process(ReceiverMdb.java:190)
       at com.company.ejb.ReceiverMdb.onMessage(ReceiverMdb.java:130)
       at sun.reflect.GeneratedMethodAccessor239.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:585)
       at org.jboss.invocation.Invocation.performCall(Invocation.java:345)
       at org.jboss.ejb.MessageDrivenContainer$ContainerInterceptor.invoke(MessageDrivenContainer.java:475)
       at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:149)
       at org.jboss.ejb.plugins.MessageDrivenInstanceInterceptor.invoke(MessageDrivenInstanceInterceptor.java:101)
       at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:48)
       at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:106)
       at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:335)
       at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:166)
       at org.jboss.ejb.plugins.RunAsSecurityInterceptor.invoke(RunAsSecurityInterceptor.java:94)
       at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:192)
       at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
       at org.jboss.ejb.MessageDrivenContainer.internalInvoke(MessageDrivenContainer.java:389)
       at org.jboss.ejb.Container.invoke(Container.java:873)
       at org.jboss.ejb.plugins.jms.JMSContainerInvoker.invoke(JMSContainerInvoker.java:1077)
       at org.jboss.ejb.plugins.jms.JMSContainerInvoker$MessageListenerImpl.onMessage(JMSContainerInvoker.java:1379)
       at org.jboss.jms.asf.StdServerSession.onMessage(StdServerSession.java:256)
       at org.jboss.mq.SpyMessageConsumer.sessionConsumerProcessMessage(SpyMessageConsumer.java:904)
       at org.jboss.mq.SpyMessageConsumer.addMessage(SpyMessageConsumer.java:160)
       at org.jboss.mq.SpySession.run(SpySession.java:333)
       at org.jboss.jms.asf.StdServerSession.run(StdServerSession.java:180)
       at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:748)
       at java.lang.Thread.run(Thread.java:595)
      Caused by: javax.jms.IllegalStateException: The connection is closed
       at org.jboss.mq.Connection.send(Connection.java:1156)
       at org.jboss.mq.SpyXAResourceManager.commit(SpyXAResourceManager.java:158)
       at org.jboss.mq.SpyXAResource.commit(SpyXAResource.java:83)
       ... 43 more
      11:34:39,068 TRACE [TransactionImpl ] [JMS SessionPool Worker-0] Committed OK, tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=batchfb01/36634, BranchQual=, localId=36634]
      11:34:39,069 TRACE [StdServerSession ] [JMS SessionPool Worker-0] Commiting the JMS transaction
      11:34:39,069 TRACE [TransactionImpl ] [JMS SessionPool Worker-0] Committing, tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=batchfb01/36633, BranchQual=, localId=36633], status=STATUS_ACTIVE
      


      What causes this exception and how severe is it?