|
1 | 1 | import type { Integration } from '@sentry/core'; |
2 | 2 | import { prismaIntegration } from '@sentry/server-utils'; |
| 3 | +import { |
| 4 | + amqplibChannelIntegration, |
| 5 | + anthropicChannelIntegration, |
| 6 | + expressChannelIntegration, |
| 7 | + firebaseChannelIntegration, |
| 8 | + genericPoolChannelIntegration, |
| 9 | + googleGenAIChannelIntegration, |
| 10 | + graphqlDiagnosticsChannelIntegration, |
| 11 | + hapiChannelIntegration, |
| 12 | + kafkajsChannelIntegration, |
| 13 | + koaChannelIntegration, |
| 14 | + langChainChannelIntegration, |
| 15 | + langGraphChannelIntegration, |
| 16 | + lruMemoizerChannelIntegration, |
| 17 | + mongodbChannelIntegration, |
| 18 | + mongooseChannelIntegration, |
| 19 | + mysqlChannelIntegration, |
| 20 | + mysql2ChannelIntegration, |
| 21 | + openaiChannelIntegration, |
| 22 | + postgresChannelIntegration, |
| 23 | + postgresJsChannelIntegration, |
| 24 | + tediousChannelIntegration, |
| 25 | + vercelAiChannelIntegration, |
| 26 | +} from '@sentry/server-utils/orchestrion'; |
3 | 27 | import { instrumentSentryHttp } from '../http'; |
4 | | -import { amqplibIntegration } from './amqplib'; |
5 | | -import { anthropicAIIntegration } from './anthropic-ai'; |
6 | | -import { expressIntegration } from './express'; |
7 | 28 | import { fastifyIntegration, instrumentFastifyV3 } from './fastify'; |
8 | | -import { firebaseIntegration } from './firebase'; |
9 | | -import { genericPoolIntegration } from './genericPool'; |
10 | | -import { googleGenAIIntegration } from './google-genai'; |
11 | | -import { graphqlIntegration } from './graphql'; |
12 | | -import { hapiIntegration } from './hapi'; |
13 | | -import { kafkaIntegration } from './kafka'; |
14 | | -import { koaIntegration } from './koa'; |
15 | | -import { langChainIntegration } from './langchain'; |
16 | | -import { langGraphIntegration } from './langgraph'; |
17 | | -import { lruMemoizerIntegration } from './lrumemoizer'; |
18 | | -import { mongoIntegration } from './mongo'; |
19 | | -import { mongooseIntegration } from './mongoose'; |
20 | | -import { mysqlIntegration } from './mysql'; |
21 | | -import { mysql2Integration } from './mysql2'; |
22 | | -import { openAIIntegration } from './openai'; |
23 | | -import { postgresIntegration } from './postgres'; |
24 | | -import { postgresJsIntegration } from './postgresjs'; |
25 | 29 | import { instrumentRedis, redisChannelIntegrations } from './redis'; |
26 | | -import { tediousIntegration } from './tedious'; |
27 | | -import { vercelAIIntegration } from './vercelai'; |
28 | 30 |
|
29 | 31 | /** |
30 | 32 | * With OTEL, all performance integrations will be added, as OTEL only initializes them when the patched package is actually required. |
31 | 33 | */ |
32 | 34 | export function getAutoPerformanceIntegrations(): Integration[] { |
33 | 35 | return [ |
34 | | - expressIntegration(), |
| 36 | + expressChannelIntegration(), |
| 37 | + // Fastify keeps the node wrapper: the channel path only covers Fastify v5, the wrapper also |
| 38 | + // instruments v3/v4. |
35 | 39 | fastifyIntegration(), |
36 | | - graphqlIntegration(), |
37 | | - mongoIntegration(), |
38 | | - mongooseIntegration(), |
39 | | - mysqlIntegration(), |
40 | | - mysql2Integration(), |
| 40 | + graphqlDiagnosticsChannelIntegration(), |
| 41 | + mongodbChannelIntegration(), |
| 42 | + mongooseChannelIntegration(), |
| 43 | + mysqlChannelIntegration(), |
| 44 | + mysql2ChannelIntegration(), |
| 45 | + // Redis keeps the node wrapper: it wires the cache `responseHook` into the channel integrations. |
41 | 46 | ...redisChannelIntegrations(), |
42 | | - postgresIntegration(), |
| 47 | + postgresChannelIntegration(), |
43 | 48 | prismaIntegration(), |
44 | | - hapiIntegration(), |
45 | | - koaIntegration(), |
46 | | - tediousIntegration(), |
47 | | - genericPoolIntegration(), |
48 | | - kafkaIntegration(), |
49 | | - amqplibIntegration(), |
50 | | - lruMemoizerIntegration(), |
| 49 | + hapiChannelIntegration(), |
| 50 | + koaChannelIntegration(), |
| 51 | + tediousChannelIntegration(), |
| 52 | + genericPoolChannelIntegration(), |
| 53 | + kafkajsChannelIntegration(), |
| 54 | + amqplibChannelIntegration(), |
| 55 | + lruMemoizerChannelIntegration(), |
51 | 56 | // AI providers |
52 | 57 | // LangChain must come first to disable AI provider integrations before they instrument |
53 | | - langChainIntegration(), |
54 | | - langGraphIntegration(), |
55 | | - vercelAIIntegration(), |
56 | | - openAIIntegration(), |
57 | | - anthropicAIIntegration(), |
58 | | - googleGenAIIntegration(), |
59 | | - postgresJsIntegration(), |
60 | | - firebaseIntegration(), |
| 58 | + langChainChannelIntegration(), |
| 59 | + langGraphChannelIntegration(), |
| 60 | + vercelAiChannelIntegration(), |
| 61 | + openaiChannelIntegration(), |
| 62 | + anthropicChannelIntegration(), |
| 63 | + googleGenAIChannelIntegration(), |
| 64 | + postgresJsChannelIntegration(), |
| 65 | + firebaseChannelIntegration(), |
61 | 66 | ]; |
62 | 67 | } |
63 | 68 |
|
|
0 commit comments