opentelemetry-erlang-contrib icon indicating copy to clipboard operation
opentelemetry-erlang-contrib copied to clipboard

Add LiveView async wrapper functions for process propagation in OpentelemetryPhoenix

Open danschultzer opened this issue 11 months ago • 1 comments

This adds helper macros to add process propagation to the LiveView async macros. It follows the same in-place replacement as OpentelemetryProcessPropagator.Task and OpentelemetryOban.

I wonder if there should be _with_span and _with_linked_span versions like the task module in process propagator?

Resolves: https://github.com/open-telemetry/opentelemetry-erlang-contrib/issues/302

danschultzer avatar Dec 16 '24 14:12 danschultzer

Turning this to draft until I can figure out how to make this not depend on :phoenix_live_view as per https://github.com/open-telemetry/opentelemetry-erlang-contrib/pull/433#issuecomment-2547269703:

Our instrumentation libraries cannot include dependencies on the library being instrumented. There are a few reasons for this but as you come up with ideas or proposals just know that is a hard constraint.

Maybe this should be a propagator library instead? Fits better with the process propagator library (in that case oban/req will probably need to be the same).

danschultzer avatar Dec 17 '24 01:12 danschultzer