Skip to content

feat(onboarding): Add metrics onboarding for Rust, Elixir, and Ruby#115998

Draft
dingsdax wants to merge 6 commits into
masterfrom
add-missing-metrics-sdk-getting-started
Draft

feat(onboarding): Add metrics onboarding for Rust, Elixir, and Ruby#115998
dingsdax wants to merge 6 commits into
masterfrom
add-missing-metrics-sdk-getting-started

Conversation

@dingsdax
Copy link
Copy Markdown

Add metrics getting-started onboarding docs for Rust and Elixir, and improve the existing Ruby metrics onboarding to align with other SDKs and official documentation.

Rust — New metrics.tsx with sentry::metrics API (counter, gauge, distribution with .capture() builder pattern), requiring metrics feature flag in Cargo.toml. Wired into rust/index.tsx and registered in withMetricsOnboarding.

Elixir — New metrics.tsx with Sentry.Metrics module API (count, gauge, distribution with keyword args). Wired into elixir/index.tsx, registered in withMetricsOnboarding, and removed from withoutPerformanceSupport.

Ruby — Updated existing metrics.tsx to use Sentry.metrics accessor style (matching official SDK docs and YARD documentation) instead of Sentry::Metrics module constant. Replaced generic example names (test-counter, my_attribute) with realistic ones from the docs (button_click, browser: 'Firefox').

All three SDKs — Added trailing "For more detailed information, see the metrics documentation" ExternalLink to match the pattern used by Python, Java, and .NET onboarding files.

Code snippets were verified against the official docs at docs.sentry.io and the sentry-ruby SDK source for API accuracy.

Also includes product availability changes from a prior commit: adds METRICS to Ruby/Rack/Rails and adds PERFORMANCE_MONITORING, LOGS, METRICS for Elixir and Rust in platformProductAvailability.

junior[bot] and others added 2 commits May 13, 2026 10:21
…Rust

Add Elixir and Rust to platformProductAvailability and add METRICS to
Ruby/Ruby-rack/Ruby-rails entries.

Feature support verified against sentry-docs frontmatter:
- Ruby (ruby, ruby-rack, ruby-rails): add METRICS (already had perf, profiling, logs)
- Elixir: add PERFORMANCE_MONITORING, LOGS, METRICS (no profiling/replay in SDK)
- Rust: add PERFORMANCE_MONITORING, LOGS, METRICS (no profiling/replay in SDK)
Add metrics onboarding snippets for Rust (sentry::metrics API) and
Elixir (Sentry.Metrics module), wire them up in each platform's
index.tsx, and register both platforms in withMetricsOnboarding.

Also remove Elixir from withoutPerformanceSupport since it now
supports performance monitoring.

Update Ruby metrics snippets to use Sentry.metrics accessor style
matching the official docs, use realistic example metric names, and
add trailing docs links across all three SDKs for consistency with
other platform onboarding files.

Co-Authored-By: Claude <noreply@anthropic.com>
@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label May 21, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 21, 2026

📊 Type Coverage Diff

✅ No new type safety issues introduced. Coverage: 93.63%

…Ruby

Verify that metrics onboarding content renders when METRICS is
selected and does not render when it is not, following the same
pattern as the existing .NET metrics spec.

Co-Authored-By: Claude <noreply@anthropic.com>
The renderWithOnboardingLayout helper renders the main onboarding
flow, not the standalone metricsOnboarding config. Switch to testing
the config object directly, matching the Python metrics test pattern.

Co-Authored-By: Claude <noreply@anthropic.com>
Rename destructured metrics to rustMetrics/elixirMetrics/rubyMetrics
to avoid TS2451 global scope collision between script-scoped files.

Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant