Uploaded image for project: 'OpenNMS'
  1. OpenNMS
  2. NMS-8714

Minion code throws "javax.jms.IllegalStateException: The Session is closed"

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 19.0.0
    • Fix Version/s: 19.0.0
    • Component/s: Architecture
    • Security Level: Default (Default Security Scheme)
    • Labels:
      None
    • Sprint:
      Horizon - Nov 30th

      Description

      If you restart OpenNMS while a Minion is attached to it, some of the Minion JMS connections appear to get into an exception state where they throw the following exception during each attempt to send a message once connectivity to OpenNMS is restored:

      016-09-06 14:43:10,256 | WARN  | da://sendMessage | SedaConsumer                     | 63 - org.apache.camel.camel-core - 2.14.1 | Error processing exchange. Exchange[Message: <syslogConnection bytes="XXXXXXXX" location="Home" port="42048" sourceAddress="127.0.0.1" systemId="0d2bc434-4533-11e6-ab01-000c2912c632"/>]. Caused by: [org.springframework.jms.IllegalStateException - The Session is closed; nested exception is javax.jms.IllegalStateException: The Session is closed]
      org.springframework.jms.IllegalStateException: The Session is closed; nested exception is javax.jms.IllegalStateException: The Session is closed
              at org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:279)[87:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
              at org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:168)[87:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
              at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:469)[87:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
              at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate.send(JmsConfiguration.java:228)[65:org.apache.camel.camel-jms:2.14.1]
              at org.apache.camel.component.jms.JmsProducer.doSend(JmsProducer.java:431)[65:org.apache.camel.camel-jms:2.14.1]
              at org.apache.camel.component.jms.JmsProducer.processInOnly(JmsProducer.java:385)[65:org.apache.camel.camel-jms:2.14.1]
              at org.apache.camel.component.jms.JmsProducer.process(JmsProducer.java:153)[65:org.apache.camel.camel-jms:2.14.1]
              at org.apache.camel.processor.SendProcessor.process(SendProcessor.java:120)[63:org.apache.camel.camel-core:2.14.1]
              at org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:72)[63:org.apache.camel.camel-core:2.14.1]
              at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:416)[63:org.apache.camel.camel-core:2.14.1]
              at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[63:org.apache.camel.camel-core:2.14.1]
              at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[63:org.apache.camel.camel-core:2.14.1]
              at org.apache.camel.component.seda.SedaConsumer.sendToConsumers(SedaConsumer.java:291)[63:org.apache.camel.camel-core:2.14.1]
              at org.apache.camel.component.seda.SedaConsumer.doRun(SedaConsumer.java:200)[63:org.apache.camel.camel-core:2.14.1]
              at org.apache.camel.component.seda.SedaConsumer.run(SedaConsumer.java:147)[63:org.apache.camel.camel-core:2.14.1]
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_60]
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_60]
              at java.lang.Thread.run(Thread.java:745)[:1.8.0_60]
      Caused by: javax.jms.IllegalStateException: The Session is closed
              at org.apache.activemq.ActiveMQSession.checkClosed(ActiveMQSession.java:767)[61:org.apache.activemq.activemq-osgi:5.10.0]
              at org.apache.activemq.ActiveMQSession.createQueue(ActiveMQSession.java:1265)[61:org.apache.activemq.activemq-osgi:5.10.0]
              at org.apache.activemq.jms.pool.PooledSession.createQueue(PooledSession.java:194)[61:org.apache.activemq.activemq-osgi:5.10.0]
              at org.springframework.jms.support.destination.DynamicDestinationResolver.resolveQueue(DynamicDestinationResolver.java:101)[87:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
              at org.springframework.jms.support.destination.DynamicDestinationResolver.resolveDestinationName(DynamicDestinationResolver.java:66)[87:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
              at org.springframework.jms.support.destination.JmsDestinationAccessor.resolveDestinationName(JmsDestinationAccessor.java:100)[87:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
              at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate.access$000(JmsConfiguration.java:217)[65:org.apache.camel.camel-jms:2.14.1]
              at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate$1.doInJms(JmsConfiguration.java:230)[65:org.apache.camel.camel-jms:2.14.1]
              at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:466)[87:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
              ... 15 more
      

      I think that we need to change the connection pool and/or Camel producer configuration so that it refreshes the connection if a JMS error occurs.

      We should probably, if possible, write a Minion system test that exercises this scenario as well.

        Issue Links

          Activity

          Hide
          j-white Jesse White added a comment -

          Fixed in develop with 9331b0f0a62797a47dc506ab24c9b973fbb870dd.

          Show
          j-white Jesse White added a comment - Fixed in develop with 9331b0f0a62797a47dc506ab24c9b973fbb870dd.
          Hide
          j-white Jesse White added a comment -

          I hit this again with one of the latest builds.

          Show
          j-white Jesse White added a comment - I hit this again with one of the latest builds.
          Hide
          j-white Jesse White added a comment -

          I updated the Minion's queueingservice to use the custom pool with the backported bug fix in d143dc9cc4cf9386bcd2ea42877ac35e003afc9c and to use the failover protocol by default in 93b51d83dd1278fb0041d83cacb7486eabde4e06.

          This appears to solve the issue. Re-resolving.

          Show
          j-white Jesse White added a comment - I updated the Minion's queueingservice to use the custom pool with the backported bug fix in d143dc9cc4cf9386bcd2ea42877ac35e003afc9c and to use the failover protocol by default in 93b51d83dd1278fb0041d83cacb7486eabde4e06 . This appears to solve the issue. Re-resolving.
          Hide
          seth Seth Leger added a comment -

          A user is still reporting "Session is closed" exceptions in the sink code in the Minion logs with the Jan 13 build of release-19.0.0. They also report that heartbeat timestamps are updating in the UI but it's not clear if they are 100% reliable.

          2017-01-18 09:05:12,366 | ERROR | Timer-2          | DefaultErrorHandler              | 82 - org.apache.camel.camel-core - 2.14.1 | Failed delivery for (MessageId: ID-localhost-localdomain-57139-1484544071302-0-15745 on ExchangeId: ID-localhost-localdomain-57139-1484544071302-0-15747). Exhausted after delivery attempt: 1 caught: org.springframework.jms.IllegalStateException: The Session is closed; nested exception is javax.jms.IllegalStateException: The Session is closed
          
          org.springframework.jms.IllegalStateException: The Session is closed; nested exception is javax.jms.IllegalStateException: The Session is closed
                  at org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:279)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
                  at org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:168)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
                  at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:469)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
                  at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate.send(JmsConfiguration.java:228)[85:org.apache.camel.camel-jms:2.14.1]
                  at org.apache.camel.component.jms.JmsProducer.doSend(JmsProducer.java:431)[85:org.apache.camel.camel-jms:2.14.1]
                  at org.apache.camel.component.jms.JmsProducer.processInOnly(JmsProducer.java:385)[85:org.apache.camel.camel-jms:2.14.1]
                  at org.apache.camel.component.jms.JmsProducer.process(JmsProducer.java:153)[85:org.apache.camel.camel-jms:2.14.1]
                  at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:416)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.MulticastProcessor.doProcessSequential(MulticastProcessor.java:586)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.MulticastProcessor.doProcessSequential(MulticastProcessor.java:514)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.MulticastProcessor.process(MulticastProcessor.java:226)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.RecipientList.sendToRecipientList(RecipientList.java:167)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.RecipientList.process(RecipientList.java:120)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:72)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:416)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.component.direct.DirectProducer.process(DirectProducer.java:51)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.processor.UnitOfWorkProducer.process(UnitOfWorkProducer.java:74)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.ProducerCache$2.doInProducer(ProducerCache.java:375)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.ProducerCache$2.doInProducer(ProducerCache.java:343)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.ProducerCache.doInProducer(ProducerCache.java:233)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.ProducerCache.sendExchange(ProducerCache.java:343)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.ProducerCache.send(ProducerCache.java:184)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.DefaultProducerTemplate.send(DefaultProducerTemplate.java:124)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.DefaultProducerTemplate.sendBodyAndHeaders(DefaultProducerTemplate.java:233)[82:org.apache.camel.camel-core:2.14.1]
                  at org.opennms.core.ipc.sink.camel.CamelRemoteMessageDispatcherFactory.dispatch(CamelRemoteMessageDispatcherFactory.java:71)[196:org.opennms.core.ipc.sink.camel-impl:19.0.0.SNAPSHOT]
                  at org.opennms.core.ipc.sink.camel.CamelRemoteMessageDispatcherFactory.dispatch(CamelRemoteMessageDispatcherFactory.java:50)[196:org.opennms.core.ipc.sink.camel-impl:19.0.0.SNAPSHOT]
                  at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory.timedDispatch(AbstractMessageDispatcherFactory.java:66)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT]
                  at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory.access$000(AbstractMessageDispatcherFactory.java:55)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT]
                  at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory$DirectDispatcher.send(AbstractMessageDispatcherFactory.java:133)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT]
                  at org.opennms.minion.heartbeat.producer.HeartbeatProducer$1.run(HeartbeatProducer.java:60)[220:org.opennms.features.minion.heartbeat.producer:19.0.0.SNAPSHOT]
                  at java.util.TimerThread.mainLoop(Timer.java:555)[:1.8.0_60]
                  at java.util.TimerThread.run(Timer.java:505)[:1.8.0_60]
          Caused by: javax.jms.IllegalStateException: The Session is closed
                  at org.apache.activemq.ActiveMQSession.checkClosed(ActiveMQSession.java:767)[79:org.apache.activemq.activemq-osgi:5.10.0]
                  at org.apache.activemq.ActiveMQSession.createQueue(ActiveMQSession.java:1265)[79:org.apache.activemq.activemq-osgi:5.10.0]
                  at org.apache.activemq.jms.pool.PooledSession.createQueue(PooledSession.java:194)[79:org.apache.activemq.activemq-osgi:5.10.0]
                  at org.springframework.jms.support.destination.DynamicDestinationResolver.resolveQueue(DynamicDestinationResolver.java:101)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
                  at org.springframework.jms.support.destination.DynamicDestinationResolver.resolveDestinationName(DynamicDestinationResolver.java:66)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
                  at org.springframework.jms.support.destination.JmsDestinationAccessor.resolveDestinationName(JmsDestinationAccessor.java:100)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
                  at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate.access$000(JmsConfiguration.java:217)[85:org.apache.camel.camel-jms:2.14.1]
                  at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate$1.doInJms(JmsConfiguration.java:230)[85:org.apache.camel.camel-jms:2.14.1]
                  at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:466)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1]
                  ... 37 more
          2017-01-18 09:05:12,366 | ERROR | Timer-2          | HeartbeatProducer                | 220 - org.opennms.features.minion.heartbeat.producer - 19.0.0.SNAPSHOT | An error occured while sending the heartbeat. Will try again in 30000 ms
          org.apache.camel.TypeConversionException: Error during type conversion from type: java.lang.String to the required type: java.lang.Integer with value ${body.debug} due java.lang.NumberFormatException: For input string: "${body.debug}"
                  at org.apache.camel.impl.converter.BaseTypeConverterRegistry.createTypeConversionException(BaseTypeConverterRegistry.java:567)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.converter.BaseTypeConverterRegistry.convertTo(BaseTypeConverterRegistry.java:131)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.converter.BaseTypeConverterRegistry.convertTo(BaseTypeConverterRegistry.java:99)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.core.osgi.OsgiTypeConverter.convertTo(OsgiTypeConverter.java:111)[81:org.apache.camel.camel-blueprint:2.14.1]
                  at org.apache.camel.util.MessageHelper.extractBodyForLogging(MessageHelper.java:214)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.util.MessageHelper.extractBodyForLogging(MessageHelper.java:152)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.DefaultMessage.toString(DefaultMessage.java:46)[82:org.apache.camel.camel-core:2.14.1]
                  at java.lang.String.valueOf(String.java:2994)[:1.8.0_60]
                  at java.lang.StringBuilder.append(StringBuilder.java:131)[:1.8.0_60]
                  at org.apache.camel.impl.DefaultExchange.toString(DefaultExchange.java:81)[82:org.apache.camel.camel-core:2.14.1]
                  at java.lang.String.valueOf(String.java:2994)[:1.8.0_60]
                  at java.lang.StringBuilder.append(StringBuilder.java:131)[:1.8.0_60]
                  at org.apache.camel.RuntimeExchangeException.createMessage(RuntimeExchangeException.java:49)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.RuntimeExchangeException.<init>(RuntimeExchangeException.java:34)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.CamelExecutionException.<init>(CamelExecutionException.java:35)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.util.ObjectHelper.wrapCamelExecutionException(ObjectHelper.java:1380)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.util.ExchangeHelper.extractResultBody(ExchangeHelper.java:623)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.DefaultProducerTemplate.extractResultBody(DefaultProducerTemplate.java:471)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.DefaultProducerTemplate.extractResultBody(DefaultProducerTemplate.java:467)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.DefaultProducerTemplate.sendBodyAndHeaders(DefaultProducerTemplate.java:245)[82:org.apache.camel.camel-core:2.14.1]
                  at org.opennms.core.ipc.sink.camel.CamelRemoteMessageDispatcherFactory.dispatch(CamelRemoteMessageDispatcherFactory.java:71)[196:org.opennms.core.ipc.sink.camel-impl:19.0.0.SNAPSHOT]
                  at org.opennms.core.ipc.sink.camel.CamelRemoteMessageDispatcherFactory.dispatch(CamelRemoteMessageDispatcherFactory.java:50)[196:org.opennms.core.ipc.sink.camel-impl:19.0.0.SNAPSHOT]
                  at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory.timedDispatch(AbstractMessageDispatcherFactory.java:66)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT]
                  at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory.access$000(AbstractMessageDispatcherFactory.java:55)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT]
                  at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory$DirectDispatcher.send(AbstractMessageDispatcherFactory.java:133)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT]
                  at org.opennms.minion.heartbeat.producer.HeartbeatProducer$1.run(HeartbeatProducer.java:60)[220:org.opennms.features.minion.heartbeat.producer:19.0.0.SNAPSHOT]
                  at java.util.TimerThread.mainLoop(Timer.java:555)[:1.8.0_60]
                  at java.util.TimerThread.run(Timer.java:505)[:1.8.0_60]
          Caused by: org.apache.camel.RuntimeCamelException: java.lang.NumberFormatException: For input string: "${body.debug}"
                  at org.apache.camel.util.ObjectHelper.wrapRuntimeCamelException(ObjectHelper.java:1364)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.util.ObjectHelper.invokeMethod(ObjectHelper.java:1006)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.converter.StaticMethodTypeConverter.convertTo(StaticMethodTypeConverter.java:59)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.converter.BaseTypeConverterRegistry.doConvertTo(BaseTypeConverterRegistry.java:276)[82:org.apache.camel.camel-core:2.14.1]
                  at org.apache.camel.impl.converter.BaseTypeConverterRegistry.convertTo(BaseTypeConverterRegistry.java:114)[82:org.apache.camel.camel-core:2.14.1]
                  ... 26 more
          Caused by: java.lang.NumberFormatException: For input string: "${body.debug}"
                  at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)[:1.8.0_60]
                  at java.lang.Integer.parseInt(Integer.java:569)[:1.8.0_60]
                  at java.lang.Integer.valueOf(Integer.java:766)[:1.8.0_60]
                  at org.apache.camel.converter.ObjectConverter.toInteger(ObjectConverter.java:250)
                  at sun.reflect.GeneratedMethodAccessor35.invoke(Unknown Source)
                  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.8.0_60]
                  at java.lang.reflect.Method.invoke(Method.java:497)[:1.8.0_60]
                  at org.apache.camel.util.ObjectHelper.invokeMethod(ObjectHelper.java:1002)[82:org.apache.camel.camel-core:2.14.1]
                  ... 29 more
          
          Show
          seth Seth Leger added a comment - A user is still reporting "Session is closed" exceptions in the sink code in the Minion logs with the Jan 13 build of release-19.0.0. They also report that heartbeat timestamps are updating in the UI but it's not clear if they are 100% reliable. 2017-01-18 09:05:12,366 | ERROR | Timer-2 | DefaultErrorHandler | 82 - org.apache.camel.camel-core - 2.14.1 | Failed delivery for (MessageId: ID-localhost-localdomain-57139-1484544071302-0-15745 on ExchangeId: ID-localhost-localdomain-57139-1484544071302-0-15747). Exhausted after delivery attempt: 1 caught: org.springframework.jms.IllegalStateException: The Session is closed; nested exception is javax.jms.IllegalStateException: The Session is closed org.springframework.jms.IllegalStateException: The Session is closed; nested exception is javax.jms.IllegalStateException: The Session is closed at org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:279)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1] at org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:168)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1] at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:469)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1] at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate.send(JmsConfiguration.java:228)[85:org.apache.camel.camel-jms:2.14.1] at org.apache.camel.component.jms.JmsProducer.doSend(JmsProducer.java:431)[85:org.apache.camel.camel-jms:2.14.1] at org.apache.camel.component.jms.JmsProducer.processInOnly(JmsProducer.java:385)[85:org.apache.camel.camel-jms:2.14.1] at org.apache.camel.component.jms.JmsProducer.process(JmsProducer.java:153)[85:org.apache.camel.camel-jms:2.14.1] at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:416)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.MulticastProcessor.doProcessSequential(MulticastProcessor.java:586)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.MulticastProcessor.doProcessSequential(MulticastProcessor.java:514)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.MulticastProcessor.process(MulticastProcessor.java:226)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.RecipientList.sendToRecipientList(RecipientList.java:167)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.RecipientList.process(RecipientList.java:120)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:72)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:416)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.component.direct.DirectProducer.process(DirectProducer.java:51)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.processor.UnitOfWorkProducer.process(UnitOfWorkProducer.java:74)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.ProducerCache$2.doInProducer(ProducerCache.java:375)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.ProducerCache$2.doInProducer(ProducerCache.java:343)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.ProducerCache.doInProducer(ProducerCache.java:233)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.ProducerCache.sendExchange(ProducerCache.java:343)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.ProducerCache.send(ProducerCache.java:184)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.DefaultProducerTemplate.send(DefaultProducerTemplate.java:124)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.DefaultProducerTemplate.sendBodyAndHeaders(DefaultProducerTemplate.java:233)[82:org.apache.camel.camel-core:2.14.1] at org.opennms.core.ipc.sink.camel.CamelRemoteMessageDispatcherFactory.dispatch(CamelRemoteMessageDispatcherFactory.java:71)[196:org.opennms.core.ipc.sink.camel-impl:19.0.0.SNAPSHOT] at org.opennms.core.ipc.sink.camel.CamelRemoteMessageDispatcherFactory.dispatch(CamelRemoteMessageDispatcherFactory.java:50)[196:org.opennms.core.ipc.sink.camel-impl:19.0.0.SNAPSHOT] at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory.timedDispatch(AbstractMessageDispatcherFactory.java:66)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT] at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory.access$000(AbstractMessageDispatcherFactory.java:55)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT] at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory$DirectDispatcher.send(AbstractMessageDispatcherFactory.java:133)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT] at org.opennms.minion.heartbeat.producer.HeartbeatProducer$1.run(HeartbeatProducer.java:60)[220:org.opennms.features.minion.heartbeat.producer:19.0.0.SNAPSHOT] at java.util.TimerThread.mainLoop(Timer.java:555)[:1.8.0_60] at java.util.TimerThread.run(Timer.java:505)[:1.8.0_60] Caused by: javax.jms.IllegalStateException: The Session is closed at org.apache.activemq.ActiveMQSession.checkClosed(ActiveMQSession.java:767)[79:org.apache.activemq.activemq-osgi:5.10.0] at org.apache.activemq.ActiveMQSession.createQueue(ActiveMQSession.java:1265)[79:org.apache.activemq.activemq-osgi:5.10.0] at org.apache.activemq.jms.pool.PooledSession.createQueue(PooledSession.java:194)[79:org.apache.activemq.activemq-osgi:5.10.0] at org.springframework.jms.support.destination.DynamicDestinationResolver.resolveQueue(DynamicDestinationResolver.java:101)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1] at org.springframework.jms.support.destination.DynamicDestinationResolver.resolveDestinationName(DynamicDestinationResolver.java:66)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1] at org.springframework.jms.support.destination.JmsDestinationAccessor.resolveDestinationName(JmsDestinationAccessor.java:100)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1] at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate.access$000(JmsConfiguration.java:217)[85:org.apache.camel.camel-jms:2.14.1] at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate$1.doInJms(JmsConfiguration.java:230)[85:org.apache.camel.camel-jms:2.14.1] at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:466)[140:org.apache.servicemix.bundles.spring-jms:3.2.14.RELEASE_1] ... 37 more 2017-01-18 09:05:12,366 | ERROR | Timer-2 | HeartbeatProducer | 220 - org.opennms.features.minion.heartbeat.producer - 19.0.0.SNAPSHOT | An error occured while sending the heartbeat. Will try again in 30000 ms org.apache.camel.TypeConversionException: Error during type conversion from type: java.lang.String to the required type: java.lang.Integer with value ${body.debug} due java.lang.NumberFormatException: For input string: "${body.debug}" at org.apache.camel.impl.converter.BaseTypeConverterRegistry.createTypeConversionException(BaseTypeConverterRegistry.java:567)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.converter.BaseTypeConverterRegistry.convertTo(BaseTypeConverterRegistry.java:131)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.converter.BaseTypeConverterRegistry.convertTo(BaseTypeConverterRegistry.java:99)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.core.osgi.OsgiTypeConverter.convertTo(OsgiTypeConverter.java:111)[81:org.apache.camel.camel-blueprint:2.14.1] at org.apache.camel.util.MessageHelper.extractBodyForLogging(MessageHelper.java:214)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.util.MessageHelper.extractBodyForLogging(MessageHelper.java:152)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.DefaultMessage.toString(DefaultMessage.java:46)[82:org.apache.camel.camel-core:2.14.1] at java.lang.String.valueOf(String.java:2994)[:1.8.0_60] at java.lang.StringBuilder.append(StringBuilder.java:131)[:1.8.0_60] at org.apache.camel.impl.DefaultExchange.toString(DefaultExchange.java:81)[82:org.apache.camel.camel-core:2.14.1] at java.lang.String.valueOf(String.java:2994)[:1.8.0_60] at java.lang.StringBuilder.append(StringBuilder.java:131)[:1.8.0_60] at org.apache.camel.RuntimeExchangeException.createMessage(RuntimeExchangeException.java:49)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.RuntimeExchangeException.<init>(RuntimeExchangeException.java:34)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.CamelExecutionException.<init>(CamelExecutionException.java:35)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.util.ObjectHelper.wrapCamelExecutionException(ObjectHelper.java:1380)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.util.ExchangeHelper.extractResultBody(ExchangeHelper.java:623)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.DefaultProducerTemplate.extractResultBody(DefaultProducerTemplate.java:471)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.DefaultProducerTemplate.extractResultBody(DefaultProducerTemplate.java:467)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.DefaultProducerTemplate.sendBodyAndHeaders(DefaultProducerTemplate.java:245)[82:org.apache.camel.camel-core:2.14.1] at org.opennms.core.ipc.sink.camel.CamelRemoteMessageDispatcherFactory.dispatch(CamelRemoteMessageDispatcherFactory.java:71)[196:org.opennms.core.ipc.sink.camel-impl:19.0.0.SNAPSHOT] at org.opennms.core.ipc.sink.camel.CamelRemoteMessageDispatcherFactory.dispatch(CamelRemoteMessageDispatcherFactory.java:50)[196:org.opennms.core.ipc.sink.camel-impl:19.0.0.SNAPSHOT] at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory.timedDispatch(AbstractMessageDispatcherFactory.java:66)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT] at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory.access$000(AbstractMessageDispatcherFactory.java:55)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT] at org.opennms.core.ipc.sink.common.AbstractMessageDispatcherFactory$DirectDispatcher.send(AbstractMessageDispatcherFactory.java:133)[197:org.opennms.core.ipc.sink.common:19.0.0.SNAPSHOT] at org.opennms.minion.heartbeat.producer.HeartbeatProducer$1.run(HeartbeatProducer.java:60)[220:org.opennms.features.minion.heartbeat.producer:19.0.0.SNAPSHOT] at java.util.TimerThread.mainLoop(Timer.java:555)[:1.8.0_60] at java.util.TimerThread.run(Timer.java:505)[:1.8.0_60] Caused by: org.apache.camel.RuntimeCamelException: java.lang.NumberFormatException: For input string: "${body.debug}" at org.apache.camel.util.ObjectHelper.wrapRuntimeCamelException(ObjectHelper.java:1364)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.util.ObjectHelper.invokeMethod(ObjectHelper.java:1006)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.converter.StaticMethodTypeConverter.convertTo(StaticMethodTypeConverter.java:59)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.converter.BaseTypeConverterRegistry.doConvertTo(BaseTypeConverterRegistry.java:276)[82:org.apache.camel.camel-core:2.14.1] at org.apache.camel.impl.converter.BaseTypeConverterRegistry.convertTo(BaseTypeConverterRegistry.java:114)[82:org.apache.camel.camel-core:2.14.1] ... 26 more Caused by: java.lang.NumberFormatException: For input string: "${body.debug}" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)[:1.8.0_60] at java.lang.Integer.parseInt(Integer.java:569)[:1.8.0_60] at java.lang.Integer.valueOf(Integer.java:766)[:1.8.0_60] at org.apache.camel.converter.ObjectConverter.toInteger(ObjectConverter.java:250) at sun.reflect.GeneratedMethodAccessor35.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.8.0_60] at java.lang.reflect.Method.invoke(Method.java:497)[:1.8.0_60] at org.apache.camel.util.ObjectHelper.invokeMethod(ObjectHelper.java:1002)[82:org.apache.camel.camel-core:2.14.1] ... 29 more
          Hide
          seth Seth Leger added a comment -

          A system test for this condition was added as part of work on NMS-9225.

          Show
          seth Seth Leger added a comment - A system test for this condition was added as part of work on NMS-9225 .

            People

            • Assignee:
              j-white Jesse White
              Reporter:
              seth Seth Leger
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development

                  Agile