Using OpenTelemetry Collector to collect traces

Note

Dapr directly writes traces using the OpenTelemetry (OTEL) protocol as the recommended method. For observability tools that support OTEL protocol, you do not need to use the OpenTelemetry Collector.

Dapr can also write traces using the Zipkin protocol. Previous to supporting the OTEL protocol, combining the Zipkin protocol with the enabled you to send traces to observability tools such as AWS X-Ray, Google Cloud Operations Suite, and Azure AppInsights. This approach remains for reference purposes only.

  1. A installation of Dapr on Kubernetes.

  2. You are already setting up your trace backends to receive traces.

  1. Apply the configuration with .

Next, set up both a Dapr configuration file to turn on tracing and deploy a tracing exporter component that uses the OpenTelemetry Collector.

  1. Create a collector-config.yaml file with this

  2. Apply the configuration with .

Some of the quickstarts such as already configure these settings, so if you are using those no additional settings are needed.

That’s it! There’s no need include any SDKs or instrument your application code. Dapr automatically handles the distributed tracing for you.

Deploy and run some applications. Wait for the trace to propagate to your tracing backend and view them there.

Last modified October 11, 2022: