AMQ214013: Failed to decode packet
armahdi Dec 15, 2016 12:14 AMMy activeMQ on widlfly was working fine and some how this week since Monday i started having this exception and quite frequently.
At first I went to the stack trace and looked into the code through code grep that throw this exception and it seemed to me that the issue might be with the largen size of the message. I stopped the process that inputs the message in the queues. and turned on my wildfly. the queue did not have data but i still got this exception.
I removed the activeMQ directory and the tx-object-store from the data directory. I started wildlfy and it had the same issue. and I am still getting this exception. there was one site ( https://www.mail-archive.com/users@activemq.apache.org/msg36343.html ) saying that may be the ports are wrongly defined. But i have been using this config for like months and I don't seem to have changed anything in there nor have I upgraded Wildfly 10 to another version. so the libs are the same still.
Can any one tell me why is this error coming if there is no data flowing through activeMQ. I removed the data directory so there was nothing that is loaded for it to decode nor it is receiving anything to put on the queue to be decoded.
2016-12-15 14:46:23,771 ERROR [org.apache.activemq.artemis.core.client] (Thread-68 (activemq-netty-threads-1550993361)) 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:413)
at org.apache.activemq.artemis.core.protocol.ClientPacketDecoder.decode(ClientPacketDecoder.java:60)
at org.apache.activemq.artemis.core.protocol.ServerPacketDecoder.decode(ServerPacketDecoder.java:202)
at org.apache.activemq.artemis.core.protocol.core.impl.RemotingConnectionImpl.bufferReceived(RemotingConnectionImpl.java:324)
at org.apache.activemq.artemis.core.remoting.server.impl.RemotingServiceImpl$DelegatingBufferHandler.bufferReceived(RemotingServiceImpl.java:605)
at org.apache.activemq.artemis.core.remoting.impl.netty.ActiveMQChannelHandler.channelRead(ActiveMQChannelHandler.java:68)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:308)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:294)
at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:265)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:308)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:294)
at io.netty.handler.codec.ByteToMessageDecoder.handlerRemoved(ByteToMessageDecoder.java:216)
at io.netty.channel.DefaultChannelPipeline.callHandlerRemoved0(DefaultChannelPipeline.java:527)
at io.netty.channel.DefaultChannelPipeline.callHandlerRemoved(DefaultChannelPipeline.java:521)
at io.netty.channel.DefaultChannelPipeline.remove0(DefaultChannelPipeline.java:351)
at io.netty.channel.DefaultChannelPipeline.remove(DefaultChannelPipeline.java:322)
at io.netty.channel.DefaultChannelPipeline.remove(DefaultChannelPipeline.java:299)
at org.apache.activemq.artemis.core.protocol.ProtocolHandler$ProtocolDecoder.decode(ProtocolHandler.java:174)
at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:349)
at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:244)
at org.apache.activemq.artemis.core.protocol.ProtocolHandler$ProtocolDecoder.channelRead(ProtocolHandler.java:117)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:308)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:294)
at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:846)
at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:131)
at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:511)
at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:468)
at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:382)
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:354)
at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:112)
at java.lang.Thread.run(Thread.java:745)
my standalone.xml:
<subsystem xmlns="urn:jboss:domain:messaging-activemq:1.0">
<server name="default">
<security enabled="false"/>
<management jmx-enabled="true"/>
<journal file-size="1024000"/>
<statistics enabled="true"/>
<shared-store-master/>
<security-setting name="#">
<role name="guest" delete-non-durable-queue="true" create-non-durable-queue="true" consume="true" send="true"/>
</security-setting>
<address-setting name="#" message-counter-history-day-limit="10" page-size-bytes="4194304" max-size-bytes="20971520" expiry-address="jms.queue.ExpiryQueue" dead-letter-address="jms.queue.DLQ"/>
<http-connector name="http-connector" endpoint="http-acceptor" socket-binding="http"/>
<http-connector name="http-connector-throughput" endpoint="http-acceptor-throughput" socket-binding="http">
<param name="batch-delay" value="50"/>
</http-connector>
<remote-connector name="netty" socket-binding="messaging"/>
<remote-connector name="netty-throughput" socket-binding="messaging-throughput">
<param name="batch-delay" value="50"/>
</remote-connector>
<in-vm-connector name="in-vm" server-id="0"/>
<http-acceptor name="http-acceptor" http-listener="default"/>
<http-acceptor name="http-acceptor-throughput" http-listener="default">
<param name="batch-delay" value="50"/>
<param name="direct-deliver" value="false"/>
</http-acceptor>
<remote-acceptor name="netty" socket-binding="messaging"/>
<remote-acceptor name="netty-throughput" socket-binding="messaging-throughput">
<param name="batch-delay" value="50"/>
<param name="direct-deliver" value="false"/>
</remote-acceptor>
<in-vm-acceptor name="in-vm" server-id="0"/>
<divert name="divert-to-multidm" forwarding-address="jms.queue.dbservice.multi_dm" address="jms.queue.dbservice.cap_tp_2"/>
<divert name="divert-to-multifo" forwarding-address="jma.queue.dbservice.multi_fo" address="jms.queue.dbservice.cl1test_odc_capfotp2"/>
<!--divert name="divert-to-cl1fo" forwarding-address="jma.queue.dbservice.cl1_fo" address="jms.queue.dbservice.cl1test_odc_capfotp2"/>
<divert name="divert-to-tmafocl1devfo" forwarding-address="jma.queue.dbservice.tmafocl1dev_fo" address="jms.queue.dbservice.cl1_test_odc_capfotp"/>
<divert name="divert-to-tmafocl1devdm" forwarding-address="jma.queue.dbservice.tmafocl1dev_dm" address="jms.queue.dbservice.cl1_test_odc_cap_tp"/-->
<jms-queue name="ExpiryQueue" entries="java:/jms/queue/ExpiryQueue"/>
<jms-queue name="DLQ" entries="java:/jms/queue/DLQ"/>
<jms-queue name="dbservice.cap_tp_2" entries="/queue/cap_tp_2"/>
<jms-queue name="dbservice.tp2_dm" entries="/queue/tp2_dm"/>
<jms-queue name="dbservice.tp2_fo" entries="/queue/tp2_fo"/>
<!--jms-queue name="dbservice.tmafocl1dev_fo" entries="/queue/tmafocl1dev_fo"/>
<jms-queue name="dbservice.tmafocl1dev_dm" entries="/queue/tmafocl1dev_dm"/-->
<connection-factory name="InVmConnectionFactory" entries="java:/ConnectionFactory" connectors="in-vm"/>
<jms-queue name="dbservice.tmafocl1dev_dm" entries="/queue/tmafocl1dev_dm"/-->
<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="hornetq-ra" transaction="xa" entries="java:/JmsXA java:jboss/DefaultJMSConnectionFactory" connectors="in-vm" min-large-message-size="10240"/>
</server>
</subsystem>
<socket-binding-group name="standard-sockets" default-interface="public" port-offset="${jboss.socket.binding.port-offset:0}">
<socket-binding name="management-http" interface="management" port="${jboss.management.http.port:9990}"/>
<socket-binding name="management-https" interface="management" port="${jboss.management.https.port:9993}"/>
<socket-binding name="ajp" port="${jboss.ajp.port:8009}"/>
<socket-binding name="http" port="${jboss.http.port:8080}"/>
<socket-binding name="https" port="${jboss.https.port:9443}"/>
<socket-binding name="iiop" interface="unsecure" port="3528"/>
<socket-binding name="iiop-ssl" interface="unsecure" port="3529"/>
<socket-binding name="messaging" port="5445"/>
<socket-binding name="messaging-backup" port="5545"/>
<socket-binding name="messaging-throughput" port="5455"/>
<socket-binding name="txn-recovery-environment" port="4712"/>
<socket-binding name="txn-status-manager" port="4713"/>
<socket-binding name="node2-jms-broker" port="${node2.broker.port:5445}"/>
<socket-binding name="node2throughput-jms-broker" port="${node2throughput.broker.port:5455}"/>
<outbound-socket-binding name="mail-smtp">
<remote-destination host="localhost" port="25"/>
</outbound-socket-binding>
</socket-binding-group>
I got an answer from here
java - ActiveMQ Artemis on wildfly with standalone ActiveMQ - Stack Overflow
but then my setup has been working for more than an year and i cannot seem to know what has changed for this error to come.