Skip to content

[chore] add datadog extension documentation #30468

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from
Draft
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
23 changes: 14 additions & 9 deletions config/_default/menus/main.en.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -810,51 +810,56 @@ menu:
identifier: otel_health_metrics
parent: otel_integrations
weight: 803
- name: Datadog Extension
url: opentelemetry/integrations/datadog_extension/
identifier: otel_datadog_extension
parent: otel_integrations
weight: 804
- name: Docker Metrics
url: opentelemetry/integrations/docker_metrics/
identifier: otel_docker_metrics
parent: otel_integrations
weight: 804
weight: 805
- name: HAProxy Metrics
url: opentelemetry/integrations/haproxy_metrics/
identifier: otel_haproxy_metrics
parent: otel_integrations
weight: 805
weight: 806
- name: Host Metrics
url: opentelemetry/integrations/host_metrics/
identifier: otel_host_metrics
parent: otel_integrations
weight: 806
weight: 807
- name: IIS Metrics
url: opentelemetry/integrations/iis_metrics/
identifier: otel_iis_metrics
parent: otel_integrations
weight: 807
weight: 808
- name: Kafka Metrics
url: opentelemetry/integrations/kafka_metrics/
identifier: otel_kafka_metrics
parent: otel_integrations
weight: 808
weight: 809
- name: MySQL Metrics
url: opentelemetry/integrations/mysql_metrics/
identifier: otel_mysql_metrics
parent: otel_integrations
weight: 809
weight: 810
- name: NGINX Metrics
url: opentelemetry/integrations/nginx_metrics/
identifier: otel_nginx_metrics
parent: otel_integrations
weight: 810
weight: 811
- name: Runtime Metrics
url: opentelemetry/integrations/runtime_metrics/
identifier: otel_runtime_metrics
parent: otel_integrations
weight: 811
weight: 812
- name: Trace Metrics
url: opentelemetry/integrations/trace_metrics/
identifier: otel_trace_metrics
parent: otel_integrations
weight: 812
weight: 813
- name: Troubleshooting
url: opentelemetry/troubleshooting/
identifier: otel_troubleshooting
Expand Down
31 changes: 22 additions & 9 deletions content/en/infrastructure/list.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ further_reading:

## Overview

The Infrastructure list shows all of your hosts monitored by Datadog with activity during the last two hours (default) and up to one week. Search your hosts or group them by tags. In Datadog, navigate to [**Infrastructure > Hosts**][10] to view the Infrastructure list. This list should not be used to estimate your infrastructure host billing. See the [billing][11] page to learn about billing.
The Infrastructure list shows all of your hosts monitored by Datadog with activity during the last two hours (default) and up to one week. Search your hosts or group them by tags. In Datadog, navigate to [**Infrastructure > Hosts**][10] to view the Infrastructure list. This list should not be used to estimate your infrastructure host billing. See the [billing][11] page to learn about billing.

## Hosts

Expand Down Expand Up @@ -47,7 +47,7 @@ Load 15
Apps
: The Datadog integrations reporting metrics for the host.

Operating System
Operating System
: The tracked operating system.

