Skip to content

Align mocha headers with W3C #9319

Merged
PascalSenn merged 4 commits intomainfrom
pse/align-mocha-with-trace-standard
Mar 8, 2026
Merged

Align mocha headers with W3C #9319
PascalSenn merged 4 commits intomainfrom
pse/align-mocha-with-trace-standard

Conversation

@PascalSenn
Copy link
Copy Markdown
Member

No description provided.

Copilot AI review requested due to automatic review settings March 7, 2026 00:23
@PascalSenn PascalSenn changed the title Align mocha with tracing standards Align mocha headers with W3C Mar 7, 2026
@github-actions github-actions Bot added the 📚 documentation This issue is about working on our documentation. label Mar 7, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates Mocha’s tracing header propagation to follow W3C Trace Context semantics (traceparent/tracestate) across message headers and related OpenTelemetry integration points.

Changes:

  • Replace custom trace header keys (trace-id/span-id/etc.) with W3C traceparent and tracestate.
  • Update WithActivity header injection behavior and related unit tests.
  • Update receive/outbox activity parent context creation to derive from traceparent (+ optional tracestate).

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
src/Mocha/test/Mocha.Tests/Telemetry/OpenTelemetryTests.cs Updates tests to assert W3C traceparent/tracestate propagation and adds coverage for unsampled flags.
src/Mocha/src/Mocha/Observability/OpenTelemetryDiagnosticObserver.cs Switches receive-side parent context construction to parse W3C traceparent and read tracestate.
src/Mocha/src/Mocha/Observability/OpenTelemetry.cs Changes header injection from separate IDs to traceparent (+ conditional tracestate).
src/Mocha/src/Mocha/Headers/MessageHeaders.cs Replaces legacy tracing header keys with W3C Trace Context keys/constants.
src/Mocha/src/Mocha.EntityFrameworkCore.Postgres/Outbox/OutboxProcessor.cs Switches outbox send-side parent context construction to parse W3C traceparent and read tracestate.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Mocha/src/Mocha/Observability/OpenTelemetry.cs Outdated
Comment thread src/Mocha/src/Mocha/Observability/OpenTelemetryDiagnosticObserver.cs Outdated
Comment thread src/Mocha/src/Mocha.EntityFrameworkCore.Postgres/Outbox/OutboxProcessor.cs Outdated
Comment thread src/Mocha/src/Mocha/Observability/OpenTelemetryDiagnosticObserver.cs Outdated
@PascalSenn PascalSenn merged commit ba572dd into main Mar 8, 2026
241 of 243 checks passed
@PascalSenn PascalSenn deleted the pse/align-mocha-with-trace-standard branch March 8, 2026 15:01
@codecov
Copy link
Copy Markdown

codecov Bot commented Mar 8, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 0.00%. Comparing base (a090dd0) to head (4d89a03).
⚠️ Report is 6 commits behind head on main.

Additional details and impacted files
@@     Coverage Diff      @@
##   main   #9319   +/-   ##
============================
============================

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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

Labels

📚 documentation This issue is about working on our documentation.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants