Dash0 Logo
Infrastructure MonitoringLog ManagementApplication Performance ManagementDistributed TracingKubernetes MonitoringDashboardsAlertingService MapIntegrationsTransparent CostObservability as Code
PricingDocs
GuidesBlogKnowledgePodcastIntegrationsChangelog
Contact usMeet our TeamCareersSecurity
  • Book A Demo
  • Sign In
  • Start Free Trial
Book a demoSign in
Start Free Trial

Resources

  • Pricing
  • Blog
  • Knowledge
  • Integrations
  • Documentation
  • Glossary
  • OTelBin.io
  • Sitemap

Company

  • Our Team
  • Careers
  • Security

Contact

  • Contact us
  • GitHub
  • LinkedIn
  • X
  • YouTube
  • Dash0 Newsletter
Subscribe to our newsletter

Receive updates on OTelBin, Dash0, Observability, OpenTelemetry, and more.

  • Terms and Conditions
  • Privacy Policy
  • Data Processing Agreement
  • Vulnerability Disclosure

©2025 Dash0 Inc.

Hub/Erlang

Technology

Erlang

Observe Elixir Phoenix apps in real-time. Gain insights into your application's performance and health with Dash0's monitoring tools.

Overview

Overview

Instrumenting your Erlang Elixir Phoenix application to generate traces, logs, and metrics is a powerful way to gain deep insights into its behavior and performance. For example, to get a clearer picture of your Phoenix apps and the database statements generated through Ecto. By adding instrumentation, you enable your application to emit valuable data that can be used for monitoring, troubleshooting, and optimization.

Dash0 supports automatic instrumentation of Phoenix applications through OpenTelemetry's open-source and vendor-agnostic helper functions.

Use Cases

  • Understand outgoing and incoming HTTP requests through traces and metrics. Allowing drill-downs to the database level.
  • You can see which database statements were executed and how long they took, which gives you valuable data to optimize your applications.
  • Reveal (uncaught) errors and the context in which they happened.
  • Get deep visibility into your Phoenix apps.

Setup

Prerequisites

This guide assumes you are having a Phoenix application running on Erlang using the Cowboy2 adapter:

Add Required OTel SDK dependencies

Add the required :tls_certificate_check application to your mix.exs file.

Then add the following dependencies to your mix.exs file.

Configure the Exporter

To send data now to Dash0, you need to configure the exporter in your config.exs:

Activate OTel Support for Phoenix and Ecto

In your application start function (for example in lib/myapp/application.ex) add the required setup calls:

We also recommend that you configure the service name by overriding the OTEL_SERVICE_NAME environment variable or setting it in config.exs:

Kubernetes Setup

In case you are not using the Dash0 operator for Kubernetes to deploy your application, you should extend the OpenTelemetry resource attributes to include the Pod UID. This is important to merge the resources between logs,traces and metrics. You can do this by adding the following environment variables to your deployment:

This will add the k8s.pod.name and k8s.pod.uid attributes to the OpenTelemetry resource attributes, which will be included in all telemetry data sent to Dash0. To read more about resource equality and merging, please refer to the Dash0 docs.

In order to learn more about the importance of resource attributes read the blog post OpenTelemetry resource attributes: Best practices for Kubernetes