Skip to content

fix(node-sdk): add OTLP integration path for OTel-first Node.js projects#93

Draft
Copilot wants to merge 2 commits intomainfrom
copilot/update-sentry-node-sdk-otlp-integration
Draft

fix(node-sdk): add OTLP integration path for OTel-first Node.js projects#93
Copilot wants to merge 2 commits intomainfrom
copilot/update-sentry-node-sdk-otlp-integration

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 9, 2026

getsentry/sentry-javascript#19729 added otlpIntegration at @sentry/node-core/light/otlp for users who already manage their own OpenTelemetry setup. The sentry-node-sdk skill had no OTLP path, unlike the Python and Ruby skills which both document this pattern.

sentry-node-sdk/SKILL.md

  • Phase 1: Detect @opentelemetry/sdk-node, @opentelemetry/sdk-trace-node, NodeTracerProvider in package.json/source
  • Phase 2: Route OTel-detected projects to OTLP path; mark Tracing and Profiling as "skip if OTel detected" (profiling requires tracesSampleRate, incompatible with OTLP)
  • Phase 3: New "OTLP Integration" section with install, init, collector endpoint, and a comparison table vs standard @sentry/node
  • Config Reference: otlpIntegration() options table (setupOtlpTracesExporter, collectorUrl)
  • Troubleshooting: 3 OTLP-specific entries
import { NodeTracerProvider } from '@opentelemetry/sdk-trace-node';
import * as Sentry from '@sentry/node-core/light';
import { otlpIntegration } from '@sentry/node-core/light/otlp';

const provider = new NodeTracerProvider();
provider.register();

Sentry.init({
  dsn: process.env.SENTRY_DSN,
  // Do NOT set tracesSampleRate — OTel controls sampling
  integrations: [otlpIntegration()],
});

sentry-otel-exporter-setup/SKILL.md

  • Step 8 now includes Node.js alongside Python and Ruby with full setup instructions

Add detection, recommendation, and setup guidance for using
@sentry/node-core/light with otlpIntegration() for projects that
already manage their own OpenTelemetry setup.

Also update sentry-otel-exporter-setup Step 8 to include Node.js
alongside Python and Ruby.

Addresses getsentry/sentry-javascript#19729.

Co-Authored-By: Claude <noreply@anthropic.com>

Agent-Logs-Url: https://github.com/getsentry/sentry-for-ai/sessions/33efdd69-5e2d-4838-9107-8af6407c17e6

Co-authored-by: HazAT <363802+HazAT@users.noreply.github.com>
Copilot AI changed the title [WIP] Update sentry-node-sdk for OTLP integration fix(node-sdk): add OTLP integration path for OTel-first Node.js projects Apr 9, 2026
Copilot AI requested a review from HazAT April 9, 2026 07:57
Copilot finished work on behalf of HazAT April 9, 2026 07:57
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.

[skill-drift] sentry-node-sdk may need updates for OTLP integration (node-core/light)

2 participants