[ 
https://issues.apache.org/jira/browse/ARTEMIS-2045?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16587324#comment-16587324
 ] 

ASF GitHub Bot commented on ARTEMIS-2045:
-----------------------------------------

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

    https://github.com/apache/activemq-artemis/pull/2256#discussion_r211574987
  
    --- Diff: 
artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/broker/AMQPMessage.java
 ---
    @@ -733,6 +743,9 @@ public void sendBuffer(ByteBuf buffer, int 
deliveryCount) {
              
buffer.writeBytes(data.duplicate().limit(headerEnds).byteBuffer());
           }
     
    +      writeOutgoingDeliveryAnnotations(buffer);
    --- End diff --
    
    I'm not sure here:
    This addition here (in `sendBuffer(buffer, deliveryCount)` from the 
`Message` interface) was done to have both the `sendBuffer` and `getSendBuffer` 
methods behave the same towards using the `outgoingDeliveryAnnotations`.
    
    But on the other hand this `sendBuffer` method isn't called by the 
`ProtonServerSenderContext` (only `getSendBuffer` is).
    So maybe the better solution would be to remove usage of 
`outgoingDeliveryAnnotations` in the `sendBuffer` method here and rename 
`getSendBuffer` to `getOutgoingMessageSendBuffer` to avoid confusion concerning 
these methods.


> [AMQP] Add support for setting delivery annotations on outgoing messages
> ------------------------------------------------------------------------
>
>                 Key: ARTEMIS-2045
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-2045
>             Project: ActiveMQ Artemis
>          Issue Type: Improvement
>          Components: AMQP
>            Reporter: Carsten Lohmann
>            Priority: Major
>
> When delivering an AMQP message, there is currently no way to set delivery 
> annotations on the outgoing message.
> Having such a possibility would allow outgoing AMQP interceptors to set such 
> annotations.
>  
> This is needed for implementing OpenTracing support via a broker plugin and 
> interceptors - see ARTEMIS-2028.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to