Skip to content

feat: add --enable-otel-metrics to export OpenTelemetry metrics from the workers - #765

Draft
johnstonmatt wants to merge 1 commit into
mainfrom
FUNC-1028/functions/slos/otel-metrics
Draft

johnstonmatt wants to merge 1 commit into
mainfrom
FUNC-1028/functions/slos/otel-metrics

Conversation

@johnstonmatt

Copy link
Copy Markdown
Contributor

Adds --enable-otel-metrics. With it, the main and event workers that --enable-otel instruments also export OpenTelemetry metrics, not only traces. Without it nothing changes.

The Edge Functions ingress needs this to push its availability counter to the regional OpenTelemetry collector (FUNC-1028). Today server.rs builds the workers' OtelConfig with tracing_enabled: true and leaves metrics_enabled at its default, so metrics.getMeter() in the main worker returns a no-op meter.

Verification

  • cargo check -p cli and cargo fmt --check pass.
  • The same vendored deno_telemetry code, run through stock Deno 2.9.8 with metrics on, pushed an @opentelemetry/api counter to an ADOT collector that wrote it to VictoriaMetrics.

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