Skip to content

[DOCS] Rust ADK: OTLP trace export (telemetry feature) #478

Closed

Description

Summary

The Rust ADK now supports OTLP trace (span) export behind an optional telemetry Cargo feature (rust-adk PR #117, closes rust-adk issue #112). This is a user-facing capability that the docs site should cover so users know how to enable and configure it.

New/relevant surface:

  • telemetry Cargo feature: cargo build --features telemetry.
  • telemetry::init(&config.telemetry_config, service_name, service_version) -> Result<TelemetryGuard>; hold the guard for the process lifetime so batched spans flush on shutdown.
  • Env vars: A2A_TELEMETRY_ENABLE, A2A_TELEMETRY_ENDPOINT, A2A_OTEL_TRACES_EXPORTER (otlp default / none), plus standard OTEL_* passthrough.
  • Endpoint precedence: A2A_TELEMETRY_ENDPOINT, else standard OTEL_EXPORTER_OTLP_ENDPOINT resolution (default http://localhost:4318).
  • Spans emitted: a2a.request (server span on POST /a2a, with remote-context extraction) and task.process (per background task).
  • HTTP/protobuf transport only; no gRPC/tonic, no metrics.

Affected pages

  • Rust ADK observability / telemetry page (new or existing).
  • Any "Cargo features" / build-configuration reference for the Rust ADK.

Link

Acceptance Criteria

  • Document the telemetry Cargo feature and the --features telemetry build.
  • Document telemetry::init usage and the let _guard lifetime requirement.
  • Document the four env vars, endpoint precedence, and the otlp/none exporter switch.
  • Note the emitted spans (a2a.request, task.process) and the HTTP/protobuf-only scope.

Activity

  1. added
    documentation
    on Jul 24, 2026
  2. edenreich commented on Jul 27, 2026

    @edenreich
    Contributor

    @claude Can you work on this? use /ponytail:ponytail also check if it's relevant before implementing it.

  3. added theissue type on Jul 27, 2026
  4. inference-gateway-maintainer commented on Jul 27, 2026

    @inference-gateway-maintainer
    ContributorAuthor

    Claude finished @edenreich's task in 4m 40s —— View job • feat/issue-478-20260727-1516 • [Create PR ➔](https://github.com/inference-gateway/docs/compare/main...feat/issue-478-20260727-1516?quick_pull=1&title=Issue%20%23478%3A%20Changes%20from%20Claude&body=This%20PR%20addresses%20issue%20%23478%0A%0AGenerated%20with%20%5BClaude%20Code%5D(https%3A%2F%2Fclaude.ai%2Fcode)


    Rust ADK OTLP telemetry docs - done

    Checked relevance first: this is relevant. The telemetry Cargo feature and telemetry::init were undocumented, and - confirmed against the rust-adk source (src/config.rs, src/telemetry.rs, Cargo.toml, PR #117) - the existing env-var Telemetry table fabricated OTEL_METRICS_EXPORTER / Prometheus rows. The Rust ADK TelemetryConfig has only three fields; it is traces-only, HTTP/protobuf-only, no metrics. So this was both a docs-gap and a correctness fix.

    • Read rust-adk.md, assessed relevance, verified facts against upstream source
    • Confirmed edits fall outside the GENERATED:* markers (generator unaffected)
    • Documented the telemetry Cargo feature + --features telemetry build (Installation table + new section)
    • Documented telemetry::init usage + the let _guard lifetime requirement (with the compiled-out warn! fallback)
    • Documented the env vars, endpoint precedence, and otlp/none switch
    • Documented emitted spans (a2a.request, task.process) and HTTP/protobuf-only scope
    • Fixed the fabricated metrics/Prometheus rows in the env-var reference
    • Validated: bun run lint:md, bun run format:check, bun test, bun run build - all pass

    Changes (rust-adk.md):

    1. Installation: added telemetry to the Cargo-features table.
    2. New ## Telemetry section: feature build, telemetry::init + guard example, warn! fallback, emitted spans, traces-only/HTTP-protobuf scope, and a config table with endpoint precedence.
    3. Env-var reference: corrected the Telemetry table to the three real A2A_* vars plus the OTEL_EXPORTER_OTLP_ENDPOINT passthrough (default http://localhost:4318); removed the non-existent metrics/Prometheus rows.

    PR: #482

    • branch: feat/issue-478-20260727-1516
  5. moved this from Todo to In progress in 2026on Jul 27, 2026
  6. moved this from In progress to QA in 2026on Jul 27, 2026
  7. moved this from QA to Done in 2026on Jul 27, 2026
  8. inference-gateway-releaser commented on Jul 27, 2026

    @inference-gateway-releaser
    Contributor

    🎉 This issue has been resolved in version 0.9.5 🎉

    The release is available on GitHub release

    Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationreleased

    Type

    Projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions