Semantic Conventions for RocketMQ

Status: Experimental

The Semantic Conventions for Apache RocketMQ extend and override the Messaging Semantic Conventions that describe common messaging operations attributes in addition to the Semantic Conventions described on this page.

messaging.system MUST be set to "rocketmq".

Apache RocketMQ attributes

Specific attributes for Apache RocketMQ are defined below.

AttributeTypeDescriptionExamplesRequirement LevelStability
messaging.rocketmq.client_groupstringName of the RocketMQ producer/consumer group that is handling the message. The client type is identified by the SpanKind.myConsumerGroupRequiredExperimental
messaging.rocketmq.namespacestringNamespace of RocketMQ resources, resources in different namespaces are individual.myNamespaceRequiredExperimental
messaging.rocketmq.message.delay_time_levelintThe delay time level for delay message, which determines the message delay time.3Conditionally Required [1]Experimental
messaging.rocketmq.message.delivery_timestampintThe timestamp in milliseconds that the delay message is expected to be delivered to consumer.1665987217045Conditionally Required [2]Experimental
messaging.rocketmq.message.groupstringIt is essential for FIFO message. Messages that belong to the same message group are always processed one by one within the same consumer group.myMessageGroupConditionally Required If the message type is FIFO.Experimental
messaging.rocketmq.consumption_modelstringModel of message consumption. This only applies to consumer spans.clusteringRecommendedExperimental
messaging.rocketmq.message.keysstring[]Key(s) of message, another way to mark message besides message id.[keyA, keyB]RecommendedExperimental
messaging.rocketmq.message.tagstringThe secondary classifier of message besides topic.tagARecommendedExperimental
messaging.rocketmq.message.typestringType of message.normalRecommendedExperimental

[1]: If the message type is delay and delivery timestamp is not specified.

[2]: If the message type is delay and delay time level is not specified.

messaging.rocketmq.consumption_model MUST be one of the following:

ValueDescriptionStability
clusteringClustering consumption modelExperimental
broadcastingBroadcasting consumption modelExperimental

messaging.rocketmq.message.type MUST be one of the following:

ValueDescriptionStability
normalNormal messageExperimental
fifoFIFO messageExperimental
delayDelay messageExperimental
transactionTransaction messageExperimental

messaging.client_id SHOULD be set to the client ID that is automatically generated by the Apache RocketMQ SDK.