Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/h3poteto/opentelemetry_phoenixchannel

Telemetry handler that creates Opentelemetry spans for Phoenix.Channels events
https://github.com/h3poteto/opentelemetry_phoenixchannel

elixir opentelemetry phoenix-channels telemetry

Last synced: 3 months ago
JSON representation

Telemetry handler that creates Opentelemetry spans for Phoenix.Channels events

Awesome Lists containing this project

README

        

# OpentelemetryPhoenixchannel

Telemetry handler that creates Opentelemetry spans from Phoenix.Channels events.

## Installation

This package can be installed by adding `opentelemetry_phoenixchannel` to your list of dependencies in `mix.exs`:

```elixir
def deps do
[
{:opentelemetry_phoenixchannel, "~> 0.1.0"}
]
end
```

## Usage
After installing, setup the handler in your application behaviour before your top-level supervisor starts.

```elixir
def start(_type, _args) do
OpentelemetryPhoenixchannel.setup()

children = [
{Phoenix.PubSub, name: MyApp.PubSub},
MyAppWeb.Endpoint
]

opts = [strategy: :one_for_one, name: MyStore.Supervisor]
Supervisor.start_link(children, opts)
end
```

## License
The software is available as open source under the terms of the [MIT License](https://opensource.org/license/MIT).