Github user clebertsuconic commented on the issue:

    https://github.com/apache/activemq-artemis/pull/1574
  
    @mtaylor did you test it?
    
    The test you added is broken... I had to fix it with this:
    
    ```java
    
       private LargeServerMessage messageToLargeMessage(Message message) throws 
Exception {
          ICoreMessage coreMessage = message.toCore();
          LargeServerMessage lsm = 
getStorageManager().createLargeMessage(storageManager.generateID(), 
coreMessage);
    
          ActiveMQBuffer buffer = coreMessage.getReadOnlyBodyBuffer();
          byte[] body = new byte[buffer.readableBytes()];
          buffer.readBytes(body);
          lsm.addBytes(body);
          lsm.releaseResources();
          lsm.putLongProperty(Message.HDR_LARGE_BODY_SIZE, body.length);
          return lsm;
       }
    ```


---

Reply via email to