3 Replies Latest reply on Aug 12, 2016 10:29 AM by Miroslav Novak

    ActiveMQ RAR XA -  java.io.IOException: Transport scheme NOT recognized: [tcp]

    Matt Madhavan Newbie

      Hello,

      I am having a real hard time having ActiveMQ connection factory working as part of the XA Transaction. I have configured ActiveMQ as a Wildfly xa resource and I can see that it is configured ok both in the log and in the tweek web console.

       

      But when I try to use it as part of a Camel route I am getting the following issue  -  Been stuck on this for a while. Any ideas please?

       

      Thanks

      Matt

       

      Caused by: javax.jms.JMSException: Could not create Transport. Reason: java.io.IOException: Transport scheme NOT recognized: [tcp]

        at org.apache.activemq.util.JMSExceptionSupport.create(JMSExceptionSupport.java:36) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ActiveMQConnectionFactory.createTransport(ActiveMQConnectionFactory.java:317) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ActiveMQConnectionFactory.createActiveMQConnection(ActiveMQConnectionFactory.java:330) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ActiveMQConnectionFactory.createConnection(ActiveMQConnectionFactory.java:251) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ra.ActiveMQConnectionSupport.makeConnection(ActiveMQConnectionSupport.java:79)

        at org.apache.activemq.ra.ActiveMQConnectionSupport.makeConnection(ActiveMQConnectionSupport.java:61)

        at org.apache.activemq.ra.ActiveMQManagedConnectionFactory.createManagedConnection(ActiveMQManagedConnectionFactory.java:188)

        ... 16 more

      Caused by: java.io.IOException: Transport scheme NOT recognized: [tcp]

        at org.apache.activemq.util.IOExceptionSupport.create(IOExceptionSupport.java:27) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.transport.TransportFactory.findTransportFactory(TransportFactory.java:181) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.transport.TransportFactory.connect(TransportFactory.java:63) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ActiveMQConnectionFactory.createTransport(ActiveMQConnectionFactory.java:315) [activemq-client-5.10.0.jar:5.10.0]

        ... 21 more

      Caused by: java.lang.ClassCastException: org.apache.activemq.transport.tcp.TcpTransportFactory cannot be cast to org.apache.activemq.transport.TransportFactory

        at org.apache.activemq.transport.TransportFactory.findTransportFactory(TransportFactory.java:178) [activemq-client-5.10.0.jar:5.10.0]

        ... 23 more

       

       

      13:34:00,256 INFO  [stdout] (Camel (CML_CTX_JTA_TEST) thread #0 - JmsConsumer[inbound]) 13:34:00.255 [Camel (CML_CTX_JTA_TEST) thread #0 - JmsConsumer[inbound]] ERROR o.a.c.c.j.DefaultJmsMessageListenerContainer - Could not refresh JMS Connection for destination 'inbound' - retrying using FixedBackOff{interval=5000, currentAttempts=57, maxAttempts=unlimited}. Cause: IJ000453: Unable to get managed connection for java:/activemq/xaConnectionFactory

       

       

      13:34:05,256 WARN  [org.jboss.jca.core.connectionmanager.pool.strategy.OnePool] (Camel (CML_CTX_JTA_TEST) thread #0 - JmsConsumer[inbound]) IJ000604: Throwable while attempting to get a new connection: null: javax.resource.ResourceException: Could not create connection.

        at org.apache.activemq.ra.ActiveMQManagedConnectionFactory.createManagedConnection(ActiveMQManagedConnectionFactory.java:190)

        at org.jboss.jca.core.connectionmanager.pool.mcp.SemaphoreArrayListManagedConnectionPool.createConnectionEventListener(SemaphoreArrayListManagedConnectionPool.java:1166)

        at org.jboss.jca.core.connectionmanager.pool.mcp.SemaphoreArrayListManagedConnectionPool.getConnection(SemaphoreArrayListManagedConnectionPool.java:446)

        at org.jboss.jca.core.connectionmanager.pool.AbstractPool.getSimpleConnection(AbstractPool.java:461)

        at org.jboss.jca.core.connectionmanager.pool.AbstractPool.getConnection(AbstractPool.java:433)

        at org.jboss.jca.core.connectionmanager.AbstractConnectionManager.getManagedConnection(AbstractConnectionManager.java:379)

        at org.jboss.jca.core.connectionmanager.tx.TxConnectionManagerImpl.getManagedConnection(TxConnectionManagerImpl.java:421)

        at org.jboss.jca.core.connectionmanager.AbstractConnectionManager.allocateConnection(AbstractConnectionManager.java:515)

        at org.apache.activemq.ra.ActiveMQConnectionFactory.createConnection(ActiveMQConnectionFactory.java:94)

        at org.apache.activemq.ra.ActiveMQConnectionFactory.createConnection(ActiveMQConnectionFactory.java:67)

        at org.springframework.jms.support.JmsAccessor.createConnection(JmsAccessor.java:180) [spring-jms-4.1.4.RELEASE.jar:4.1.4.RELEASE]

        at org.springframework.jms.listener.DefaultMessageListenerContainer.refreshConnectionUntilSuccessful(DefaultMessageListenerContainer.java:910) [spring-jms-4.1.4.RELEASE.jar:4.1.4.RELEASE]

        at org.springframework.jms.listener.DefaultMessageListenerContainer.recoverAfterListenerSetupFailure(DefaultMessageListenerContainer.java:882) [spring-jms-4.1.4.RELEASE.jar:4.1.4.RELEASE]

        at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:1053) [spring-jms-4.1.4.RELEASE.jar:4.1.4.RELEASE]

        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_51]

        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_51]

        at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_51]

      Caused by: javax.jms.JMSException: Could not create Transport. Reason: java.io.IOException: Transport scheme NOT recognized: [tcp]

        at org.apache.activemq.util.JMSExceptionSupport.create(JMSExceptionSupport.java:36) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ActiveMQConnectionFactory.createTransport(ActiveMQConnectionFactory.java:317) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ActiveMQConnectionFactory.createActiveMQConnection(ActiveMQConnectionFactory.java:330) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ActiveMQConnectionFactory.createConnection(ActiveMQConnectionFactory.java:251) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ra.ActiveMQConnectionSupport.makeConnection(ActiveMQConnectionSupport.java:79)

        at org.apache.activemq.ra.ActiveMQConnectionSupport.makeConnection(ActiveMQConnectionSupport.java:61)

        at org.apache.activemq.ra.ActiveMQManagedConnectionFactory.createManagedConnection(ActiveMQManagedConnectionFactory.java:188)

        ... 16 more

      Caused by: java.io.IOException: Transport scheme NOT recognized: [tcp]

        at org.apache.activemq.util.IOExceptionSupport.create(IOExceptionSupport.java:27) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.transport.TransportFactory.findTransportFactory(TransportFactory.java:181) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.transport.TransportFactory.connect(TransportFactory.java:63) [activemq-client-5.10.0.jar:5.10.0]

        at org.apache.activemq.ActiveMQConnectionFactory.createTransport(ActiveMQConnectionFactory.java:315) [activemq-client-5.10.0.jar:5.10.0]

        ... 21 more

      Caused by: java.lang.ClassCastException: org.apache.activemq.transport.tcp.TcpTransportFactory cannot be cast to org.apache.activemq.transport.TransportFactory

        at org.apache.activemq.transport.TransportFactory.findTransportFactory(TransportFactory.java:178) [activemq-client-5.10.0.jar:5.10.0]

        ... 23 more