Skip to content

[API Proposal]: Consider capturing ActivitySpanId, ActivityTraceId, and MessageTemplate when using log buffering #6502

Open
@voroninp

Description

@voroninp

Background and motivation

Here's what docs say:

Not all information of the original log record is preserved. Log buffering internally uses BufferedLogRecord class when flushing, and the following of its properties are always empty:
ActivitySpanId, ActivityTraceId, ManagedThreadId, MessageTemplate.

Maybe I am missing a point with log buffering, but I believe knowing the trace and span ids is still useful for correlating messages with traces.
MessageTemplate is convenient for indexing and searching for similar messages. But it can increase memory footprint, so not sure about it for 100%.

API Proposal

BufferedLogRecord already has these properties, but SerializedLogRecord stored in buffer does not. It looks like these properties should be added there.

API Usage

Should be transparent for the client.

Alternative Designs

No response

Risks

No response

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions