binzhaomobile opened a new issue #2079:
URL: https://github.com/apache/rocketmq/issues/2079


   In Message#putUserProperty, emply property value is not allowed. If an empty 
value is set, QocketMQ will throw IllegalArgumentException"The name or value of 
property can not be null or blank string!"
   In some cases, empty value makes business sense. Empty property shoud better 
be supported.
   
   Source Code:
   public void putUserProperty(String name, String value) {
       if (MessageConst.STRING_HASH_SET.contains(name)) {
           throw new RuntimeException(String.format("The Property<%s> is used 
by system, input another please", name));
       } else if (value != null && !value.trim().isEmpty() && name != null && 
!name.trim().isEmpty()) {
           this.putProperty(name, value);
       } else {
           throw new IllegalArgumentException("The name or value of property 
can not be null or blank string!");
       }
   }
   


----------------------------------------------------------------
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:
[email protected]


Reply via email to