Cloud Platform
Expand All @@ -74,6 +74,7 @@ Click on any host to view more details including:
- [containers][4]
- [logs][5] (if enabled)
- [Agent configuration](#agent-configuration) (if enabled)
- [OpenTelemetry Collector configuration](#opentelemetry-collector-configuration) (if enabled)

{{< img src="infrastructure/index/infra-list2.png" alt="Infrastructure list host details" style="width:100%;">}}

Expand All @@ -85,17 +86,26 @@ Datadog creates aliases for host names when there are multiple uniquely identifi

#### Agent configuration

The Agent can send its own configuration to Datadog to be displayed in the `Agent Configuration` section of the host detail panel.
With the [General Availability (GA) release of Fleet Automation][12], the Agent Configuration section has moved to [Fleet Automation][13] and is no longer displayed in the infrastructure list host detail panel. You can now view and manage Agent configurations across your entire infrastructure with enhanced visibility and control through Fleet Automation.

The Agent configuration is scrubbed of any sensitive information and only contains configuration you've set using the configuration file or environment variables. The configuration changes are updated every 10 minutes.
To access Agent configurations, use the **Open Host** dropdown button in the top-right corner of the host detail panel and select "View Agent Configurations" to go directly to the Fleet Automation UI. This provides advanced configuration management capabilities and fleet-wide visibility.

The Agent configuration view is enabled by default in Agent version >= 7.47.0/6.47.0. In Agent versions >= 7.39/6.39, you can enable it manually:
{{< img src="infrastructure/index/infra-list-config-4.png" alt="View Agent configurations in Fleet Automation" style="width:100%;">}}

To enable or disable the configuration view:
- Set the value of `inventories_configuration_enabled` in your [Agent configuration file][6] to `true` to enable the configuration view, or `false` to disable it.
- Alternatively, use the `DD_INVENTORIES_CONFIGURATION_ENABLED` environment variable to enable or disable the configuration view.
#### OpenTelemetry Collector configuration

{{< img src="infrastructure/index/infra-list-config3.png" alt="The Agent configuration view" style="width:100%;">}}
When the [Datadog Extension][14] is configured with your OpenTelemetry Collector, you can view collector configuration and build information directly in the infrastructure list host detail panel. The Datadog Extension provides visibility into your collector fleet from within the Datadog UI, making it easier to manage and debug your OpenTelemetry Collector deployments.

<div class="alert alert-info">The <a href="/opentelemetry/integrations/datadog_extension/">Datadog Extension</a> must be enabled and configured in your OpenTelemetry Collector. This component is only available in OpenTelemetry Collector Contrib version 0.129.0 or greater.</div>

To view OpenTelemetry Collector configurations:
1. Click on any host running the OpenTelemetry Collector in the infrastructure list
2. In the host detail panel, select the **OTel Collector** tab
3. View the build information and complete collector configuration

The displayed configuration is scrubbed of sensitive information. The data shown includes collector version, build details, component information, and the full configuration structure in YAML format.

{{< img src="infrastructure/index/infra-list-config-otel.png" alt="View OpenTelemetry Collector configurations in infrastructure list" style="width:100%;">}}

### Export

Expand Down Expand Up @@ -153,3 +163,6 @@ for host in infra['rows']:
[9]: https://github.com/DataDog/Miscellany/tree/master/get_hostname_agentversion
[10]: https://app.datadoghq.com/infrastructure
[11]: https://docs.datadoghq.com/account_management/billing/
[12]: https://app.datadoghq.com/release-notes/fleet-automation-is-now-generally-available
[13]: https://docs.datadoghq.com/agent/fleet_automation
[14]: /opentelemetry/integrations/datadog_extension/
4 changes: 3 additions & 1 deletion content/en/opentelemetry/integrations/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ Monitor and optimize your application's performance:
Monitor the health and performance of your OpenTelemetry Collector:

- [Collector Health Metrics][4] - Track the performance of your OpenTelemetry Collector
- [Datadog Extension][16] - View collector configuration and build information in Datadog Infrastructure Monitoring

### Containers and hosts

Expand Down Expand Up @@ -88,4 +89,5 @@ Monitor big data processing frameworks:
[12]: /opentelemetry/integrations/kafka_metrics/
[13]: /opentelemetry/integrations/spark_metrics/
[14]: /opentelemetry/mapping/metrics_mapping/#metrics-mappings
[15]: https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/receiver/dockerstatsreceiver/metadata.yaml
[15]: https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/receiver/dockerstatsreceiver/metadata.yaml
[16]: /opentelemetry/integrations/datadog_extension/
192 changes: 192 additions & 0 deletions content/en/opentelemetry/integrations/datadog_extension.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,192 @@
---
title: Datadog Extension
aliases:
further_reading:
- link: "/opentelemetry/setup/collector_exporter/"
tag: "Documentation"
text: "Setting Up the OpenTelemetry Collector"
- link: "/infrastructure/list/"
tag: "Documentation"
text: "Infrastructure List"
- link: "/infrastructure/resource_catalog/"
tag: "Documentation"
text: "Resource Catalog"
---

## Overview

<div class="alert alert-info">The Datadog Extension is in Preview and is subject to change.</div>

The Datadog Extension enables OpenTelemetry Collector configuration and build information to be viewed in the Datadog Infrastructure Monitoring application. When configured with the [Datadog Exporter][1], this extension provides visibility into your collector fleet directly within the Datadog UI.

{{< img src="/opentelemetry/integrations/datadog_extension_hostlist.png" alt="OpenTelemetry Collector configuration shown in Datadog Host List" style="width:100%;" >}}

## Key Features

- **Collector Configuration Visibility**: View complete collector configuration in the Infrastructure List and Resource Catalog
- **Build Information**: Display collector version, build details, and component information
- **Fleet Management**: Monitor and manage your OpenTelemetry Collector fleet from the Datadog UI
- **Local Inspection**: HTTP server endpoint for local debugging and configuration inspection

## Setup

### 1. Add the Datadog Extension to your collector configuration

Configure the Datadog Extension in your OpenTelemetry Collector configuration file:

```yaml
extensions:
datadog:
api:
key: ${env:DD_API_KEY}
site: {{< region-param key="dd_site" >}}
hostname: "my-collector-host" # Optional: must match Datadog Exporter hostname if set

service:
extensions: [datadog]
```

### 2. Configure the Datadog Exporter

Ensure your collector is also configured with the Datadog Exporter:

```yaml
exporters:
datadog/exporter:
api:
key: ${env:DD_API_KEY}
site: {{< region-param key="dd_site" >}}
hostname: "my-collector-host" # Optional: must match Datadog Extension hostname if set
```

### 3. Enable the extension in your service configuration

Add the Datadog Extension to your service extensions:

```yaml
service:
extensions: [datadog]
pipelines:
traces:
receivers: [otlp]
processors: [batch]
exporters: [datadog/exporter]
metrics:
receivers: [otlp]
processors: [batch]
exporters: [datadog/exporter]
```

## Configuration Options

| Parameter | Description | Default |
|-----------|-------------|---------|
| `api.key` | Datadog API key (required) | - |
| `api.site` | Datadog site (e.g., `us5.datadoghq.com`) | `datadoghq.com` |
| `hostname` | Custom hostname for the collector | Auto-detected |
| `http.endpoint` | Local HTTP server endpoint | `localhost:9875` |
| `http.path` | HTTP server path for metadata | `/metadata` |
| `proxy_url` | HTTP proxy URL for outbound requests | - |
| `timeout` | Timeout for HTTP requests | `30s` |
| `tls.insecure_skip_verify` | Skip TLS certificate verification | `false` |

### Complete Configuration Example

```yaml
extensions:
datadog:
api:
key: ${env:DD_API_KEY}
site: {{< region-param key="dd_site" >}}
hostname: "my-collector-host"
http:
endpoint: "localhost:9875"
path: "/metadata"
proxy_url: "http://proxy.example.com:8080"
timeout: 30s
tls:
insecure_skip_verify: false

exporters:
datadog/exporter:
api:
key: ${env:DD_API_KEY}
site: {{< region-param key="dd_site" >}}
hostname: "my-collector-host"

service:
extensions: [datadog]
pipelines:
traces:
receivers: [otlp]
processors: [batch]
exporters: [datadog/exporter]
metrics:
receivers: [otlp]
processors: [batch]
exporters: [datadog/exporter]
```

## Viewing Collector Configuration

Once configured, you can view your OpenTelemetry Collector configuration and build information in two locations:

### Infrastructure List (Host List)

1. Navigate to **Infrastructure > Hosts** in your Datadog account
2. Click on any host running the OpenTelemetry Collector (note: filtering by `field:apps:otel` will show only collector instances)
3. In the host details panel, select the **OTel Collector** tab
4. View the build info and full collector configuration

### Resource Catalog

1. Navigate to **Infrastructure > Resource Catalog** in your Datadog account
2. Filter for hosts or search for your collector instances
3. Click on any host running the OpenTelemetry Collector
4. Scroll down to **Collector** to view build info and full configuration

## Local HTTP Server

The Datadog Extension includes a local HTTP server for debugging and inspection:

```bash
# Access collector metadata locally
curl http://localhost:9875/metadata
```

This endpoint provides:
- Collector configuration (scrubbed of sensitive information)
- Build information and version details
- Active component list
- Extension status

## Important Notes

<div class="alert alert-warning">
<strong>Hostname Matching</strong>: If you specify a custom <code>hostname</code> in the Datadog Extension, it must match the <code>hostname</code> value in the Datadog Exporter configuration. If left unset in both components, the auto-detected hostname will match correctly.
</div>

<div class="alert alert-info">
The Datadog Extension is in Preview and functionality may change as Datadog infrastructure monitoring features evolve. For the latest updates, watch the <a href="https://www.datadoghq.com/blog/">Datadog blog</a> and the <a href="https://github.com/open-telemetry/opentelemetry-collector-contrib">OpenTelemetry Collector Contrib repository</a>.
</div>

## Troubleshooting

### Configuration Not Appearing

1. **Check hostname matching**: Ensure hostnames match between Datadog Extension and Datadog Exporter
2. **Verify API key**: Confirm the API key is valid and has appropriate permissions
3. **Check collector logs**: Look for extension initialization and data submission logs
4. **Confirm extension is enabled**: Verify the extension is listed in the service configuration

### HTTP Server Issues

1. **Port conflicts**: Ensure port 9875 is available or configure a different port
2. **Network access**: Verify the HTTP server is accessible from your debug location
3. **Check logs**: Review extension logs for HTTP server startup issues

## Further Reading

{{< partial name="whats-next/whats-next.html" >}}

[1]: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/exporter/datadogexporter
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading