0 Replies Latest reply on Mar 14, 2018 1:10 AM by Nagaraju Chitimilla

    Widlfly 12 - Integration with External Active Mq

    Nagaraju Chitimilla Newbie

      I'm trying to integrate the external activeMq with Wildfly 12. I have used the remote-connector to connect to the external active mq.

      <subsystem xmlns="urn:jboss:domain:messaging-activemq:3.0">

         <server name="default">

           ...

            <remote-connector name="remote-messaging" socket-binding="external-messaging-broker">

               <param name="enabled-protocols" value="TLSv1.2" />

               <param name="key-store-path" value="C:/ActiveMQ/conf/keystore.p12" />

               <param name="key-store-password" value="N0tall0wed" />

               <param name="trust-store-path" value="C:/ActiveMQ/conf/keystore.p12" />

               <param name="trust-store-password" value="N0tall0wed" />

               <param name="ssl-enabled" value="true" />

            </remote-connector>

           ...

            <jms-queue name="ExpiryQueue" entries="java:/jms/queue/ExpiryQueue" />

            <jms-queue name="DLQ" entries="java:/jms/queue/DLQ" />

            <connection-factory name="InVmConnectionFactory" entries="java:/ConnectionFactory" connectors="in-vm" />

            <connection-factory name="RemoteConnectionFactory" entries="java:jboss/exported/jms/RemoteConnectionFactory" connectors="http-connector" />

            <pooled-connection-factory name="activemq-ra" entries="java:/ActivemqJms" connectors="remote-messaging" transaction="xa" user="reportserver" password="N0tall0wed" />

         </server>

      </subsystem>

      <socket-binding-group name="standard-sockets" default-interface="public" port-offset="${jboss.socket.binding.port-offset:0}">

      ...

      <outbound-socket-binding name="external-messaging-broker"> 

      <remote-destination host="localhost" port="61616"/> 

      </outbound-socket-binding>

      </socket-binding-group>

       

      After wildfly startup i could see that server is throwing the following exception:

       

      22:36:07,733 ERROR [org.apache.activemq.artemis.core.client] (Thread-5 (ActiveMQ-client-netty-threads)) AMQ214013: Failed to decode packet: java.lang.IllegalArgumentException: AMQ119032: Invalid type: 1
              at org.apache.activemq.artemis.core.protocol.core.impl.PacketDecoder.decode(PacketDecoder.java:424)
              at org.apache.activemq.artemis.core.protocol.ClientPacketDecoder.decode(ClientPacketDecoder.java:60)
              at org.apache.activemq.artemis.core.protocol.ClientPacketDecoder.decode(ClientPacketDecoder.java:39)
              at org.apache.activemq.artemis.core.protocol.core.impl.RemotingConnectionImpl.bufferReceived(RemotingConnectionImpl.java:355)
              at org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl$DelegatingBufferHandler.bufferReceived(ClientSessionFactoryImpl.java:1143)
              at org.apache.activemq.artemis.core.remoting.impl.netty.ActiveMQChannelHandler.channelRead(ActiveMQChannelHandler.java:69)
              at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
              at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
              at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:340)
              at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:293)
              at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:267)
              at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
              at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
              at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:340)
              at io.netty.handler.ssl.SslHandler.unwrap(SslHandler.java:1240)
              at io.netty.handler.ssl.SslHandler.decode(SslHandler.java:1041)
              at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:411)
              at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:248)
              at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
              at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
              at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:340)
              at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1334)
              at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
              at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
              at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:926)
              at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:134)
              at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:624)
              at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:559)
              at io.netty.channel.nio.NioEventLoop.processS     electedKeys(NioEventLoop.java:476)
              at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:438)

       

      Below is the exception logged in activemq log.

       

      2018-03-14 10:26:52,820 | WARN  | Transport Connection to: tcp://127.0.0.1:62344 failed: java.io.IOException: Frame size of 1045 MB larger than max allowed 100 MB | org.apache.activemq.broker.TransportConnection.Transport | ActiveMQ NIO Worker 367
      2018-03-14 10:29:02,878 | WARN  | Transport Connection to: tcp://127.0.0.1:62383 failed: java.io.IOException: Frame size of 1045 MB larger than max allowed 100 MB | org.apache.activemq.broker.TransportConnection.Transport | ActiveMQ NIO Worker 368
      2018-03-14 10:31:12,847 | WARN  | Transport Connection to: tcp://127.0.0.1:62422 failed: java.io.IOException: Frame size of 1045 MB larger than max allowed 100 MB | org.apache.activemq.broker.TransportConnection.Transport | ActiveMQ NIO Worker 369

       

      I haven't created any queue as of now but still wildfly trying to send the 1045MB of data to activemq?