[
https://issues.apache.org/jira/browse/ARTEMIS-316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15986626#comment-15986626
]
Timothy Bish commented on ARTEMIS-316:
--------------------------------------
Given the refactoring that was done in the 2.0.0 release for the straight
through handling of AMQP messages this is most certainly fixed in 2.0.0 but
probably even before then given the other fixes that went into the AMQP JMS
Transformer layer. The best way to check though is to ask the computer by
running the test again against a new broker.
> Broker cannot receive a message; throws "java.lang.NullPointerException"
> ------------------------------------------------------------------------
>
> Key: ARTEMIS-316
> URL: https://issues.apache.org/jira/browse/ARTEMIS-316
> Project: ActiveMQ Artemis
> Issue Type: Bug
> Components: Broker
> Affects Versions: 1.1.0
> Environment: Broker: apache-artemis-1.1.0 on Rhel 6.7 -x86_64
> Client: amqpnetlite-1.1.0.3-1 on Windows Server 2012 R2
> Used protocol: AMQP 1.0
> Reporter: Petra Svobodova
>
> Sending a message on the broker throws the exception on the broker side.
> Steps to reproduce:
> on Linux:
> 1. Set JAVA_HOME environment variable, download and unpack the broker package.
> 2. Create a broker instance.
> 3. Open "broker.xml" file and create a queue "testQ" (see below)
> 4. Run the broker: "~/bin/artemis run"
> on Windows;
> 5. Download and unpack the amqpnetlite package.
> 6. Build the examples solution.
> 7. Try to run "Interop.Spout.exe --broker amqp://<broker-url>:5672 --address
> testQ"
> 8. The exception is thrown and no message was received on the broker side;
> see below, please:
> Exception transcription (Broker output):
> java.lang.NullPointerException
> at
> org.apache.qpid.proton.jms.JMSMappingInboundTransformer.transform(JMSMappingInboundTransformer.java:86)
> at
> org.apache.activemq.artemis.core.protocol.proton.converter.ProtonMessageConverter.inboundJMSType(ProtonMessageConverter.java:57)
> at
> org.apache.activemq.artemis.core.protocol.proton.converter.ProtonMessageConverter.inbound(ProtonMessageConverter.java:43)
> at
> org.apache.activemq.artemis.core.protocol.proton.plug.ProtonSessionIntegrationCallback.serverSend(ProtonSessionIntegrationCallback.java:238)
> at
> org.proton.plug.context.server.ProtonServerReceiverContext.onMessage(ProtonServerReceiverContext.java:114)
> at
> org.proton.plug.context.AbstractConnectionContext$LocalListener.onDelivery(AbstractConnectionContext.java:243)
> at org.proton.plug.handler.Events.dispatch(Events.java:100)
> at
> org.proton.plug.handler.impl.ProtonHandlerImpl.dispatch(ProtonHandlerImpl.java:337)
> at
> org.proton.plug.handler.impl.ProtonHandlerImpl.flush(ProtonHandlerImpl.java:257)
> at
> org.proton.plug.handler.impl.ProtonHandlerImpl.inputBuffer(ProtonHandlerImpl.java:158)
> at
> org.proton.plug.context.AbstractConnectionContext.inputBuffer(AbstractConnectionContext.java:81)
> at
> org.apache.activemq.artemis.core.protocol.proton.ActiveMQProtonRemotingConnection.bufferReceived(ActiveMQProtonRemotingConnection.java:127)
> at
> org.apache.activemq.artemis.core.remoting.server.impl.RemotingServiceImpl$DelegatingBufferHandler.bufferReceived(RemotingServiceImpl.java:595)
> 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.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:110)
> at java.lang.Thread.run(Thread.java:745)
> !!!!! Readable!!!!!!!
> broker.xml file:
> # cat etc/broker.xml
> <?xml version='1.0'?>
> <!--
> Licensed to the Apache Software Foundation (ASF) under one
> or more contributor license agreements. See the NOTICE file
> distributed with this work for additional information
> regarding copyright ownership. The ASF licenses this file
> to you under the Apache License, Version 2.0 (the
> "License"); you may not use this file except in compliance
> with the License. You may obtain a copy of the License at
> http://www.apache.org/licenses/LICENSE-2.0
> Unless required by applicable law or agreed to in writing,
> software distributed under the License is distributed on an
> "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
> KIND, either express or implied. See the License for the
> specific language governing permissions and limitations
> under the License.
> -->
> <configuration xmlns="urn:activemq"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="urn:activemq
> /schema/artemis-configuration.xsd">
> <jms xmlns="urn:activemq:jms">
> <queue name="DLQ"/>
> <queue name="ExpiryQueue"/>
> </jms>
> <core xmlns="urn:activemq:core">
> <!-- this could be ASYNCIO or NIO
> -->
> <journal-type>ASYNCIO</journal-type>
> <paging-directory>./data/paging</paging-directory>
> <bindings-directory>./data/bindings</bindings-directory>
> <journal-directory>./data/journal</journal-directory>
>
> <large-messages-directory>./data/large-messages</large-messages-directory>
> <journal-min-files>10</journal-min-files>
> <!--
> This value was determined through a calculation.
> Your system could perform 0.08 writes per millisecond
> on the current journal configuration.
> That translates as a sync write every 12228000 nanoseconds
> -->
> <journal-buffer-timeout>12228000</journal-buffer-timeout>
> <acceptors>
> <!-- Default ActiveMQ Artemis Acceptor. Multi-protocol adapter.
> Currently supports Core, OpenWire, Stomp and AMQP. -->
> <!-- performance tests have shown that openWire performs best with
> these buffer sizes -->
> <acceptor
> name="artemis">tcp://0.0.0.0:61616?tcpSendBufferSize=1048576;tcpReceiveBufferSize=1048576</acceptor>
> <!-- AMQP Acceptor. Listens on default AMQP port for AMQP
> traffic.-->
> <acceptor name="amqp">tcp://0.0.0.0:5672?protocols=AMQP</acceptor>
> <!-- STOMP Acceptor. -->
> <acceptor name="stomp">tcp://0.0.0.0:61613?protocols=STOMP</acceptor>
> <!-- HornetQ Compatibility Acceptor. Enables ActiveMQ Artemis Core
> and STOMP for legacy HornetQ clients. -->
> <acceptor
> name="hornetq">tcp://0.0.0.0:5445?protocols=HORNETQ,STOMP</acceptor>
> <!-- MQTT Acceptor -->
> <acceptor name="mqtt">tcp://0.0.0.0:1883?protocols=MQTT</acceptor>
> </acceptors>
> <security-settings>
> <security-setting match="#">
> <permission type="createNonDurableQueue" roles="amq"/>
> <permission type="deleteNonDurableQueue" roles="amq"/>
> <permission type="createDurableQueue" roles="amq"/>
> <permission type="deleteDurableQueue" roles="amq"/>
> <permission type="consume" roles="amq"/>
> <permission type="send" roles="amq"/>
> <!-- we need this otherwise ./artemis data imp wouldn't work -->
> <permission type="manage" roles="amq"/>
> </security-setting>
> </security-settings>
> <address-settings>
> <!--default for catch all-->
> <address-setting match="#">
> <dead-letter-address>jms.queue.DLQ</dead-letter-address>
> <expiry-address>jms.queue.ExpiryQueue</expiry-address>
> <redelivery-delay>0</redelivery-delay>
> <max-size-bytes>10485760</max-size-bytes>
>
> <message-counter-history-day-limit>10</message-counter-history-day-limit>
> <address-full-policy>BLOCK</address-full-policy>
> </address-setting>
> </address-settings>
> <queues>
> <queue name="testQ">
> <address>"testQ"</address>
> <durable>true</durable>
> </queue>
> </queues>
> </core>
> </configuration>
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)