Skip to content

feat(hub): add explicit telemetry foundation - #165

Merged
nshki merged 3 commits into
build/hub/newfrom
copilot/hub-telemetry-foundation
Oct 30, 2026
Merged

nshki merged 3 commits into
build/hub/newfrom
copilot/hub-telemetry-foundation

Conversation

Copilot AI commented Oct 30, 2026

Copy link
Copy Markdown
Contributor

Why

Feature ports to the Express Hub need a consistent way to record server-side traces and send them to an operator's chosen recipient. This carries forward the provider-neutral approach from #34 without porting Rails instrumentation or treating sampled traces as durable product analytics.

What changes

Adds two public functions under integrations/opentelemetry: startTelemetry() owns validated configuration and SDK lifetime, and withTelemetrySpan() records an operation while preserving its result, failure, and asynchronous parent context. Export is disabled by default and supports OTLP over HTTP/protobuf with bounded batching and shutdown. Span attributes accept only approved UUID identifiers; exception details and export credentials stay out of telemetry diagnostics.

API and worker entrypoints initialize telemetry and flush it after active work drains. The API gains bounded graceful shutdown for this lifecycle. Application imports remain static; automatic instrumentation, cross-process propagation, and product analytics remain outside this foundation.

The new telemetry guide documents configuration, ownership, safe feature-port examples, architecture boundaries, and future extension rules. Hub instructions and the documentation index link to it so future agents can find the contract.

Created from a Slack conversation.

Co-authored-by: Nishiki <1121087+nshki@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI auto review requested due to automatic review settings October 30, 2026 16:21
Copilot AI requested review from a team and nshki as code owners October 30, 2026 16:22

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because there is no eligible user to bill.

An enterprise owner can allow the organization to be billed for reviews like this by enabling Copilot code review for users without a license.

Copilot AI and others added 2 commits October 30, 2026 17:02
Co-authored-by: Nishiki <1121087+nshki@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Nishiki <1121087+nshki@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@nshki
nshki merged commit 7d07109 into build/hub/new Oct 30, 2026
26 checks passed
@nshki
nshki deleted the copilot/hub-telemetry-foundation branch October 30, 2026 20:41
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.

5 participants