From 411be9b8143dc6fbffd67ad20cfbd1e162ac301d Mon Sep 17 00:00:00 2001 From: Martin Hutchinson Date: Mon, 16 Feb 2026 10:59:11 +0000 Subject: [PATCH] [POSIX] Env takes priority when configuring OTel attributes This makes POSIX OTel configuration order work the same way as GCP was changed to in #700. --- cmd/tesseract/posix/otel.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/tesseract/posix/otel.go b/cmd/tesseract/posix/otel.go index 287634775..e6deab04a 100644 --- a/cmd/tesseract/posix/otel.go +++ b/cmd/tesseract/posix/otel.go @@ -53,11 +53,11 @@ func initOTel(ctx context.Context, origin string) func(context.Context) { resources, err := resource.New(ctx, resource.WithTelemetrySDK(), - resource.WithFromEnv(), // unpacks OTEL_RESOURCE_ATTRIBUTES resource.WithAttributes( semconv.ServiceNameKey.String(origin), semconv.ServiceNamespaceKey.String("tesseract"), ), + resource.WithFromEnv(), // unpacks OTEL_RESOURCE_ATTRIBUTES ) if err != nil { klog.Exitf("Failed to detect resources: %v", err)