javax.jms.JMSException: Already closed

Spring JIRA | Eugene Prokopiev | 1 decade ago
  1. 0

    SPR-2461 must be reopened. All works with default DefaultMessageListenerContainer.cacheLevel=CACHE_SESSION but thre are some errors with other cacheLevel values. In the same configuration described in SPR-2461 I got: with CACHE_CONNECTION on starting context: ERROR DefaultMessageListenerContainer - Setup of JMS message listener invoker failed - trying to recover javax.jms.JMSException: Already closed at org.jencks.pool.PooledSpringXAConnection.getConnection(PooledSpringXAConnection.java:284) at org.jencks.pool.PooledSpringXAConnection.start(PooledSpringXAConnection.java:95) at org.springframework.jms.connection.ConnectionFactoryUtils.doGetTransactionalSession(ConnectionFactoryUtils.java:195) at org.springframework.jms.listener.DefaultMessageListenerContainer.doReceiveAndExecute(DefaultMessageListenerContainer.java:483) at org.springframework.jms.listener.DefaultMessageListenerContainer.receiveAndExecute(DefaultMessageListenerContainer.java:441) at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:859) at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:818) at org.springframework.core.task.SimpleAsyncTaskExecutor$ConcurrencyThrottlingRunnable.run(SimpleAsyncTaskExecutor.java:203) at java.lang.Thread.run(Thread.java:595) INFO DefaultMessageListenerContainer - Successfully refreshed JMS Connection with CACHE_SESSION and CACHE_CONSUMER on receiving message: ERROR DefaultMessageListenerContainer - Setup of JMS message listener invoker failed - trying to recover javax.jms.JMSException: Session's XAResource has not been enlisted in a distributed transaction. at org.apache.activemq.ActiveMQXASession.doStartTransaction(ActiveMQXASession.java:109) at org.apache.activemq.ActiveMQMessageConsumer.ackLater(ActiveMQMessageConsumer.java:658) at org.apache.activemq.ActiveMQMessageConsumer.beforeMessageIsConsumed(ActiveMQMessageConsumer.java:610) at org.apache.activemq.ActiveMQMessageConsumer.receive(ActiveMQMessageConsumer.java:469) at org.springframework.jms.listener.DefaultMessageListenerContainer.receiveMessage(DefaultMessageListenerContainer.java:560) at org.springframework.jms.listener.DefaultMessageListenerContainer.doReceiveAndExecute(DefaultMessageListenerContainer.java:505) at org.springframework.jms.listener.DefaultMessageListenerContainer.receiveAndExecute(DefaultMessageListenerContainer.java:441) at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:859) at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:818) at org.springframework.core.task.SimpleAsyncTaskExecutor$ConcurrencyThrottlingRunnable.run(SimpleAsyncTaskExecutor.java:203) at java.lang.Thread.run(Thread.java:595) INFO DefaultMessageListenerContainer - Successfully refreshed JMS Connection

    Spring JIRA | 1 decade ago | Eugene Prokopiev
    javax.jms.JMSException: Already closed
  2. 0

    SPR-2461 must be reopened. All works with default DefaultMessageListenerContainer.cacheLevel=CACHE_SESSION but thre are some errors with other cacheLevel values. In the same configuration described in SPR-2461 I got: with CACHE_CONNECTION on starting context: ERROR DefaultMessageListenerContainer - Setup of JMS message listener invoker failed - trying to recover javax.jms.JMSException: Already closed at org.jencks.pool.PooledSpringXAConnection.getConnection(PooledSpringXAConnection.java:284) at org.jencks.pool.PooledSpringXAConnection.start(PooledSpringXAConnection.java:95) at org.springframework.jms.connection.ConnectionFactoryUtils.doGetTransactionalSession(ConnectionFactoryUtils.java:195) at org.springframework.jms.listener.DefaultMessageListenerContainer.doReceiveAndExecute(DefaultMessageListenerContainer.java:483) at org.springframework.jms.listener.DefaultMessageListenerContainer.receiveAndExecute(DefaultMessageListenerContainer.java:441) at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:859) at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:818) at org.springframework.core.task.SimpleAsyncTaskExecutor$ConcurrencyThrottlingRunnable.run(SimpleAsyncTaskExecutor.java:203) at java.lang.Thread.run(Thread.java:595) INFO DefaultMessageListenerContainer - Successfully refreshed JMS Connection with CACHE_SESSION and CACHE_CONSUMER on receiving message: ERROR DefaultMessageListenerContainer - Setup of JMS message listener invoker failed - trying to recover javax.jms.JMSException: Session's XAResource has not been enlisted in a distributed transaction. at org.apache.activemq.ActiveMQXASession.doStartTransaction(ActiveMQXASession.java:109) at org.apache.activemq.ActiveMQMessageConsumer.ackLater(ActiveMQMessageConsumer.java:658) at org.apache.activemq.ActiveMQMessageConsumer.beforeMessageIsConsumed(ActiveMQMessageConsumer.java:610) at org.apache.activemq.ActiveMQMessageConsumer.receive(ActiveMQMessageConsumer.java:469) at org.springframework.jms.listener.DefaultMessageListenerContainer.receiveMessage(DefaultMessageListenerContainer.java:560) at org.springframework.jms.listener.DefaultMessageListenerContainer.doReceiveAndExecute(DefaultMessageListenerContainer.java:505) at org.springframework.jms.listener.DefaultMessageListenerContainer.receiveAndExecute(DefaultMessageListenerContainer.java:441) at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:859) at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:818) at org.springframework.core.task.SimpleAsyncTaskExecutor$ConcurrencyThrottlingRunnable.run(SimpleAsyncTaskExecutor.java:203) at java.lang.Thread.run(Thread.java:595) INFO DefaultMessageListenerContainer - Successfully refreshed JMS Connection

    Spring JIRA | 1 decade ago | Eugene Prokopiev
    javax.jms.JMSException: Already closed
  3. 0

    java.activemq.user - Re: Jmeter tests - I don't get it - msg#00205 - Recent Discussion OSDir.com

    osdir.com | 4 months ago
    javax.jms.JMSException: Cannot write to the stream any more it has already been closed
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    java.activemq.user - Re: Jmeter tests - I don't get it - msg#00205 - Recent Discussion OSDir.com

    osdir.com | 4 months ago
    javax.jms.JMSException: Cannot write to the stream any more it has already been closed
  6. 0

    WL Client died

    Oracle Community | 2 decades ago | 3004
    javax.jms.JMSException: Consumer closed

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. javax.jms.JMSException

      Already closed

      at org.jencks.pool.PooledSpringXAConnection.getConnection()
    2. Jencks
      PooledSpringXAConnection.start
      1. org.jencks.pool.PooledSpringXAConnection.getConnection(PooledSpringXAConnection.java:284)
      2. org.jencks.pool.PooledSpringXAConnection.start(PooledSpringXAConnection.java:95)
      2 frames
    3. Spring Framework
      DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run
      1. org.springframework.jms.connection.ConnectionFactoryUtils.doGetTransactionalSession(ConnectionFactoryUtils.java:195)
      2. org.springframework.jms.listener.DefaultMessageListenerContainer.doReceiveAndExecute(DefaultMessageListenerContainer.java:483)
      3. org.springframework.jms.listener.DefaultMessageListenerContainer.receiveAndExecute(DefaultMessageListenerContainer.java:441)
      4. org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:859)
      5. org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:818)
      5 frames
    4. Spring Core
      SimpleAsyncTaskExecutor$ConcurrencyThrottlingRunnable.run
      1. org.springframework.core.task.SimpleAsyncTaskExecutor$ConcurrencyThrottlingRunnable.run(SimpleAsyncTaskExecutor.java:203)
      1 frame
    5. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:595)
      1 frame