Open
Conversation
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit f1ac205. Configure here.
Contributor
size-limit report 📦
|
Platform-portable Connect tracing integration in `@sentry/core` (`patchConnectModule`, `setupConnectErrorHandler`), similar to portable Express integration, and rewire the Node SDK's Connect integration to call into it through the otel InstrumentationBase class. Remove OTel-specific span attribute fix-up. Spans created with correct origin (`auto.http.connect`) and op directly in the middleware.
Add platform-portable building blocks that server SDKs use to instrument incoming HTTP requests without depending on OTel HTTP instrumentation: - `getHttpServerSubscriptions`: diagnostics_channel listener for `http.server.request.start`, set up isolation scope, request data, trace continuation, optional body capture and request-session tracking - `getHttpServerSpanSubscriptions`: wrapper that creates the root server span around the request lifecycle, applying static-asset/status-code filtering, `ignoreIncomingRequests` and `onSpanCreated` hooks - `recordRequestSession`: release-health session aggregation per request - `patchRequestToCaptureBody`: opt-in incoming request body capture Add `kind` field on `StartSpanOptions` so OTel-based SDKs can set SpanKind on the underlying span, and update `headersToDict` to allow `number`-valued headers to support Node.js types.
Replace inline `instrumentServer` Proxy/emit-wrapping implementation in node-light's HTTP integration with core's `getHttpServerSubscriptions`, which does the same work (isolation scope, request data, body capture, trace continuation, best-effort transaction name). Centralized implementation lets Bun, Deno, Workers, and the OTel-based Node SDK share server-side primitives. Also drop `wrappedEmitFns` and the import of several core utilities that are now consumed via the subscriptions.
…erIntegration Replace inline `instrumentServer` Proxy/emit-wrapping in `httpServerIntegration.ts` with core's `getHttpServerSubscriptions`. OTel-specific concerns (header propagation, double-wrap context guard, `_startSpanCallback` dispatch) move into a `wrapServerEmitRequest` callback that `instrumentServer` invokes inside the per-request lifecycle. Re-export `recordRequestSession` from core so existing test continues to pass. Duplicated request-isolation/session/body-capture plumbing removed, logic now lives in `@sentry/core`'s subscription factory.
`patchRequestToCaptureBody` lives in `@sentry/core` now and both the light SDK and the OTel-based `httpServerIntegration` consume it from there.
f1ac205 to
2954cdc
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Before submitting a pull request, please take a look at our
Contributing guidelines and verify:
yarn lint) & (yarn test).Closes #issue_link_here