feat(bun): enable new mysql, pg integrations in 'bun build'#21828
Open
isaacs wants to merge 1 commit into
Open
feat(bun): enable new mysql, pg integrations in 'bun build'#21828isaacs wants to merge 1 commit into
isaacs wants to merge 1 commit into
Conversation
9545bf8 to
dfe74f5
Compare
e3cde9d to
f53b1bc
Compare
Contributor
size-limit report 📦
|
JPeer264
approved these changes
Jun 29, 2026
JPeer264
left a comment
Member
There was a problem hiding this comment.
nice changes. Could also be useful for Cloudflare I think
dfe74f5 to
373c014
Compare
f53b1bc to
17bb086
Compare
2b34039 to
a4e321e
Compare
17bb086 to
caead8a
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 6 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 caead8a. Configure here.
aac5ba0 to
913c558
Compare
The bun *plugin* was injecting the channels, and we had an integration test verifying that. However, it was not actually swapping out the (nonfunctional) OTel-based integrations with the orchestrion diagnostics-channel versions, meaning that the spans would not be emitted as expected. Add a full end-to-end test verifying that a `bun build`-compiled application will instrument a mysql connection and emit spans for the queries being executed. When the orchestrion bundler marker is *not* present, do not add the diagnostics-channel listeners, since they will not have anything to trigger them anyway. Also, this means that as new diagnostics-channel-injection integrations are added, Bun will benefit from automatically loading those instrumentations, as long as the application is compiled with `bun build`, using the `@sentry/bun/plugin` plugin.
913c558 to
fe1c7bc
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.

The bun plugin was injecting the channels, and we had an integration test verifying that. However, it was not actually swapping out the (nonfunctional) OTel-based integrations with the orchestrion diagnostics-channel versions, meaning that the spans would not be emitted as expected.
Add a full end-to-end test verifying that a
bun build-compiled application will instrument a mysql connection and emit spans for the queries being executed.When the orchestrion bundler marker is not present, do not add the diagnostics-channel listeners, since they will not have anything to trigger them anyway.
Also, this means that as new diagnostics-channel-injection integrations are added, Bun will benefit from automatically loading those instrumentations, as long as the application is compiled with
bun build, using the@sentry/bun/pluginplugin.