News KrakenD Enterprise v2.6 released with OpenTelemetry, FIPS-140, gRPC server and more

Enterprise Documentation

Recent changes

You are viewing a previous version of KrakenD Enterprise Edition (v2.0) , go to the latest version

Exporting traces to Datadog

Document updated on Jun 15, 2022

Exporting traces to Datadog

Datadog is a cloud monitoring and security platform for developers, IT operations teams, and businesses.

Datadog configuration

The Opencensus exporter allows you to export data to Datadog. Enabling it only requires you to add the datadog exporter in the opencensus module.

The following configuration snippet sends data to your Datadog:

      "extra_config": {
        "telemetry/opencensus": {
          "exporters": {
            "datadog": {
              "tags": [
              "global_tags": {
                "env": "prod"
              "disable_count_per_buckets": true,
              "trace_address": "localhost:8126",
              "stats_address": "localhost:8125",
              "namespace": "krakend",
              "service": "gateway"

  • namespace(string) the namespace to which metric keys are appended.
  • tags (list) specifies a set of global tags to attach to each metric
  • global_tags (object) GlobalTags holds a set of tags (key/value) that will automatically be applied to all exported spans.
  • service (string) Service specifies the service name used for tracing
  • trace_address (string) TraceAddr specifies the host[:port] address of the Datadog Trace Agent. It defaults to localhost:8126.
  • stats_address (string) StatsAddr specifies the host[:port] address for DogStatsD. It defaults to localhost:8125. To enable ingestion using Unix Domain Socket (UDS) mount your UDS path and reference it in the stats_address using a path like unix:///var/run/datadog/dsd.socket.
  • disable_count_per_buckets (bool) Specifies whether to emit count_per_bucket metrics

See also the additional settings of the Opencensus module that can be declared.

B3 propagation

The Opencensus module uses B3 style propagation headers, while the rest of your services might be using datadog-specific propagation headers. If this difference is actual, krakend traces will show up in Datadog but they won’t be connected to the frontend and backend traces.

The ddtrace-run adds an option to support B3 style propagation using the environment variables DD_TRACE_PROPAGATION_STYLE_EXTRACT and DD_TRACE_PROPAGATION_STYLE_INJECT. Use these variables to have your traces perfectly aligned.

For more information see its configuration.


Unresolved issues?

The documentation is only a piece of the help you can get! Whether you are looking for Open Source or Enterprise support, see more support channels that can help you.