Github user clebertsuconic commented on a diff in the pull request:

    https://github.com/apache/activemq-artemis/pull/1965#discussion_r176408421
  
    --- Diff: 
artemis-protocols/artemis-stomp-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/stomp/StompSession.java
 ---
    @@ -154,12 +154,16 @@ public int sendMessage(MessageReference ref,
                 encoder.encode(buffer, bodySize);
                 encoder.close();
              } else {
    -            buffer = coreMessage.getReadOnlyBodyBuffer();
    +            if 
(Boolean.TRUE.equals(serverMessage.getBooleanProperty(Message.HDR_LARGE_COMPRESSED)))
 {
    +               buffer = coreMessage.getBodyBuffer();
    --- End diff --
    
    @gaohoward I will send a PR... the same code you wrote would work with 
readOnlyBuffer...
    
    Besides this problem is not just stomp.. AMQP and MQTT would fail. I will 
make this generic.


---

Reply via email to