zainzhoucom opened a new issue #176: Why don't you take a TAG from the Header
URL: https://github.com/apache/rocketmq-spring/issues/176
 
 
   `MessageBuilder.withPayload(new 
Model()).setHeader(RocketMQHeaders.TAGS,"test.tag").build()`
   
   RocketMQUtil.getAndWrapMessage
   `
   //Why is that?
   String[] tempArr = destination.split(":", 2);
     String topic = tempArr[0];
     String tags = "";
      if (tempArr.length > 1) {
             tags = tempArr[1];
     }
   
   Message rocketMsg = new Message(topic, tags, payloads);
                `
   
   `
   //Why not
   Object tag = headers.get(RocketMQHeaders.TAGS);
    if(!StringUtils.isEmpty(tag)){
       rocketMsg.setTags(tag.toString());
     }
   Object keys = headers.get(RocketMQHeaders.KEYS);
   `

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to