[
https://issues.apache.org/jira/browse/AMQ-3742?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13217559#comment-13217559
]
David Wheeler commented on AMQ-3742:
------------------------------------
I've created the following extra test method that should reproduce the issue
Index: src/test/java/org/apache/activemq/transport/stomp/StompTest.java
===================================================================
--- src/test/java/org/apache/activemq/transport/stomp/StompTest.java
(revision 1294315)
+++ src/test/java/org/apache/activemq/transport/stomp/StompTest.java
(working copy)
@@ -1819,6 +1819,24 @@
doReplyToAcrossConnections("queue");
}
+ public void testSendNullBodyTextMessage() throws Exception {
+ String frame = "CONNECT\n" + "login: system\n" + "passcode: manager\n\n"
+ Stomp.NULL;
+ stompConnection.sendFrame(frame);
+
+ frame = stompConnection.receiveFrame();
+ assertTrue(frame.startsWith("CONNECTED"));
+
+ frame = "SUBSCRIBE\n" + "destination:/queue/" + getQueueName() + "\n" +
"ack:auto\n\n" + Stomp.NULL;
+ stompConnection.sendFrame(frame);
+
+ sendMessage(null);
+ frame = stompConnection.receiveFrame();
+ assertNotNull("Message not received", frame);
+
+ frame = "DISCONNECT\n" + "\n\n" + Stomp.NULL;
+ stompConnection.sendFrame(frame);
+ }
+
private void doReplyToAcrossConnections(String type) throws Exception {
LOG.info("Starting test on Temp Destinations using a temporary: " +
type);
> STOMP subscriber does not receive TextMessage with null body sent from JMS
> --------------------------------------------------------------------------
>
> Key: AMQ-3742
> URL: https://issues.apache.org/jira/browse/AMQ-3742
> Project: ActiveMQ
> Issue Type: Bug
> Components: stomp
> Affects Versions: 5.5.1
> Reporter: David Wheeler
>
> If a JMS publisher sends a TextMessage with null body, any STOMP subscribers
> to the topic (I haven't tested queues) will not receive that message or any
> further messages on that topic.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira