wu-sheng commented on code in PR #404:
URL: https://github.com/apache/skywalking-java/pull/404#discussion_r1038734804
##########
apm-sniffer/apm-sdk-plugin/rocketMQ-4.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/rocketMQ/v4/MessageSendInterceptor.java:
##########
@@ -59,6 +59,15 @@ public void beforeMethod(EnhancedInstance objInst, Method
method, Object[] allAr
span.setComponent(ComponentsDefine.ROCKET_MQ_PRODUCER);
Tags.MQ_BROKER.set(span, (String) allArguments[0]);
Tags.MQ_TOPIC.set(span, message.getTopic());
+ String keys = message.getKeys();
+ if (StringUtil.isNotBlank(keys)) {
+ span.tag(Tags.ofKey("message.keys"), keys);
+ }
+ String tags = message.getTags();
+ if (StringUtil.isNotBlank(tags)) {
+ span.tag(Tags.ofKey("message.tags"), tags);
+ }
Review Comment:
please add a prefix for tag keys. `mq.message.keys` and `mq.message.tags`.
If they are widely known concepts in the queue ecosystem, consider moving them
to `Tags`. If not, you don't have to.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]