Skip to content

Distributed HTTP Telemetry#115

Open
patrickleet wants to merge 2 commits into
mainfrom
tasks--distributed-http-telemetry-1
Open

Distributed HTTP Telemetry#115
patrickleet wants to merge 2 commits into
mainfrom
tasks--distributed-http-telemetry-1

Conversation

@patrickleet

Copy link
Copy Markdown
Collaborator

Summary

  • add bounded HTTP server request counter and duration metrics for Distributed-owned routers
  • add shared Axum HTTP telemetry middleware with optional OTEL SERVER spans parented from incoming W3C trace context
  • cover command HTTP, metrics-only, and Knative CloudEvents routers plus docs for request-vs-dispatch boundaries and privacy rules

Acceptance Criteria Addressed

  • GET /health, GET /metrics, command HTTP success/unknown/pre-dispatch rejection, and Knative CloudEvents ingress record HTTP request metrics with route templates only
  • Prometheus exposition includes the new HTTP metric families and is covered by promtool-compatible integration test output
  • metric labels are bounded to service/method/route/status_code and existing framework labels; tests assert raw paths, queries, trace IDs, user IDs, aggregate IDs, headers, and payload data are not emitted
  • existing dispatch metrics remain intact, including unknown commands bucketed as message="unknown"
  • http, http+metrics, http+otel, and http+metrics+otel feature combinations compile
  • OTLP integration test covers HTTP span parenting and dispatch span child relationship when collector env is available
  • docs updated in metrics, observability, transports, and README

Local Validation

  • cargo check --no-default-features --features http
  • cargo check --no-default-features --features http,metrics
  • cargo check --no-default-features --features http,otel
  • cargo check --no-default-features --features http,metrics,otel
  • cargo clippy --all-targets --no-default-features --features http,metrics,otel -- -D warnings
  • cargo test --no-default-features --features http,metrics,otel
  • cargo test --lib --no-default-features --features http,metrics
  • cargo test --test microsvc --no-default-features --features http,metrics
  • cargo test --test knative_cloudevents --no-default-features --features http,metrics
  • cargo test --test metrics_exposition --no-default-features --features http,metrics
  • cargo test --test otel_export --no-default-features --features http,otel
  • git diff --check

Implements [[tasks/distributed-http-telemetry-1]]
@coderabbitai

coderabbitai Bot commented Jul 7, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@patrickleet, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 8 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: ae790333-95ac-4a4d-b3bc-42119e164410

📥 Commits

Reviewing files that changed from the base of the PR and between 84a72f1 and 82f5a82.

📒 Files selected for processing (15)
  • README.md
  • docs/metrics.md
  • docs/observability.md
  • docs/transports.md
  • src/http_telemetry.rs
  • src/lib.rs
  • src/metrics.rs
  • src/microsvc/http.rs
  • src/microsvc/knative_ingress.rs
  • src/telemetry.rs
  • src/trace_context.rs
  • tests/knative_cloudevents/main.rs
  • tests/metrics_exposition/main.rs
  • tests/microsvc/transport_http.rs
  • tests/otel_export/main.rs
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch tasks--distributed-http-telemetry-1

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Implements [[tasks/distributed-http-telemetry-1]]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant