From b2739c282d7a1d6a58fbd340a2d486f8fd404726 Mon Sep 17 00:00:00 2001 From: Bogdan Drutu Date: Tue, 9 Jan 2024 11:17:54 -0800 Subject: [PATCH 1/2] Add TraceState to the LogRecord Signed-off-by: Bogdan Drutu --- CHANGELOG.md | 2 ++ opentelemetry/proto/logs/v1/logs.proto | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 470f1f43e..de1747ae0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,8 @@ Full list of differences found in [this compare](https://github.com/open-telemet * Add a field for W3C-specified Trace Context flags to the `Span` and `Link`. [#503](https://github.com/open-telemetry/opentelemetry-proto/pull/503) +* Add a field for W3C-specified Trace Context TraceState to the `LogRecord`. + [#522](https://github.com/open-telemetry/opentelemetry-proto/pull/522) ## 1.0.0 - 2023-07-03 diff --git a/opentelemetry/proto/logs/v1/logs.proto b/opentelemetry/proto/logs/v1/logs.proto index f9b97dd74..6a7533dda 100644 --- a/opentelemetry/proto/logs/v1/logs.proto +++ b/opentelemetry/proto/logs/v1/logs.proto @@ -208,4 +208,9 @@ message LogRecord { // - the field is not present, // - the field contains an invalid value. bytes span_id = 10; + + // trace_state conveys information about request position in multiple distributed tracing graphs. + // It is a trace_state in w3c-trace-context format: https://www.w3.org/TR/trace-context/#tracestate-header + // See also https://github.com/w3c/distributed-tracing for more details about this field. + string trace_state = 12; } From 28aba509a505ab28553d4983fd3d318f515960db Mon Sep 17 00:00:00 2001 From: Bogdan Drutu Date: Tue, 9 Jan 2024 11:26:35 -0800 Subject: [PATCH 2/2] Update opentelemetry/proto/logs/v1/logs.proto Co-authored-by: Reiley Yang --- opentelemetry/proto/logs/v1/logs.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opentelemetry/proto/logs/v1/logs.proto b/opentelemetry/proto/logs/v1/logs.proto index 6a7533dda..8e378ba23 100644 --- a/opentelemetry/proto/logs/v1/logs.proto +++ b/opentelemetry/proto/logs/v1/logs.proto @@ -210,7 +210,7 @@ message LogRecord { bytes span_id = 10; // trace_state conveys information about request position in multiple distributed tracing graphs. - // It is a trace_state in w3c-trace-context format: https://www.w3.org/TR/trace-context/#tracestate-header + // It is a trace_state in w3c-trace-context format: https://www.w3.org/TR/trace-context/#tracestate-header. // See also https://github.com/w3c/distributed-tracing for more details about this field. string trace_state = 12; }