This commit is contained in:
Clebert Suconic 2018-05-21 18:10:00 -04:00
commit 7a917dc7d2
2 changed files with 6 additions and 1 deletions

View File

@ -965,7 +965,7 @@ public class ActiveMQMessage implements javax.jms.Message {
boolean result = false;
if (jmsPropertyName.equals(name)) {
message.putStringProperty(corePropertyName, value.toString());
message.putStringProperty(corePropertyName, value == null ? null : value.toString());
result = true;
}

View File

@ -26,6 +26,7 @@ import javax.jms.Session;
import javax.jms.StreamMessage;
import org.apache.activemq.artemis.api.jms.ActiveMQJMSClient;
import org.apache.activemq.artemis.reader.MessageUtil;
import org.apache.activemq.artemis.tests.integration.IntegrationTestLogger;
import org.apache.activemq.artemis.tests.util.JMSTestBase;
import org.junit.Assert;
@ -193,6 +194,10 @@ public class MessageTest extends JMSTestBase {
msg.setObjectProperty(MessageTest.propName1, null);
msg.setObjectProperty(MessageUtil.JMSXGROUPID, null);
msg.setObjectProperty(MessageUtil.JMSXUSERID, null);
msg.setStringProperty(MessageTest.propName2, null);
msg.getStringProperty(MessageTest.propName1);