@Immutable
public final class MessageEvent
extends java.lang.Object
It requires a type
and a message id that serves to uniquely identify each
message. It can optionally have information about the message size.
Modifier and Type | Class and Description |
---|---|
static class |
MessageEvent.Type
Available types for a
MessageEvent . |
Modifier and Type | Method and Description |
---|---|
static void |
record(io.opentelemetry.trace.Span span,
MessageEvent.Type type,
long messageId,
long uncompressedSize,
long compressedSize)
Records a
MessageEvent with the desired values to the given Span. |
public static void record(io.opentelemetry.trace.Span span, MessageEvent.Type type, long messageId, long uncompressedSize, long compressedSize)
MessageEvent
with the desired values to the given Span.span
- the span to record the MessageEvent
to.type
- designates whether this is a send or receive message.messageId
- serves to uniquely identify each message.uncompressedSize
- represents the uncompressed size in bytes of this message. If not
available use 0.compressedSize
- represents the compressed size in bytes of this message. If not available
use 0.