#telemetry #datadog #telemetry-data #send #tracing #datadoghq #metrics-collection

libdd-telemetry

Telemetry client allowing to send data as described in https://docs.datadoghq.com/tracing/configure_data_security/?tab=net#telemetry-collection

2 stable releases

2.0.0 Jan 21, 2026
1.0.0 Nov 17, 2025

#646 in Web programming

Download history 233/week @ 2025-11-13 398/week @ 2025-11-20 361/week @ 2025-11-27 378/week @ 2025-12-04 648/week @ 2025-12-11 1109/week @ 2025-12-18 480/week @ 2025-12-25 267/week @ 2026-01-01 2465/week @ 2026-01-08 2002/week @ 2026-01-15 2528/week @ 2026-01-22 2732/week @ 2026-01-29

9,827 downloads per month
Used in 4 crates (3 directly)

Apache-2.0

295KB
6.5K SLoC

libdd-telemetry

Internal telemetry library for reporting Datadog library metrics and events.

Overview

libdd-telemetry provides telemetry collection and reporting for Datadog libraries, allowing them to report their own operational metrics, configuration, and errors back to Datadog.

Features

  • Metrics Collection: Collect library performance metrics
  • Configuration Reporting: Report library configuration
  • Error Tracking: Track and report library errors
  • Host Information: Automatic host and container metadata
  • HTTP Transport: Send telemetry data to Datadog intake
  • Worker Pattern: Async background telemetry worker
  • Dependency Tracking: Report library dependencies
  • Application Metadata: Track application information

Modules

  • config: Telemetry configuration
  • data: Telemetry data types and structures
  • info: System and host information gathering
  • metrics: Metrics collection and aggregation
  • worker: Background telemetry worker

Telemetry Data Types

The library collects and reports:

  • Metrics: Count, gauge, rate, and distribution metrics
  • Logs: Library log events
  • Configurations: Library configuration changes
  • Dependencies: Loaded library versions
  • Integrations: Active integrations
  • App Started: Application lifecycle events

Example Usage

use libdd_telemetry::{build_host, data};

// Build host information
let host = build_host();

// Create telemetry data
let app = data::Application {
    service_name: "my-service".to_string(),
    env: Some("production".to_string()),
    // ...
};

Host Information

Automatically gathers:

  • Hostname
  • Container ID
  • OS name and version
  • Kernel information
  • Entity ID

Dependencies

~16–59MB
~1M SLoC