| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 6154b37 commit 63119eb
46 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,5 +1,5 @@ | |||
| 1 | 1 | /** | |
| 2 | - * orchestrion code-transform plugin for Bun's bundler (`bun build`). | ||
| 2 | + * Sentry code-transform plugin for Bun's bundler (`bun build`). | ||
| 3 | 3 | * | |
| 4 | 4 | * Usage: | |
| 5 | 5 | * | |
@@ -17,7 +17,7 @@ | |||
| 17 | 17 | * | |
| 18 | 18 | * When https://github.com/oven-sh/bun/pull/31770 lands, we can revisit. | |
| 19 | 19 | * | |
| 20 | - * Until then, Bun apps must bundle to get orchestrion instrumentation. In dev | ||
| 20 | + * Until then, Bun apps must bundle to get build-time instrumentation. In dev | ||
| 21 | 21 | * (ie, `bun run`) there is simply no instrumentation, which is clearer than | |
| 22 | 22 | * partial/inconsistent coverage. | |
| 23 | 23 | * | |
@@ -52,7 +52,7 @@ interface BunPluginBuilder { | |||
| 52 | 52 | } | |
| 53 | 53 | ||
| 54 | 54 | /** | |
| 55 | - * Returns the orchestrion code-transform plugin for Bun's bundler, configured | ||
| 55 | + * Returns the Sentry code-transform plugin for Bun's bundler, configured | ||
| 56 | 56 | * with the central `SENTRY_INSTRUMENTATIONS`. The plugin injects | |
| 57 | 57 | * `diagnostics_channel.tracingChannel` calls into the instrumented libraries as | |
| 58 | 58 | * `bun build` bundles them — plus, via the module-injected transform, the | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -974,7 +974,7 @@ export abstract class Client<O extends ClientOptions = ClientOptions> { | |||
| 974 | 974 | public on(hook: 'stopUIProfiler', callback: () => void): () => void; | |
| 975 | 975 | ||
| 976 | 976 | /** | |
| 977 | - * A hook that is called when an orchestrion-instrumented module is injected — | ||
| 977 | + * A hook that is called when an instrumented module is injected — | ||
| 978 | 978 | * at runtime by the module hook, or at load of a bundler-transformed module. | |
| 979 | 979 | * Channel-based integrations use it to subscribe their diagnostics-channel | |
| 980 | 980 | * listeners lazily, only once the module they instrument is actually loaded. | |
@@ -1262,7 +1262,7 @@ export abstract class Client<O extends ClientOptions = ClientOptions> { | |||
| 1262 | 1262 | public emit(hook: 'stopUIProfiler'): void; | |
| 1263 | 1263 | ||
| 1264 | 1264 | /** | |
| 1265 | - * Emit a hook when an orchestrion-instrumented module is injected (runtime | ||
| 1265 | + * Emit a hook when an instrumented module is injected (runtime | ||
| 1266 | 1266 | * module hook or bundler-transformed module load). | |
| 1267 | 1267 | */ | |
| 1268 | 1268 | public emit(hook: 'orchestrion.module-injected', moduleName: string): void; | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -401,7 +401,7 @@ export function _sanitizeSqlQuery(sqlQuery: string | undefined): string { | |||
| 401 | 401 | /** | |
| 402 | 402 | * Sets connection context attributes on a span. | |
| 403 | 403 | * | |
| 404 | - * @internal Exported for the orchestrion (diagnostics-channel) integration. | ||
| 404 | + * @internal Exported for the diagnostics-channel integration. | ||
| 405 | 405 | */ | |
| 406 | 406 | export function _setConnectionAttributes(span: Span, connectionContext: PostgresConnectionContext | undefined): void { | |
| 407 | 407 | if (!connectionContext) { | |
@@ -426,7 +426,7 @@ export function _setConnectionAttributes(span: Span, connectionContext: Postgres | |||
| 426 | 426 | /** | |
| 427 | 427 | * Extracts DB operation name from SQL query and sets it on the span. | |
| 428 | 428 | * | |
| 429 | - * @internal Exported for the orchestrion (diagnostics-channel) integration. | ||
| 429 | + * @internal Exported for the diagnostics-channel integration. | ||
| 430 | 430 | */ | |
| 431 | 431 | export function _setOperationName(span: Span, sanitizedQuery: string | undefined, command?: string): void { | |
| 432 | 432 | if (command) { | |
@@ -444,7 +444,7 @@ export function _setOperationName(span: Span, sanitizedQuery: string | undefined | |||
| 444 | 444 | * Builds a {@link PostgresConnectionContext} from postgres.js' parsed options | |
| 445 | 445 | * (which store `host`/`port` as arrays). Defaults to 'localhost'/5432. | |
| 446 | 446 | * | |
| 447 | - * @internal Exported for the orchestrion (diagnostics-channel) integration. | ||
| 447 | + * @internal Exported for the diagnostics-channel integration. | ||
| 448 | 448 | */ | |
| 449 | 449 | export function _buildConnectionContext(options: { | |
| 450 | 450 | host?: string[]; | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -56,7 +56,7 @@ export type InternalGlobal = { | |||
| 56 | 56 | _sentryModuleMetadata?: Record<string, any>; | |
| 57 | 57 | _sentryWrappedDepth?: number; | |
| 58 | 58 | /** | |
| 59 | - * Orchestrion bundler and runtime detection. | ||
| 59 | + * Bundler and runtime instrumentation detection. | ||
| 60 | 60 | */ | |
| 61 | 61 | __SENTRY_ORCHESTRION__?: { | |
| 62 | 62 | /** Empty array signifies runtime hooked */ | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -60,10 +60,8 @@ Sentry.captureEvent({ | |||
| 60 | 60 | ## Auto-instrumentation (experimental) | |
| 61 | 61 | ||
| 62 | 62 | Some libraries (e.g. `mysql`) don't emit tracing signals on their | |
| 63 | - own. To instrument them, Sentry uses | ||
| 64 | - [orchestrion](https://github.com/apm-js-collab/tracing-hooks) to | ||
| 65 | - transform them at load time so they publish to | ||
| 66 | - `node:diagnostics_channel`. | ||
| 63 | + own. To instrument them, Sentry transforms them at load time so they | ||
| 64 | + publish to `node:diagnostics_channel`. | ||
| 67 | 65 | ||
| 68 | 66 | Use the `--import` or `--preload` argument to `deno run` to enable | |
| 69 | 67 | these instrumentations. | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -121,7 +121,7 @@ export function subscribeToNestChannels(): void { | |||
| 121 | 121 | return; | |
| 122 | 122 | } | |
| 123 | 123 | ||
| 124 | - DEBUG_BUILD && debug.log('[orchestrion:nestjs] subscribing to @nestjs channels'); | ||
| 124 | + DEBUG_BUILD && debug.log('[instrumentation:nestjs] subscribing to @nestjs channels'); | ||
| 125 | 125 | ||
| 126 | 126 | // App-creation span: `bindTracingChannelToSpan` opens the span on | |
| 127 | 127 | // `start`, makes it the active context for the bootstrap, and ends it | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,12 +1,14 @@ | |||
| 1 | 1 | import { sentryEsbuildPlugin as sentryEsbuildBundlerPlugin } from '@sentry/bundler-plugins/esbuild'; | |
| 2 | 2 | import type { SentryEsbuildPluginOptions as SentryEsbuildPluginOptionsBase } from '@sentry/bundler-plugins/esbuild'; | |
| 3 | + import type { InstrumentationConfig } from '@sentry/server-utils'; | ||
| 3 | 4 | import { sentryOrchestrionPlugin } from '@sentry/server-utils/orchestrion/esbuild'; | |
| 5 | + import type { EsbuildPlugin } from '@sentry/server-utils/orchestrion/esbuild'; | ||
| 4 | 6 | ||
| 5 | 7 | export type SentryEsbuildPluginOptions = SentryEsbuildPluginOptionsBase & { | |
| 6 | 8 | /** | |
| 7 | 9 | * @ignore This is for internal use only when this plugin is consumed by a framework SDK | |
| 8 | 10 | */ | |
| 9 | - instrumentations?: NonNullable<Parameters<typeof sentryOrchestrionPlugin>[0]>['instrumentations']; | ||
| 11 | + instrumentations?: InstrumentationConfig[]; | ||
| 10 | 12 | ||
| 11 | 13 | /** | |
| 12 | 14 | * Automatic instrumentation of server-side dependencies at build time. | |
@@ -18,8 +20,6 @@ export type SentryEsbuildPluginOptions = SentryEsbuildPluginOptionsBase & { | |||
| 18 | 20 | buildTimeInstrumentation?: boolean; | |
| 19 | 21 | }; | |
| 20 | 22 | ||
| 21 | - type EsbuildPlugin = ReturnType<typeof sentryOrchestrionPlugin>; | ||
| 22 | - | ||
| 23 | 23 | /** | |
| 24 | 24 | * esbuild plugin that bundles the Sentry esbuild bundler plugin (source maps, | |
| 25 | 25 | * release injection, …) together with the code transformer | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,12 +1,14 @@ | |||
| 1 | 1 | import { sentryRollupPlugin as sentryRollupBundlerPlugin } from '@sentry/bundler-plugins/rollup'; | |
| 2 | 2 | import type { SentryRollupPluginOptions as SentryRollupPluginOptionsBase } from '@sentry/bundler-plugins/rollup'; | |
| 3 | + import type { InstrumentationConfig } from '@sentry/server-utils'; | ||
| 3 | 4 | import { sentryOrchestrionPlugin } from '@sentry/server-utils/orchestrion/rollup'; | |
| 5 | + import type { RollupPlugin } from '@sentry/server-utils/orchestrion/rollup'; | ||
| 4 | 6 | ||
| 5 | 7 | export type SentryRollupPluginOptions = SentryRollupPluginOptionsBase & { | |
| 6 | 8 | /** | |
| 7 | 9 | * @ignore This is for internal use only when this plugin is consumed by a framework SDK | |
| 8 | 10 | */ | |
| 9 | - instrumentations?: NonNullable<Parameters<typeof sentryOrchestrionPlugin>[0]>['instrumentations']; | ||
| 11 | + instrumentations?: InstrumentationConfig[]; | ||
| 10 | 12 | ||
| 11 | 13 | /** | |
| 12 | 14 | * Automatic instrumentation of server-side dependencies at build time. | |
@@ -18,8 +20,6 @@ export type SentryRollupPluginOptions = SentryRollupPluginOptionsBase & { | |||
| 18 | 20 | buildTimeInstrumentation?: boolean; | |
| 19 | 21 | }; | |
| 20 | 22 | ||
| 21 | - type RollupPlugin = ReturnType<typeof sentryOrchestrionPlugin>; | ||
| 22 | - | ||
| 23 | 23 | /** | |
| 24 | 24 | * Rollup plugin that bundles the Sentry Rollup bundler plugin (source maps, | |
| 25 | 25 | * release injection, bundle size optimizations, …) together with the | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,12 +1,14 @@ | |||
| 1 | 1 | import { sentryVitePlugin as sentryViteBundlerPlugin } from '@sentry/bundler-plugins/vite'; | |
| 2 | 2 | import type { SentryVitePluginOptions as SentryVitePluginOptionsBase } from '@sentry/bundler-plugins/vite'; | |
| 3 | + import type { InstrumentationConfig } from '@sentry/server-utils'; | ||
| 3 | 4 | import { sentryOrchestrionPlugin } from '@sentry/server-utils/orchestrion/vite'; | |
| 5 | + import type { VitePlugin } from '@sentry/server-utils/orchestrion/vite'; | ||
| 4 | 6 | ||
| 5 | 7 | export type SentryVitePluginOptions = SentryVitePluginOptionsBase & { | |
| 6 | 8 | /** | |
| 7 | 9 | * @ignore This is for internal use only when this plugin is consumed by a framework SDK | |
| 8 | 10 | */ | |
| 9 | - instrumentations?: NonNullable<Parameters<typeof sentryOrchestrionPlugin>[0]>['instrumentations']; | ||
| 11 | + instrumentations?: InstrumentationConfig[]; | ||
| 10 | 12 | ||
| 11 | 13 | /** | |
| 12 | 14 | * Automatic instrumentation of server-side dependencies at build time. | |
@@ -18,8 +20,6 @@ export type SentryVitePluginOptions = SentryVitePluginOptionsBase & { | |||
| 18 | 20 | buildTimeInstrumentation?: boolean; | |
| 19 | 21 | }; | |
| 20 | 22 | ||
| 21 | - type VitePlugin = ReturnType<typeof sentryOrchestrionPlugin>; | ||
| 22 | - | ||
| 23 | 23 | /** | |
| 24 | 24 | * Vite plugin that bundles the Sentry Vite bundler plugin (source maps, release | |
| 25 | 25 | * injection, bundle size optimizations, …) together with the code | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,12 +1,13 @@ | |||
| 1 | 1 | import { sentryWebpackPlugin as sentryWebpackBundlerPlugin } from '@sentry/bundler-plugins/webpack'; | |
| 2 | 2 | import type { SentryWebpackPluginOptions as SentryWebpackPluginOptionsBase } from '@sentry/bundler-plugins/webpack'; | |
| 3 | + import type { InstrumentationConfig } from '@sentry/server-utils'; | ||
| 3 | 4 | import { sentryOrchestrionWebpackPlugin } from '@sentry/server-utils/orchestrion/webpack'; | |
| 4 | 5 | ||
| 5 | 6 | export type SentryWebpackPluginOptions = SentryWebpackPluginOptionsBase & { | |
| 6 | 7 | /** | |
| 7 | 8 | * @ignore This is for internal use only when this plugin is consumed by a framework SDK | |
| 8 | 9 | */ | |
| 9 | - instrumentations?: NonNullable<Parameters<typeof sentryOrchestrionWebpackPlugin>[0]>['instrumentations']; | ||
| 10 | + instrumentations?: InstrumentationConfig[]; | ||
| 10 | 11 | ||
| 11 | 12 | /** | |
| 12 | 13 | * Automatic instrumentation of server-side dependencies at build time. | |
| Back | FazBrowse Home | New Git URL |
0 commit comments