From d6cd5a0a56eafe9ef0cde925af12b71b523813ec Mon Sep 17 00:00:00 2001 From: Matt Hughes Date: Thu, 27 Mar 2025 14:35:54 +0000 Subject: [PATCH] feat(configx): default otel sampling rate to 1 This puts OTEL in line with the jaeger config. The motivation for this was the time spent debugging why no traces were being sent from a pod running `oryd/hydra` with our basic config: tracing: provider: otel service_name: ory-hydra deployment_environment: development providers: otlp: server_url: our-collector:4318 insecure: true --- configx/provider.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configx/provider.go b/configx/provider.go index 51a931c4..69a8479e 100644 --- a/configx/provider.go +++ b/configx/provider.go @@ -504,7 +504,7 @@ func (p *Provider) TracingConfig(serviceName string) *otelx.Config { ServerURL: p.String("tracing.providers.otlp.server_url"), Insecure: p.Bool("tracing.providers.otlp.insecure"), Sampling: otelx.OTLPSampling{ - SamplingRatio: p.Float64("tracing.providers.otlp.sampling.sampling_ratio"), + SamplingRatio: p.Float64F("tracing.providers.otlp.sampling.sampling_ratio", 1), }, AuthorizationHeader: p.String("tracing.providers.otlp.authorization_header"), },