-
Notifications
You must be signed in to change notification settings - Fork 973
Trace payload/message size in semantic convention is inconsistent #1053
Description
What are you trying to achieve?
Consistency should exist between the naming of payload/message size attribute names. Currently, we have a mix of how the name is constructed over 3 different protocols. HTTP has measure-name(length)(compressed) convention, gRPC has message.un/compressedmeasure_name(size) and message systems have message.measure-name(size)_unit(bytes). Here you have the complete list:
HTTP (attribute on a span):
http.request_content_lengthhttp.request_content_length_uncompressedhttp.response_content_lengthhttp.response_content_length_uncompressed
gRPC (attribute on link in a stream)
message.compressed_sizemessage.uncompressed_size
Messaging system (attribute on a span):
messaging.message_payload_size_bytesmessaging.message_payload_compressed_size_bytes
What did you expect to see?
Although this doesn't strictly violates the spec (although message in gRPC is borderline), we should seek consistency in the naming of measures. I would have expected something more like this:
HTTP (keeping this as this is the most established)
http.request_content_lengthhttp.request_content_length_uncompressedhttp.response_content_lengthhttp.response_content_length_uncompressed
gRPC and messaging:
messaging.payload_sizemessaging.payload_size_uncompressed
changes for message: joined RPC and messaging and:
- Removed unit (bytes)
- Changed compressed to uncompressed to align with HTTP
- Removed message from message_payload_size
I think it would be wise too add a note in the attributes naming convention some guidelines for messages, like:
- not adding the unit (bytes, mm, ...) in the attribute name
Metadata
Metadata
Assignees
Labels
Type
Projects
Status