Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 31 additions & 7 deletions content/en/opentelemetry/config/environment_variable_support.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,12 @@ The precedence rules on this page describe how *Datadog SDKs* resolve configurat
**Note**: Even when `DD_METRICS_OTEL_ENABLED=true`, standard Runtime Metrics are still emitted through DogStatsD.

## Datadog SDK configuration
These environment variables enable the Datadog SDK to ingest OpenTelemetry Metrics and Logs API data. For guides on how to instrument your application, see the [language-specific instrumentation documentation][14].
These environment variables enable the Datadog SDK to ingest OpenTelemetry Traces, Metrics, and Logs API data. For guides on how to instrument your application, see the [language-specific instrumentation documentation][14].

`DD_TRACE_OTEL_ENABLED`
: **Description**: Enables the Datadog SDK's OpenTelemetry interoperability for traces. <br>
**Default**: `false`<br>
**Notes**: The default is `true` in the Java SDK.
**Notes**: This configuration only enables the OpenTelemetry Tracing API. See `OTEL_TRACES_EXPORTER` to emit traces using OTLP.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
**Notes**: This configuration only enables the OpenTelemetry Tracing API. See `OTEL_TRACES_EXPORTER` to emit traces using OTLP.
**Note**: This configuration only enables the OpenTelemetry Tracing API. See `OTEL_TRACES_EXPORTER` to emit traces using OTLP.


`DD_METRICS_OTEL_ENABLED`
: **Description**: Enables the automatic instrumentation components of the Datadog SDK to collect and emit metrics generated by the OTel Metrics API. <br>
Expand Down Expand Up @@ -100,11 +100,6 @@ Mapped values between `OTEL_TRACES_SAMPLER` & `DD_TRACE_SAMPLE_RATE`:<br>
- `always_off`|`0.0`
- `traceidratio`|`${OTEL_TRACES_SAMPLER_ARG}`

`OTEL_TRACES_EXPORTER`
: **Datadog convention**: `DD_TRACE_ENABLED=false` <br>
Trace exporter to be used<br>
**Notes**: Only a value of `none` is accepted<br>

`OTEL_METRICS_EXPORTER`
: **Description**: Specifies the metrics exporter to be used. <br>
**Notes**: The only accepted values are `otlp` and `none`. A value of `none` disables the emission of OTel metrics, as well as APM runtime metrics (equivalent to `DD_RUNTIME_METRICS_ENABLED=false`) <br>
Expand Down Expand Up @@ -205,6 +200,24 @@ For more details on the official specification for these variables, see the [Ope
: **Description**: Specifies the timeout (in milliseconds) for a single outgoing OTLP logs request. Takes precedence over the general `OTEL_EXPORTER_OTLP_TIMEOUT`. <br>
**Default**: `10000` (10s).

### Traces-specific OTLP configuration
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
### Traces-specific OTLP configuration
### Trace-specific OTLP configuration


For more details on the official specification for these variables, see the [OpenTelemetry Protocol Exporter documentation][13].

`OTEL_EXPORTER_OTLP_TRACES_PROTOCOL`
: **Description**: Specifies the OTLP transport protocol for traces. Takes precedence over `OTEL_EXPORTER_OTLP_PROTOCOL`. <br>
**Accepted values**: `grpc`, `http/protobuf`, `http/json`. <br>
**Default**: SDK-dependent. The Datadog SDK aims to match the default protocol of the corresponding official OpenTelemetry SDK for that language.

`OTEL_EXPORTER_OTLP_TRACES_ENDPOINT`
: **Description**: Specifies the URL for sending OTLP trace data. Takes precedence over `OTEL_EXPORTER_OTLP_ENDPOINT`. <br>
**Default (gRPC)**: `http://localhost:4317`. <br>
**Default (HTTP)**: `http://localhost:4318/v1/traces`. <br>
**Notes**: For HTTP protocols, the SDK automatically appends `/v1/traces` if the general `OTEL_EXPORTER_OTLP_ENDPOINT` is used as a fallback.

`OTEL_EXPORTER_OTLP_TRACES_HEADERS`
: **Description**: Specifies a comma-separated list of key-value pairs to be used as headers on outgoing OTLP trace requests (for example, `api-key=key,other-config=value`). Takes precedence over the general `OTEL_EXPORTER_OTLP_HEADERS`.

## OpenTelemetry Metrics SDK configuration

Datadog SDKs support the following OpenTelemetry Metrics SDK options.
Expand Down Expand Up @@ -250,6 +263,17 @@ Datadog SDKs support the following OpenTelemetry Logs SDK options.
: **Description**: The maximum number of log records in a single OTLP payload. <br>
**Default**: `512`

## OpenTelemetry Traces SDK configuration

Datadog SDKs support the following OpenTelemetry Traces SDK options.

`OTEL_TRACES_EXPORTER`
: **Description**: Specifies the trace exporter to be used. <br>
**Accepted values**: `otlp`, `none`. A value of `none` disables the emission of OTel and Datadog traces. <br>
**Default**: `otlp`
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
**Default**: `otlp`
**Default**: `otlp`<br>

**Notes**: The Java SDK requires `DD_TRACE_OTEL_ENABLED=true` for this configuration to take effect.<br>
OTLP export is not available for the Ruby, PHP, or Rust language SDKs.
Comment on lines +274 to +275
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
**Notes**: The Java SDK requires `DD_TRACE_OTEL_ENABLED=true` for this configuration to take effect.<br>
OTLP export is not available for the Ruby, PHP, or Rust language SDKs.
**Notes**:
- The Java SDK requires `DD_TRACE_OTEL_ENABLED=true` for this configuration to take effect.
- OTLP export is not available for the Ruby, PHP, or Rust SDKs.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two suggestions here:

  • Remove language as this seems to be the only place in the file that SDKs are referred to as language SDKs.
  • Add the two distinct notes as an unordered list to make them easier to notice and scan.


## Java-specific configuration
Datadog SDKs support the following Java-specific OpenTelemetry configuration options. For more information, see the [OpenTelemetry documentation on Java agent configuration][10].

Expand Down
2 changes: 1 addition & 1 deletion layouts/shortcodes/otel-network-requirements.en.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ When using the Datadog SDK with OpenTelemetry API support, telemetry is routed t

| Signal Source | Protocol | Port | Destination Component |
|---------------|----------|------|----------------------|
| OTel Metrics and Logs API | OTLP (gRPC/HTTP) | 4317 / 4318 | Datadog Agent OTLP Receiver or DDOT Collector |
| OTel Metrics, Logs, and Traces | OTLP (gRPC/HTTP) | 4317 / 4318 | Datadog Agent OTLP Receiver or DDOT Collector |
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This uses the order Metrics, Logs, and Traces but the other file (line 51) uses Traces, Metrics, and Logs. Should one or the other be updated for consistency?

| Datadog Tracing | Datadog trace intake | 8126 (TCP) | Datadog Trace Agent |
| Runtime Metrics | DogStatsD | 8125 (UDP) | DogStatsD Server |
Loading