From 2714831a4e6a0972a0eca5d46af2f82f9ed2efd9 Mon Sep 17 00:00:00 2001 From: Michael Date: Thu, 29 Aug 2024 14:30:05 +0200 Subject: [PATCH] fix: otlp doc + potential panic --- docs/content/observability/tracing/overview.md | 4 +--- pkg/config/static/static_config.go | 3 +++ 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/content/observability/tracing/overview.md b/docs/content/observability/tracing/overview.md index fcea5c548..b69aee46b 100644 --- a/docs/content/observability/tracing/overview.md +++ b/docs/content/observability/tracing/overview.md @@ -170,7 +170,6 @@ Defines the list of query parameters to not redact. ```yaml tab="File (YAML)" tracing: - otlp: safeQueryParams: - bar - buz @@ -178,10 +177,9 @@ tracing: ```toml tab="File (TOML)" [tracing] - [tracing.otlp] safeQueryParams = ["bar", "buz"] ``` ```bash tab="CLI" ---tracing.otlp.safeQueryParams=bar,buz +--tracing.safeQueryParams=bar,buz ``` diff --git a/pkg/config/static/static_config.go b/pkg/config/static/static_config.go index 2dae73cfc..1e0c5d61d 100644 --- a/pkg/config/static/static_config.go +++ b/pkg/config/static/static_config.go @@ -212,6 +212,9 @@ type Tracing struct { func (t *Tracing) SetDefaults() { t.ServiceName = "traefik" t.SampleRate = 1.0 + + t.OTLP = &opentelemetry.Config{} + t.OTLP.SetDefaults() } // Providers contains providers configuration.