You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@activemq.apache.org by GitBox <gi...@apache.org> on 2021/01/11 17:48:29 UTC

[GitHub] [activemq-artemis] tabish121 commented on pull request #3404: ARTEMIS-3061 AMQPMessage::getDuplicateProperty can save key comparisons and class checks

tabish121 commented on pull request #3404:
URL: https://github.com/apache/activemq-artemis/pull/3404#issuecomment-758115040


   > @gemmellr
   > Just a qq about this:
   > 
   > ```java
   >          if (value instanceof UnsignedInteger ||
   >             value instanceof UnsignedByte ||
   >             value instanceof UnsignedLong ||
   >             value instanceof UnsignedShort) {
   >             return ((Number) value).longValue();
   >          }
   > ```
   > 
   > I've improved things a bit on this PR, but still...is it necessary?
   
   Unless the calling code is able / willing to deal with AMQP primitive types like these unsigned values then yes you still need it.  It was added for that reason as these types escaped into the AMQP to Core conversion stuff and it didn't deal with them correctly leading to issues.  They are valid types for ApplicationProperties so they need to be accounted for in this context.  
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org