From a4b4d90da8b48a81b63fccb7a337555c674a4f5d Mon Sep 17 00:00:00 2001 From: Anantha Kumaran Date: Thu, 19 May 2022 11:03:07 +0530 Subject: [PATCH] allow custom propagator --- CHANGELOG.md | 6 ++++++ apps/opentelemetry/src/otel_configuration.erl | 2 ++ 2 files changed, 8 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index a445a97e..c81dcffd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [SDK] + +### Fixed + +- [Allow custom text propagator to be configured via application env](https://github.com/open-telemetry/opentelemetry-erlang/pull/408) + ## SDK 1.0.5 - 2022-05-20 ### Fixed diff --git a/apps/opentelemetry/src/otel_configuration.erl b/apps/opentelemetry/src/otel_configuration.erl index 4f59de74..30c38989 100644 --- a/apps/opentelemetry/src/otel_configuration.erl +++ b/apps/opentelemetry/src/otel_configuration.erl @@ -454,6 +454,8 @@ transform(propagator, Value) when Value =:= "b3" ; %% TODO: support jager propagator format %% transform(propagator, "jaeger") -> %% jaeger; +transform(propagator, Propagator) when is_atom(Propagator) -> + Propagator; transform(propagator, Propagator) -> ?LOG_WARNING("Ignoring unknown propagator ~ts in OS environment variable $OTEL_PROPAGATORS", [Propagator]),