spandex_phoenix v1.0.0 SpandexPhoenix.Telemetry

Defines the :telemetry handlers to attach tracing to Phoenix Telemetry.

Link to this section Summary

Functions

Installs :telemetry event handlers for Phoenix Telemetry events.

Link to this section Functions

Link to this function

install(opts \\ [])

Installs :telemetry event handlers for Phoenix Telemetry events.

Options

  • :tracer (Atom)

    The tracing module to be used for traces in your Endpoint. Default: Application.get_env(:spandex_phoenix, :tracer)

  • :filter_traces (fun((Plug.Conn.t()) -> boolean))

    A function that takes a conn and returns true if a trace should be created for that conn, and false if it should be ignored. Default: fn _ -> true end (include all)

  • :span_name (String.t())

    The name for the span this module creates. Default: "request"

  • :customize_metadata (fun((Plug.Conn.t()) -> Keyword.t()))

    A function that takes a conn and returns a keyword list of metadata. Default: &SpandexPhoenix.default_metadata/1