diff --git a/dev-packages/e2e-tests/test-applications/node-exports-test-app/scripts/consistentExports.ts b/dev-packages/e2e-tests/test-applications/node-exports-test-app/scripts/consistentExports.ts index 78f287d37e8c..f4d14f73d08a 100644 --- a/dev-packages/e2e-tests/test-applications/node-exports-test-app/scripts/consistentExports.ts +++ b/dev-packages/e2e-tests/test-applications/node-exports-test-app/scripts/consistentExports.ts @@ -54,6 +54,13 @@ const DEPENDENTS: Dependent[] = [ 'NodeClient', 'hapiErrorPlugin', 'makeNodeTransport', + // TODO: remove these when we switch exports from nodeExperimentalExports to nodeExports + 'Integrations', + 'addGlobalEventProcessor', + 'getActiveTransaction', + 'getCurrentHub', + 'makeMain', + 'startTransaction', ], }, { diff --git a/packages/bun/src/index.ts b/packages/bun/src/index.ts index c332f1c19109..2d9b76dd9be2 100644 --- a/packages/bun/src/index.ts +++ b/packages/bun/src/index.ts @@ -22,8 +22,6 @@ export type { TransactionNamingScheme } from '@sentry/node-experimental'; export type { BunOptions } from './types'; export { - // eslint-disable-next-line deprecation/deprecation - addGlobalEventProcessor, addEventProcessor, addBreadcrumb, addIntegration, @@ -33,22 +31,14 @@ export { close, createTransport, flush, - // eslint-disable-next-line deprecation/deprecation - getActiveTransaction, - // eslint-disable-next-line deprecation/deprecation - getCurrentHub, getClient, isInitialized, getCurrentScope, getGlobalScope, getIsolationScope, Hub, - // eslint-disable-next-line deprecation/deprecation - makeMain, setCurrentClient, Scope, - // eslint-disable-next-line deprecation/deprecation - startTransaction, SDK_VERSION, setContext, setExtra, @@ -119,13 +109,4 @@ export { init, } from './sdk'; -import { Integrations as NodeIntegrations } from '@sentry/node-experimental'; -import { BunServer } from './integrations/bunserver'; export { bunServerIntegration } from './integrations/bunserver'; - -const INTEGRATIONS = { - ...NodeIntegrations, - BunServer, -}; - -export { INTEGRATIONS as Integrations }; diff --git a/packages/bun/src/integrations/bunserver.ts b/packages/bun/src/integrations/bunserver.ts index 8ab9a73194da..f1294a5d00d6 100644 --- a/packages/bun/src/integrations/bunserver.ts +++ b/packages/bun/src/integrations/bunserver.ts @@ -4,7 +4,6 @@ import { Transaction, captureException, continueTrace, - convertIntegrationFnToClass, defineIntegration, getCurrentScope, setHttpStatus, @@ -25,15 +24,20 @@ const _bunServerIntegration = (() => { }; }) satisfies IntegrationFn; -export const bunServerIntegration = defineIntegration(_bunServerIntegration); - /** * Instruments `Bun.serve` to automatically create transactions and capture errors. * - * @deprecated Use `bunServerIntegration()` instead. + * Enabled by default in the Bun SDK. + * + * ```js + * Sentry.init({ + * integrations: [ + * Sentry.bunServerIntegration(), + * ], + * }) + * ``` */ -// eslint-disable-next-line deprecation/deprecation -export const BunServer = convertIntegrationFnToClass(INTEGRATION_NAME, bunServerIntegration); +export const bunServerIntegration = defineIntegration(_bunServerIntegration); /** * Instruments Bun.serve by patching it's options. diff --git a/packages/bun/test/integrations/bunserver.test.ts b/packages/bun/test/integrations/bunserver.test.ts index 14080fa02315..95dcc9363e7d 100644 --- a/packages/bun/test/integrations/bunserver.test.ts +++ b/packages/bun/test/integrations/bunserver.test.ts @@ -79,8 +79,6 @@ describe('Bun Serve Integration', () => { // span.endTimestamp is already set in `finishTransaction` hook expect(transaction.isRecording()).toBe(false); - // eslint-disable-next-line deprecation/deprecation - expect(transaction.metadata?.dynamicSamplingContext).toStrictEqual({ version: '1.0', environment: 'production' }); expect(getDynamicSamplingContextFromSpan(transaction)).toStrictEqual({ version: '1.0', environment: 'production',