@sentry/node 10.57.0 → 10.59.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (523) hide show
  1. package/build/cjs/index.js +2 -0
  2. package/build/cjs/index.js.map +1 -1
  3. package/build/cjs/integrations/fs/index.js +3 -84
  4. package/build/cjs/integrations/fs/index.js.map +1 -1
  5. package/build/cjs/integrations/fs/vendored/constants.js.map +1 -1
  6. package/build/cjs/integrations/fs/vendored/instrumentation.js +145 -175
  7. package/build/cjs/integrations/fs/vendored/instrumentation.js.map +1 -1
  8. package/build/cjs/integrations/fs/vendored/utils.js.map +1 -1
  9. package/build/cjs/integrations/node-fetch/vendored/undici.js.map +1 -1
  10. package/build/cjs/integrations/tracing/amqplib/vendored/amqplib.js.map +1 -1
  11. package/build/cjs/integrations/tracing/amqplib/vendored/semconv-obsolete.js.map +1 -1
  12. package/build/cjs/integrations/tracing/amqplib/vendored/semconv.js.map +1 -1
  13. package/build/cjs/integrations/tracing/amqplib/vendored/types.js.map +1 -1
  14. package/build/cjs/integrations/tracing/amqplib/vendored/utils.js.map +1 -1
  15. package/build/cjs/integrations/tracing/connect/index.js +0 -21
  16. package/build/cjs/integrations/tracing/connect/index.js.map +1 -1
  17. package/build/cjs/integrations/tracing/connect/vendored/enums/AttributeNames.js +0 -6
  18. package/build/cjs/integrations/tracing/connect/vendored/enums/AttributeNames.js.map +1 -1
  19. package/build/cjs/integrations/tracing/connect/vendored/instrumentation.js +33 -42
  20. package/build/cjs/integrations/tracing/connect/vendored/instrumentation.js.map +1 -1
  21. package/build/cjs/integrations/tracing/connect/vendored/internal-types.js.map +1 -1
  22. package/build/cjs/integrations/tracing/connect/vendored/utils.js +3 -2
  23. package/build/cjs/integrations/tracing/connect/vendored/utils.js.map +1 -1
  24. package/build/cjs/integrations/tracing/dataloader/index.js +2 -22
  25. package/build/cjs/integrations/tracing/dataloader/index.js.map +1 -1
  26. package/build/cjs/integrations/tracing/dataloader/vendored/instrumentation.js +93 -120
  27. package/build/cjs/integrations/tracing/dataloader/vendored/instrumentation.js.map +1 -1
  28. package/build/cjs/integrations/tracing/fastify/v3/instrumentation.js +1 -1
  29. package/build/cjs/integrations/tracing/fastify/v3/instrumentation.js.map +1 -1
  30. package/build/cjs/integrations/tracing/fastify/vendored/instrumentation.js.map +1 -1
  31. package/build/cjs/integrations/tracing/genericPool/index.js +1 -15
  32. package/build/cjs/integrations/tracing/genericPool/index.js.map +1 -1
  33. package/build/cjs/integrations/tracing/genericPool/vendored/instrumentation.js +37 -37
  34. package/build/cjs/integrations/tracing/genericPool/vendored/instrumentation.js.map +1 -1
  35. package/build/cjs/integrations/tracing/graphql/index.js +1 -51
  36. package/build/cjs/integrations/tracing/graphql/index.js.map +1 -1
  37. package/build/cjs/integrations/tracing/graphql/vendored/enum.js.map +1 -1
  38. package/build/cjs/integrations/tracing/graphql/vendored/enums/AttributeNames.js +0 -2
  39. package/build/cjs/integrations/tracing/graphql/vendored/enums/AttributeNames.js.map +1 -1
  40. package/build/cjs/integrations/tracing/graphql/vendored/instrumentation.js +67 -57
  41. package/build/cjs/integrations/tracing/graphql/vendored/instrumentation.js.map +1 -1
  42. package/build/cjs/integrations/tracing/graphql/vendored/internal-types.js.map +1 -1
  43. package/build/cjs/integrations/tracing/graphql/vendored/symbols.js.map +1 -1
  44. package/build/cjs/integrations/tracing/graphql/vendored/utils.js +28 -62
  45. package/build/cjs/integrations/tracing/graphql/vendored/utils.js.map +1 -1
  46. package/build/cjs/integrations/tracing/hapi/index.js +0 -17
  47. package/build/cjs/integrations/tracing/hapi/index.js.map +1 -1
  48. package/build/cjs/integrations/tracing/hapi/vendored/enums/AttributeNames.js.map +1 -1
  49. package/build/cjs/integrations/tracing/hapi/vendored/instrumentation.js +28 -45
  50. package/build/cjs/integrations/tracing/hapi/vendored/instrumentation.js.map +1 -1
  51. package/build/cjs/integrations/tracing/hapi/vendored/internal-types.js.map +1 -1
  52. package/build/cjs/integrations/tracing/hapi/vendored/semconv.js.map +1 -1
  53. package/build/cjs/integrations/tracing/hapi/vendored/utils.js +4 -9
  54. package/build/cjs/integrations/tracing/hapi/vendored/utils.js.map +1 -1
  55. package/build/cjs/integrations/tracing/index.js +1 -0
  56. package/build/cjs/integrations/tracing/index.js.map +1 -1
  57. package/build/cjs/integrations/tracing/kafka/vendored/instrumentation.js.map +1 -1
  58. package/build/cjs/integrations/tracing/kafka/vendored/internal-types.js.map +1 -1
  59. package/build/cjs/integrations/tracing/kafka/vendored/propagator.js.map +1 -1
  60. package/build/cjs/integrations/tracing/kafka/vendored/semconv.js.map +1 -1
  61. package/build/cjs/integrations/tracing/knex/index.js +2 -17
  62. package/build/cjs/integrations/tracing/knex/index.js.map +1 -1
  63. package/build/cjs/integrations/tracing/knex/vendored/instrumentation.js +65 -93
  64. package/build/cjs/integrations/tracing/knex/vendored/instrumentation.js.map +1 -1
  65. package/build/cjs/integrations/tracing/knex/vendored/semconv.js +2 -0
  66. package/build/cjs/integrations/tracing/knex/vendored/semconv.js.map +1 -1
  67. package/build/cjs/integrations/tracing/knex/vendored/utils.js +2 -15
  68. package/build/cjs/integrations/tracing/knex/vendored/utils.js.map +1 -1
  69. package/build/cjs/integrations/tracing/koa/index.js +1 -24
  70. package/build/cjs/integrations/tracing/koa/index.js.map +1 -1
  71. package/build/cjs/integrations/tracing/koa/vendored/enums/AttributeNames.js.map +1 -1
  72. package/build/cjs/integrations/tracing/koa/vendored/instrumentation.js +29 -41
  73. package/build/cjs/integrations/tracing/koa/vendored/instrumentation.js.map +1 -1
  74. package/build/cjs/integrations/tracing/koa/vendored/internal-types.js.map +1 -1
  75. package/build/cjs/integrations/tracing/koa/vendored/types.js.map +1 -1
  76. package/build/cjs/integrations/tracing/koa/vendored/utils.js.map +1 -1
  77. package/build/cjs/integrations/tracing/lrumemoizer/vendored/instrumentation.js.map +1 -1
  78. package/build/cjs/integrations/tracing/mongo/index.js +1 -42
  79. package/build/cjs/integrations/tracing/mongo/index.js.map +1 -1
  80. package/build/cjs/integrations/tracing/mongo/vendored/instrumentation.js +12 -562
  81. package/build/cjs/integrations/tracing/mongo/vendored/instrumentation.js.map +1 -1
  82. package/build/cjs/integrations/tracing/mongo/vendored/internal-types.js.map +1 -1
  83. package/build/cjs/integrations/tracing/mongo/vendored/patches.js +151 -0
  84. package/build/cjs/integrations/tracing/mongo/vendored/patches.js.map +1 -0
  85. package/build/cjs/integrations/tracing/mongo/vendored/semconv.js +0 -4
  86. package/build/cjs/integrations/tracing/mongo/vendored/semconv.js.map +1 -1
  87. package/build/cjs/integrations/tracing/mongo/vendored/utils.js +153 -0
  88. package/build/cjs/integrations/tracing/mongo/vendored/utils.js.map +1 -0
  89. package/build/cjs/integrations/tracing/mongoose/index.js +1 -8
  90. package/build/cjs/integrations/tracing/mongoose/index.js.map +1 -1
  91. package/build/cjs/integrations/tracing/mongoose/vendored/mongoose.js +56 -203
  92. package/build/cjs/integrations/tracing/mongoose/vendored/mongoose.js.map +1 -1
  93. package/build/cjs/integrations/tracing/mongoose/vendored/semconv.js +0 -4
  94. package/build/cjs/integrations/tracing/mongoose/vendored/semconv.js.map +1 -1
  95. package/build/cjs/integrations/tracing/mongoose/vendored/utils.js +19 -49
  96. package/build/cjs/integrations/tracing/mongoose/vendored/utils.js.map +1 -1
  97. package/build/cjs/integrations/tracing/mysql/vendored/AttributeNames.js.map +1 -1
  98. package/build/cjs/integrations/tracing/mysql/vendored/instrumentation.js.map +1 -1
  99. package/build/cjs/integrations/tracing/mysql/vendored/semconv.js.map +1 -1
  100. package/build/cjs/integrations/tracing/mysql/vendored/utils.js.map +1 -1
  101. package/build/cjs/integrations/tracing/mysql2/index.js +1 -8
  102. package/build/cjs/integrations/tracing/mysql2/index.js.map +1 -1
  103. package/build/cjs/integrations/tracing/mysql2/vendored/instrumentation.js +21 -59
  104. package/build/cjs/integrations/tracing/mysql2/vendored/instrumentation.js.map +1 -1
  105. package/build/cjs/integrations/tracing/mysql2/vendored/semconv.js.map +1 -1
  106. package/build/cjs/integrations/tracing/mysql2/vendored/utils.js +14 -33
  107. package/build/cjs/integrations/tracing/mysql2/vendored/utils.js.map +1 -1
  108. package/build/cjs/integrations/tracing/postgres/index.js +0 -4
  109. package/build/cjs/integrations/tracing/postgres/index.js.map +1 -1
  110. package/build/cjs/integrations/tracing/postgres/vendored/enums/AttributeNames.js +0 -1
  111. package/build/cjs/integrations/tracing/postgres/vendored/enums/AttributeNames.js.map +1 -1
  112. package/build/cjs/integrations/tracing/postgres/vendored/enums/SpanNames.js.map +1 -1
  113. package/build/cjs/integrations/tracing/postgres/vendored/instrumentation.js +51 -261
  114. package/build/cjs/integrations/tracing/postgres/vendored/instrumentation.js.map +1 -1
  115. package/build/cjs/integrations/tracing/postgres/vendored/semconv.js +0 -12
  116. package/build/cjs/integrations/tracing/postgres/vendored/semconv.js.map +1 -1
  117. package/build/cjs/integrations/tracing/postgres/vendored/utils.js +43 -167
  118. package/build/cjs/integrations/tracing/postgres/vendored/utils.js.map +1 -1
  119. package/build/cjs/integrations/tracing/prisma/vendored/active-tracing-helper.js.map +1 -1
  120. package/build/cjs/integrations/tracing/prisma/vendored/constants.js.map +1 -1
  121. package/build/cjs/integrations/tracing/prisma/vendored/global.js.map +1 -1
  122. package/build/cjs/integrations/tracing/prisma/vendored/instrumentation.js.map +1 -1
  123. package/build/cjs/integrations/tracing/redis/index.js +1 -1
  124. package/build/cjs/integrations/tracing/redis/index.js.map +1 -1
  125. package/build/cjs/integrations/tracing/redis/vendored/ioredis-instrumentation.js +89 -160
  126. package/build/cjs/integrations/tracing/redis/vendored/ioredis-instrumentation.js.map +1 -1
  127. package/build/cjs/integrations/tracing/redis/vendored/redis-common.js.map +1 -1
  128. package/build/cjs/integrations/tracing/redis/vendored/redis-instrumentation.js +92 -231
  129. package/build/cjs/integrations/tracing/redis/vendored/redis-instrumentation.js.map +1 -1
  130. package/build/cjs/integrations/tracing/redis/vendored/semconv.js +0 -2
  131. package/build/cjs/integrations/tracing/redis/vendored/semconv.js.map +1 -1
  132. package/build/cjs/integrations/tracing/tedious/index.js +1 -25
  133. package/build/cjs/integrations/tracing/tedious/index.js.map +1 -1
  134. package/build/cjs/integrations/tracing/tedious/vendored/instrumentation.js +25 -76
  135. package/build/cjs/integrations/tracing/tedious/vendored/instrumentation.js.map +1 -1
  136. package/build/cjs/integrations/tracing/tedious/vendored/semconv.js.map +1 -1
  137. package/build/cjs/integrations/tracing/tedious/vendored/utils.js.map +1 -1
  138. package/build/cjs/sdk/diagnosticsChannelInjection.js +21 -0
  139. package/build/cjs/sdk/diagnosticsChannelInjection.js.map +1 -0
  140. package/build/cjs/sdk/experimentalUseDiagnosticsChannelInjection.js +19 -0
  141. package/build/cjs/sdk/experimentalUseDiagnosticsChannelInjection.js.map +1 -0
  142. package/build/cjs/sdk/index.js +17 -1
  143. package/build/cjs/sdk/index.js.map +1 -1
  144. package/build/esm/index.js +1 -0
  145. package/build/esm/index.js.map +1 -1
  146. package/build/esm/integrations/fs/index.js +4 -85
  147. package/build/esm/integrations/fs/index.js.map +1 -1
  148. package/build/esm/integrations/fs/vendored/constants.js.map +1 -1
  149. package/build/esm/integrations/fs/vendored/instrumentation.js +147 -177
  150. package/build/esm/integrations/fs/vendored/instrumentation.js.map +1 -1
  151. package/build/esm/integrations/fs/vendored/utils.js.map +1 -1
  152. package/build/esm/integrations/node-fetch/vendored/undici.js.map +1 -1
  153. package/build/esm/integrations/tracing/amqplib/vendored/amqplib.js.map +1 -1
  154. package/build/esm/integrations/tracing/amqplib/vendored/semconv-obsolete.js.map +1 -1
  155. package/build/esm/integrations/tracing/amqplib/vendored/semconv.js.map +1 -1
  156. package/build/esm/integrations/tracing/amqplib/vendored/types.js.map +1 -1
  157. package/build/esm/integrations/tracing/amqplib/vendored/utils.js.map +1 -1
  158. package/build/esm/integrations/tracing/connect/index.js +1 -22
  159. package/build/esm/integrations/tracing/connect/index.js.map +1 -1
  160. package/build/esm/integrations/tracing/connect/vendored/enums/AttributeNames.js +1 -6
  161. package/build/esm/integrations/tracing/connect/vendored/enums/AttributeNames.js.map +1 -1
  162. package/build/esm/integrations/tracing/connect/vendored/instrumentation.js +36 -44
  163. package/build/esm/integrations/tracing/connect/vendored/instrumentation.js.map +1 -1
  164. package/build/esm/integrations/tracing/connect/vendored/internal-types.js.map +1 -1
  165. package/build/esm/integrations/tracing/connect/vendored/utils.js +3 -2
  166. package/build/esm/integrations/tracing/connect/vendored/utils.js.map +1 -1
  167. package/build/esm/integrations/tracing/dataloader/index.js +4 -24
  168. package/build/esm/integrations/tracing/dataloader/index.js.map +1 -1
  169. package/build/esm/integrations/tracing/dataloader/vendored/instrumentation.js +95 -122
  170. package/build/esm/integrations/tracing/dataloader/vendored/instrumentation.js.map +1 -1
  171. package/build/esm/integrations/tracing/fastify/v3/instrumentation.js +1 -1
  172. package/build/esm/integrations/tracing/fastify/v3/instrumentation.js.map +1 -1
  173. package/build/esm/integrations/tracing/fastify/vendored/instrumentation.js.map +1 -1
  174. package/build/esm/integrations/tracing/genericPool/index.js +3 -17
  175. package/build/esm/integrations/tracing/genericPool/index.js.map +1 -1
  176. package/build/esm/integrations/tracing/genericPool/vendored/instrumentation.js +38 -38
  177. package/build/esm/integrations/tracing/genericPool/vendored/instrumentation.js.map +1 -1
  178. package/build/esm/integrations/tracing/graphql/index.js +3 -53
  179. package/build/esm/integrations/tracing/graphql/index.js.map +1 -1
  180. package/build/esm/integrations/tracing/graphql/vendored/enum.js.map +1 -1
  181. package/build/esm/integrations/tracing/graphql/vendored/enums/AttributeNames.js +0 -2
  182. package/build/esm/integrations/tracing/graphql/vendored/enums/AttributeNames.js.map +1 -1
  183. package/build/esm/integrations/tracing/graphql/vendored/instrumentation.js +69 -59
  184. package/build/esm/integrations/tracing/graphql/vendored/instrumentation.js.map +1 -1
  185. package/build/esm/integrations/tracing/graphql/vendored/internal-types.js.map +1 -1
  186. package/build/esm/integrations/tracing/graphql/vendored/symbols.js.map +1 -1
  187. package/build/esm/integrations/tracing/graphql/vendored/utils.js +29 -62
  188. package/build/esm/integrations/tracing/graphql/vendored/utils.js.map +1 -1
  189. package/build/esm/integrations/tracing/hapi/index.js +1 -18
  190. package/build/esm/integrations/tracing/hapi/index.js.map +1 -1
  191. package/build/esm/integrations/tracing/hapi/vendored/enums/AttributeNames.js.map +1 -1
  192. package/build/esm/integrations/tracing/hapi/vendored/instrumentation.js +30 -47
  193. package/build/esm/integrations/tracing/hapi/vendored/instrumentation.js.map +1 -1
  194. package/build/esm/integrations/tracing/hapi/vendored/internal-types.js.map +1 -1
  195. package/build/esm/integrations/tracing/hapi/vendored/semconv.js.map +1 -1
  196. package/build/esm/integrations/tracing/hapi/vendored/utils.js +5 -10
  197. package/build/esm/integrations/tracing/hapi/vendored/utils.js.map +1 -1
  198. package/build/esm/integrations/tracing/index.js +1 -0
  199. package/build/esm/integrations/tracing/index.js.map +1 -1
  200. package/build/esm/integrations/tracing/kafka/vendored/instrumentation.js.map +1 -1
  201. package/build/esm/integrations/tracing/kafka/vendored/internal-types.js.map +1 -1
  202. package/build/esm/integrations/tracing/kafka/vendored/propagator.js.map +1 -1
  203. package/build/esm/integrations/tracing/kafka/vendored/semconv.js.map +1 -1
  204. package/build/esm/integrations/tracing/knex/index.js +4 -19
  205. package/build/esm/integrations/tracing/knex/index.js.map +1 -1
  206. package/build/esm/integrations/tracing/knex/vendored/instrumentation.js +66 -94
  207. package/build/esm/integrations/tracing/knex/vendored/instrumentation.js.map +1 -1
  208. package/build/esm/integrations/tracing/knex/vendored/semconv.js +2 -1
  209. package/build/esm/integrations/tracing/knex/vendored/semconv.js.map +1 -1
  210. package/build/esm/integrations/tracing/knex/vendored/utils.js +3 -15
  211. package/build/esm/integrations/tracing/knex/vendored/utils.js.map +1 -1
  212. package/build/esm/integrations/tracing/koa/index.js +3 -26
  213. package/build/esm/integrations/tracing/koa/index.js.map +1 -1
  214. package/build/esm/integrations/tracing/koa/vendored/enums/AttributeNames.js.map +1 -1
  215. package/build/esm/integrations/tracing/koa/vendored/instrumentation.js +31 -43
  216. package/build/esm/integrations/tracing/koa/vendored/instrumentation.js.map +1 -1
  217. package/build/esm/integrations/tracing/koa/vendored/internal-types.js.map +1 -1
  218. package/build/esm/integrations/tracing/koa/vendored/types.js.map +1 -1
  219. package/build/esm/integrations/tracing/koa/vendored/utils.js.map +1 -1
  220. package/build/esm/integrations/tracing/lrumemoizer/vendored/instrumentation.js.map +1 -1
  221. package/build/esm/integrations/tracing/mongo/index.js +3 -43
  222. package/build/esm/integrations/tracing/mongo/index.js.map +1 -1
  223. package/build/esm/integrations/tracing/mongo/vendored/instrumentation.js +13 -563
  224. package/build/esm/integrations/tracing/mongo/vendored/instrumentation.js.map +1 -1
  225. package/build/esm/integrations/tracing/mongo/vendored/internal-types.js.map +1 -1
  226. package/build/esm/integrations/tracing/mongo/vendored/patches.js +143 -0
  227. package/build/esm/integrations/tracing/mongo/vendored/patches.js.map +1 -0
  228. package/build/esm/integrations/tracing/mongo/vendored/semconv.js +1 -3
  229. package/build/esm/integrations/tracing/mongo/vendored/semconv.js.map +1 -1
  230. package/build/esm/integrations/tracing/mongo/vendored/utils.js +146 -0
  231. package/build/esm/integrations/tracing/mongo/vendored/utils.js.map +1 -0
  232. package/build/esm/integrations/tracing/mongoose/index.js +2 -9
  233. package/build/esm/integrations/tracing/mongoose/index.js.map +1 -1
  234. package/build/esm/integrations/tracing/mongoose/vendored/mongoose.js +59 -206
  235. package/build/esm/integrations/tracing/mongoose/vendored/mongoose.js.map +1 -1
  236. package/build/esm/integrations/tracing/mongoose/vendored/semconv.js +1 -3
  237. package/build/esm/integrations/tracing/mongoose/vendored/semconv.js.map +1 -1
  238. package/build/esm/integrations/tracing/mongoose/vendored/utils.js +20 -50
  239. package/build/esm/integrations/tracing/mongoose/vendored/utils.js.map +1 -1
  240. package/build/esm/integrations/tracing/mysql/vendored/AttributeNames.js.map +1 -1
  241. package/build/esm/integrations/tracing/mysql/vendored/instrumentation.js.map +1 -1
  242. package/build/esm/integrations/tracing/mysql/vendored/semconv.js.map +1 -1
  243. package/build/esm/integrations/tracing/mysql/vendored/utils.js.map +1 -1
  244. package/build/esm/integrations/tracing/mysql2/index.js +2 -9
  245. package/build/esm/integrations/tracing/mysql2/index.js.map +1 -1
  246. package/build/esm/integrations/tracing/mysql2/vendored/instrumentation.js +26 -64
  247. package/build/esm/integrations/tracing/mysql2/vendored/instrumentation.js.map +1 -1
  248. package/build/esm/integrations/tracing/mysql2/vendored/semconv.js.map +1 -1
  249. package/build/esm/integrations/tracing/mysql2/vendored/utils.js +15 -34
  250. package/build/esm/integrations/tracing/mysql2/vendored/utils.js.map +1 -1
  251. package/build/esm/integrations/tracing/postgres/index.js +1 -5
  252. package/build/esm/integrations/tracing/postgres/index.js.map +1 -1
  253. package/build/esm/integrations/tracing/postgres/vendored/enums/AttributeNames.js +0 -1
  254. package/build/esm/integrations/tracing/postgres/vendored/enums/AttributeNames.js.map +1 -1
  255. package/build/esm/integrations/tracing/postgres/vendored/enums/SpanNames.js.map +1 -1
  256. package/build/esm/integrations/tracing/postgres/vendored/instrumentation.js +52 -262
  257. package/build/esm/integrations/tracing/postgres/vendored/instrumentation.js.map +1 -1
  258. package/build/esm/integrations/tracing/postgres/vendored/semconv.js +1 -7
  259. package/build/esm/integrations/tracing/postgres/vendored/semconv.js.map +1 -1
  260. package/build/esm/integrations/tracing/postgres/vendored/utils.js +44 -165
  261. package/build/esm/integrations/tracing/postgres/vendored/utils.js.map +1 -1
  262. package/build/esm/integrations/tracing/prisma/vendored/active-tracing-helper.js.map +1 -1
  263. package/build/esm/integrations/tracing/prisma/vendored/constants.js.map +1 -1
  264. package/build/esm/integrations/tracing/prisma/vendored/global.js.map +1 -1
  265. package/build/esm/integrations/tracing/prisma/vendored/instrumentation.js.map +1 -1
  266. package/build/esm/integrations/tracing/redis/index.js +1 -1
  267. package/build/esm/integrations/tracing/redis/index.js.map +1 -1
  268. package/build/esm/integrations/tracing/redis/vendored/ioredis-instrumentation.js +92 -163
  269. package/build/esm/integrations/tracing/redis/vendored/ioredis-instrumentation.js.map +1 -1
  270. package/build/esm/integrations/tracing/redis/vendored/redis-common.js.map +1 -1
  271. package/build/esm/integrations/tracing/redis/vendored/redis-instrumentation.js +94 -233
  272. package/build/esm/integrations/tracing/redis/vendored/redis-instrumentation.js.map +1 -1
  273. package/build/esm/integrations/tracing/redis/vendored/semconv.js +1 -2
  274. package/build/esm/integrations/tracing/redis/vendored/semconv.js.map +1 -1
  275. package/build/esm/integrations/tracing/tedious/index.js +3 -27
  276. package/build/esm/integrations/tracing/tedious/index.js.map +1 -1
  277. package/build/esm/integrations/tracing/tedious/vendored/instrumentation.js +29 -79
  278. package/build/esm/integrations/tracing/tedious/vendored/instrumentation.js.map +1 -1
  279. package/build/esm/integrations/tracing/tedious/vendored/semconv.js.map +1 -1
  280. package/build/esm/integrations/tracing/tedious/vendored/utils.js.map +1 -1
  281. package/build/esm/package.json +1 -1
  282. package/build/esm/sdk/diagnosticsChannelInjection.js +17 -0
  283. package/build/esm/sdk/diagnosticsChannelInjection.js.map +1 -0
  284. package/build/esm/sdk/experimentalUseDiagnosticsChannelInjection.js +17 -0
  285. package/build/esm/sdk/experimentalUseDiagnosticsChannelInjection.js.map +1 -0
  286. package/build/esm/sdk/index.js +17 -1
  287. package/build/esm/sdk/index.js.map +1 -1
  288. package/build/import-hook.mjs +6 -0
  289. package/build/types/index.d.ts +1 -0
  290. package/build/types/index.d.ts.map +1 -1
  291. package/build/types/integrations/fs/index.d.ts.map +1 -1
  292. package/build/types/integrations/fs/vendored/constants.d.ts.map +1 -1
  293. package/build/types/integrations/fs/vendored/instrumentation.d.ts +6 -10
  294. package/build/types/integrations/fs/vendored/instrumentation.d.ts.map +1 -1
  295. package/build/types/integrations/fs/vendored/types.d.ts +10 -15
  296. package/build/types/integrations/fs/vendored/types.d.ts.map +1 -1
  297. package/build/types/integrations/fs/vendored/utils.d.ts +2 -2
  298. package/build/types/integrations/fs/vendored/utils.d.ts.map +1 -1
  299. package/build/types/integrations/node-fetch/vendored/internal-types.d.ts.map +1 -1
  300. package/build/types/integrations/node-fetch/vendored/types.d.ts.map +1 -1
  301. package/build/types/integrations/node-fetch/vendored/undici.d.ts.map +1 -1
  302. package/build/types/integrations/tracing/amqplib/vendored/amqplib.d.ts.map +1 -1
  303. package/build/types/integrations/tracing/amqplib/vendored/semconv-obsolete.d.ts.map +1 -1
  304. package/build/types/integrations/tracing/amqplib/vendored/semconv.d.ts.map +1 -1
  305. package/build/types/integrations/tracing/amqplib/vendored/types.d.ts.map +1 -1
  306. package/build/types/integrations/tracing/amqplib/vendored/utils.d.ts.map +1 -1
  307. package/build/types/integrations/tracing/connect/index.d.ts.map +1 -1
  308. package/build/types/integrations/tracing/connect/vendored/enums/AttributeNames.d.ts +0 -4
  309. package/build/types/integrations/tracing/connect/vendored/enums/AttributeNames.d.ts.map +1 -1
  310. package/build/types/integrations/tracing/connect/vendored/instrumentation.d.ts +5 -5
  311. package/build/types/integrations/tracing/connect/vendored/instrumentation.d.ts.map +1 -1
  312. package/build/types/integrations/tracing/connect/vendored/internal-types.d.ts +2 -2
  313. package/build/types/integrations/tracing/connect/vendored/internal-types.d.ts.map +1 -1
  314. package/build/types/integrations/tracing/connect/vendored/utils.d.ts +1 -1
  315. package/build/types/integrations/tracing/connect/vendored/utils.d.ts.map +1 -1
  316. package/build/types/integrations/tracing/dataloader/index.d.ts.map +1 -1
  317. package/build/types/integrations/tracing/dataloader/vendored/instrumentation.d.ts +2 -5
  318. package/build/types/integrations/tracing/dataloader/vendored/instrumentation.d.ts.map +1 -1
  319. package/build/types/integrations/tracing/dataloader/vendored/types.d.ts +20 -8
  320. package/build/types/integrations/tracing/dataloader/vendored/types.d.ts.map +1 -1
  321. package/build/types/integrations/tracing/fastify/vendored/instrumentation.d.ts.map +1 -1
  322. package/build/types/integrations/tracing/genericPool/index.d.ts.map +1 -1
  323. package/build/types/integrations/tracing/genericPool/vendored/generic-pool-types.d.ts +1 -1
  324. package/build/types/integrations/tracing/genericPool/vendored/generic-pool-types.d.ts.map +1 -1
  325. package/build/types/integrations/tracing/genericPool/vendored/instrumentation.d.ts +2 -1
  326. package/build/types/integrations/tracing/genericPool/vendored/instrumentation.d.ts.map +1 -1
  327. package/build/types/integrations/tracing/graphql/index.d.ts.map +1 -1
  328. package/build/types/integrations/tracing/graphql/vendored/enum.d.ts.map +1 -1
  329. package/build/types/integrations/tracing/graphql/vendored/enums/AttributeNames.d.ts +1 -3
  330. package/build/types/integrations/tracing/graphql/vendored/enums/AttributeNames.d.ts.map +1 -1
  331. package/build/types/integrations/tracing/graphql/vendored/instrumentation.d.ts +7 -2
  332. package/build/types/integrations/tracing/graphql/vendored/instrumentation.d.ts.map +1 -1
  333. package/build/types/integrations/tracing/graphql/vendored/internal-types.d.ts +4 -4
  334. package/build/types/integrations/tracing/graphql/vendored/internal-types.d.ts.map +1 -1
  335. package/build/types/integrations/tracing/graphql/vendored/symbols.d.ts.map +1 -1
  336. package/build/types/integrations/tracing/graphql/vendored/types.d.ts +5 -43
  337. package/build/types/integrations/tracing/graphql/vendored/types.d.ts.map +1 -1
  338. package/build/types/integrations/tracing/graphql/vendored/utils.d.ts +8 -11
  339. package/build/types/integrations/tracing/graphql/vendored/utils.d.ts.map +1 -1
  340. package/build/types/integrations/tracing/hapi/index.d.ts.map +1 -1
  341. package/build/types/integrations/tracing/hapi/vendored/enums/AttributeNames.d.ts.map +1 -1
  342. package/build/types/integrations/tracing/hapi/vendored/instrumentation.d.ts +2 -2
  343. package/build/types/integrations/tracing/hapi/vendored/instrumentation.d.ts.map +1 -1
  344. package/build/types/integrations/tracing/hapi/vendored/internal-types.d.ts.map +1 -1
  345. package/build/types/integrations/tracing/hapi/vendored/semconv.d.ts.map +1 -1
  346. package/build/types/integrations/tracing/hapi/vendored/utils.d.ts +3 -4
  347. package/build/types/integrations/tracing/hapi/vendored/utils.d.ts.map +1 -1
  348. package/build/types/integrations/tracing/index.d.ts.map +1 -1
  349. package/build/types/integrations/tracing/kafka/vendored/instrumentation.d.ts.map +1 -1
  350. package/build/types/integrations/tracing/kafka/vendored/internal-types.d.ts.map +1 -1
  351. package/build/types/integrations/tracing/kafka/vendored/propagator.d.ts.map +1 -1
  352. package/build/types/integrations/tracing/kafka/vendored/semconv.d.ts.map +1 -1
  353. package/build/types/integrations/tracing/kafka/vendored/types.d.ts.map +1 -1
  354. package/build/types/integrations/tracing/knex/index.d.ts.map +1 -1
  355. package/build/types/integrations/tracing/knex/vendored/instrumentation.d.ts +8 -10
  356. package/build/types/integrations/tracing/knex/vendored/instrumentation.d.ts.map +1 -1
  357. package/build/types/integrations/tracing/knex/vendored/semconv.d.ts +1 -0
  358. package/build/types/integrations/tracing/knex/vendored/semconv.d.ts.map +1 -1
  359. package/build/types/integrations/tracing/knex/vendored/utils.d.ts +0 -6
  360. package/build/types/integrations/tracing/knex/vendored/utils.d.ts.map +1 -1
  361. package/build/types/integrations/tracing/koa/index.d.ts.map +1 -1
  362. package/build/types/integrations/tracing/koa/vendored/enums/AttributeNames.d.ts.map +1 -1
  363. package/build/types/integrations/tracing/koa/vendored/instrumentation.d.ts +1 -1
  364. package/build/types/integrations/tracing/koa/vendored/instrumentation.d.ts.map +1 -1
  365. package/build/types/integrations/tracing/koa/vendored/internal-types.d.ts +4 -4
  366. package/build/types/integrations/tracing/koa/vendored/internal-types.d.ts.map +1 -1
  367. package/build/types/integrations/tracing/koa/vendored/types.d.ts +2 -39
  368. package/build/types/integrations/tracing/koa/vendored/types.d.ts.map +1 -1
  369. package/build/types/integrations/tracing/koa/vendored/utils.d.ts +3 -3
  370. package/build/types/integrations/tracing/koa/vendored/utils.d.ts.map +1 -1
  371. package/build/types/integrations/tracing/lrumemoizer/vendored/instrumentation.d.ts.map +1 -1
  372. package/build/types/integrations/tracing/mongo/index.d.ts +0 -4
  373. package/build/types/integrations/tracing/mongo/index.d.ts.map +1 -1
  374. package/build/types/integrations/tracing/mongo/vendored/instrumentation.d.ts +4 -72
  375. package/build/types/integrations/tracing/mongo/vendored/instrumentation.d.ts.map +1 -1
  376. package/build/types/integrations/tracing/mongo/vendored/internal-types.d.ts +0 -59
  377. package/build/types/integrations/tracing/mongo/vendored/internal-types.d.ts.map +1 -1
  378. package/build/types/integrations/tracing/mongo/vendored/patches.d.ts +15 -0
  379. package/build/types/integrations/tracing/mongo/vendored/patches.d.ts.map +1 -0
  380. package/build/types/integrations/tracing/mongo/vendored/semconv.d.ts +0 -54
  381. package/build/types/integrations/tracing/mongo/vendored/semconv.d.ts.map +1 -1
  382. package/build/types/integrations/tracing/mongo/vendored/utils.d.ts +24 -0
  383. package/build/types/integrations/tracing/mongo/vendored/utils.d.ts.map +1 -0
  384. package/build/types/integrations/tracing/mongoose/index.d.ts.map +1 -1
  385. package/build/types/integrations/tracing/mongoose/vendored/mongoose-types.d.ts +3 -0
  386. package/build/types/integrations/tracing/mongoose/vendored/mongoose-types.d.ts.map +1 -1
  387. package/build/types/integrations/tracing/mongoose/vendored/mongoose.d.ts +3 -8
  388. package/build/types/integrations/tracing/mongoose/vendored/mongoose.d.ts.map +1 -1
  389. package/build/types/integrations/tracing/mongoose/vendored/semconv.d.ts +0 -14
  390. package/build/types/integrations/tracing/mongoose/vendored/semconv.d.ts.map +1 -1
  391. package/build/types/integrations/tracing/mongoose/vendored/utils.d.ts +4 -6
  392. package/build/types/integrations/tracing/mongoose/vendored/utils.d.ts.map +1 -1
  393. package/build/types/integrations/tracing/mysql/vendored/AttributeNames.d.ts.map +1 -1
  394. package/build/types/integrations/tracing/mysql/vendored/instrumentation.d.ts.map +1 -1
  395. package/build/types/integrations/tracing/mysql/vendored/mysql-types.d.ts.map +1 -1
  396. package/build/types/integrations/tracing/mysql/vendored/semconv.d.ts.map +1 -1
  397. package/build/types/integrations/tracing/mysql/vendored/types.d.ts.map +1 -1
  398. package/build/types/integrations/tracing/mysql/vendored/utils.d.ts.map +1 -1
  399. package/build/types/integrations/tracing/mysql2/index.d.ts.map +1 -1
  400. package/build/types/integrations/tracing/mysql2/vendored/instrumentation.d.ts +3 -6
  401. package/build/types/integrations/tracing/mysql2/vendored/instrumentation.d.ts.map +1 -1
  402. package/build/types/integrations/tracing/mysql2/vendored/semconv.d.ts.map +1 -1
  403. package/build/types/integrations/tracing/mysql2/vendored/utils.d.ts +3 -5
  404. package/build/types/integrations/tracing/mysql2/vendored/utils.d.ts.map +1 -1
  405. package/build/types/integrations/tracing/postgres/index.d.ts.map +1 -1
  406. package/build/types/integrations/tracing/postgres/vendored/enums/AttributeNames.d.ts +0 -1
  407. package/build/types/integrations/tracing/postgres/vendored/enums/AttributeNames.d.ts.map +1 -1
  408. package/build/types/integrations/tracing/postgres/vendored/enums/SpanNames.d.ts.map +1 -1
  409. package/build/types/integrations/tracing/postgres/vendored/instrumentation.d.ts +1 -9
  410. package/build/types/integrations/tracing/postgres/vendored/instrumentation.d.ts.map +1 -1
  411. package/build/types/integrations/tracing/postgres/vendored/internal-types.d.ts +0 -2
  412. package/build/types/integrations/tracing/postgres/vendored/internal-types.d.ts.map +1 -1
  413. package/build/types/integrations/tracing/postgres/vendored/pg-pool-types.d.ts.map +1 -1
  414. package/build/types/integrations/tracing/postgres/vendored/pg-types.d.ts.map +1 -1
  415. package/build/types/integrations/tracing/postgres/vendored/semconv.d.ts +0 -50
  416. package/build/types/integrations/tracing/postgres/vendored/semconv.d.ts.map +1 -1
  417. package/build/types/integrations/tracing/postgres/vendored/types.d.ts +2 -56
  418. package/build/types/integrations/tracing/postgres/vendored/types.d.ts.map +1 -1
  419. package/build/types/integrations/tracing/postgres/vendored/utils.d.ts +13 -26
  420. package/build/types/integrations/tracing/postgres/vendored/utils.d.ts.map +1 -1
  421. package/build/types/integrations/tracing/prisma/vendored/active-tracing-helper.d.ts.map +1 -1
  422. package/build/types/integrations/tracing/prisma/vendored/constants.d.ts.map +1 -1
  423. package/build/types/integrations/tracing/prisma/vendored/global.d.ts.map +1 -1
  424. package/build/types/integrations/tracing/prisma/vendored/instrumentation.d.ts.map +1 -1
  425. package/build/types/integrations/tracing/prisma/vendored/types.d.ts.map +1 -1
  426. package/build/types/integrations/tracing/redis/index.d.ts.map +1 -1
  427. package/build/types/integrations/tracing/redis/vendored/ioredis-instrumentation.d.ts +3 -8
  428. package/build/types/integrations/tracing/redis/vendored/ioredis-instrumentation.d.ts.map +1 -1
  429. package/build/types/integrations/tracing/redis/vendored/redis-common.d.ts.map +1 -1
  430. package/build/types/integrations/tracing/redis/vendored/redis-instrumentation.d.ts.map +1 -1
  431. package/build/types/integrations/tracing/redis/vendored/semconv.d.ts.map +1 -1
  432. package/build/types/integrations/tracing/redis/vendored/types.d.ts +2 -36
  433. package/build/types/integrations/tracing/redis/vendored/types.d.ts.map +1 -1
  434. package/build/types/integrations/tracing/tedious/index.d.ts.map +1 -1
  435. package/build/types/integrations/tracing/tedious/vendored/instrumentation.d.ts +3 -14
  436. package/build/types/integrations/tracing/tedious/vendored/instrumentation.d.ts.map +1 -1
  437. package/build/types/integrations/tracing/tedious/vendored/semconv.d.ts.map +1 -1
  438. package/build/types/integrations/tracing/tedious/vendored/utils.d.ts.map +1 -1
  439. package/build/types/sdk/diagnosticsChannelInjection.d.ts +41 -0
  440. package/build/types/sdk/diagnosticsChannelInjection.d.ts.map +1 -0
  441. package/build/types/sdk/experimentalUseDiagnosticsChannelInjection.d.ts +34 -0
  442. package/build/types/sdk/experimentalUseDiagnosticsChannelInjection.d.ts.map +1 -0
  443. package/build/types/sdk/index.d.ts.map +1 -1
  444. package/build/types-ts3.8/index.d.ts +1 -0
  445. package/build/types-ts3.8/integrations/fs/vendored/instrumentation.d.ts +6 -10
  446. package/build/types-ts3.8/integrations/fs/vendored/types.d.ts +10 -15
  447. package/build/types-ts3.8/integrations/fs/vendored/utils.d.ts +2 -2
  448. package/build/types-ts3.8/integrations/tracing/connect/vendored/enums/AttributeNames.d.ts +0 -4
  449. package/build/types-ts3.8/integrations/tracing/connect/vendored/instrumentation.d.ts +4 -4
  450. package/build/types-ts3.8/integrations/tracing/connect/vendored/internal-types.d.ts +2 -2
  451. package/build/types-ts3.8/integrations/tracing/dataloader/vendored/instrumentation.d.ts +2 -5
  452. package/build/types-ts3.8/integrations/tracing/dataloader/vendored/types.d.ts +20 -8
  453. package/build/types-ts3.8/integrations/tracing/genericPool/vendored/generic-pool-types.d.ts +1 -1
  454. package/build/types-ts3.8/integrations/tracing/genericPool/vendored/instrumentation.d.ts +2 -1
  455. package/build/types-ts3.8/integrations/tracing/graphql/vendored/enums/AttributeNames.d.ts +1 -3
  456. package/build/types-ts3.8/integrations/tracing/graphql/vendored/instrumentation.d.ts +6 -1
  457. package/build/types-ts3.8/integrations/tracing/graphql/vendored/internal-types.d.ts +3 -3
  458. package/build/types-ts3.8/integrations/tracing/graphql/vendored/types.d.ts +4 -42
  459. package/build/types-ts3.8/integrations/tracing/graphql/vendored/utils.d.ts +6 -9
  460. package/build/types-ts3.8/integrations/tracing/hapi/vendored/instrumentation.d.ts +2 -2
  461. package/build/types-ts3.8/integrations/tracing/hapi/vendored/utils.d.ts +1 -2
  462. package/build/types-ts3.8/integrations/tracing/knex/vendored/instrumentation.d.ts +8 -10
  463. package/build/types-ts3.8/integrations/tracing/knex/vendored/semconv.d.ts +1 -0
  464. package/build/types-ts3.8/integrations/tracing/knex/vendored/utils.d.ts +0 -6
  465. package/build/types-ts3.8/integrations/tracing/koa/vendored/internal-types.d.ts +4 -4
  466. package/build/types-ts3.8/integrations/tracing/koa/vendored/types.d.ts +1 -38
  467. package/build/types-ts3.8/integrations/tracing/mongo/index.d.ts +0 -4
  468. package/build/types-ts3.8/integrations/tracing/mongo/vendored/instrumentation.d.ts +4 -72
  469. package/build/types-ts3.8/integrations/tracing/mongo/vendored/internal-types.d.ts +0 -59
  470. package/build/types-ts3.8/integrations/tracing/mongo/vendored/patches.d.ts +15 -0
  471. package/build/types-ts3.8/integrations/tracing/mongo/vendored/semconv.d.ts +0 -54
  472. package/build/types-ts3.8/integrations/tracing/mongo/vendored/utils.d.ts +24 -0
  473. package/build/types-ts3.8/integrations/tracing/mongoose/vendored/mongoose-types.d.ts +3 -0
  474. package/build/types-ts3.8/integrations/tracing/mongoose/vendored/mongoose.d.ts +3 -8
  475. package/build/types-ts3.8/integrations/tracing/mongoose/vendored/semconv.d.ts +0 -14
  476. package/build/types-ts3.8/integrations/tracing/mongoose/vendored/utils.d.ts +4 -6
  477. package/build/types-ts3.8/integrations/tracing/mysql2/vendored/instrumentation.d.ts +3 -6
  478. package/build/types-ts3.8/integrations/tracing/mysql2/vendored/utils.d.ts +3 -5
  479. package/build/types-ts3.8/integrations/tracing/postgres/vendored/enums/AttributeNames.d.ts +0 -1
  480. package/build/types-ts3.8/integrations/tracing/postgres/vendored/instrumentation.d.ts +0 -8
  481. package/build/types-ts3.8/integrations/tracing/postgres/vendored/internal-types.d.ts +0 -2
  482. package/build/types-ts3.8/integrations/tracing/postgres/vendored/semconv.d.ts +0 -50
  483. package/build/types-ts3.8/integrations/tracing/postgres/vendored/types.d.ts +1 -55
  484. package/build/types-ts3.8/integrations/tracing/postgres/vendored/utils.d.ts +13 -26
  485. package/build/types-ts3.8/integrations/tracing/redis/vendored/ioredis-instrumentation.d.ts +3 -8
  486. package/build/types-ts3.8/integrations/tracing/redis/vendored/types.d.ts +2 -36
  487. package/build/types-ts3.8/integrations/tracing/tedious/vendored/instrumentation.d.ts +3 -14
  488. package/build/types-ts3.8/sdk/diagnosticsChannelInjection.d.ts +41 -0
  489. package/build/types-ts3.8/sdk/experimentalUseDiagnosticsChannelInjection.d.ts +34 -0
  490. package/package.json +20 -6
  491. package/build/cjs/integrations/tracing/knex/vendored/constants.js +0 -16
  492. package/build/cjs/integrations/tracing/knex/vendored/constants.js.map +0 -1
  493. package/build/cjs/integrations/tracing/postgres/vendored/internal-types.js +0 -6
  494. package/build/cjs/integrations/tracing/postgres/vendored/internal-types.js.map +0 -1
  495. package/build/cjs/integrations/tracing/utils/sql-common.js +0 -43
  496. package/build/cjs/integrations/tracing/utils/sql-common.js.map +0 -1
  497. package/build/esm/integrations/tracing/knex/vendored/constants.js +0 -13
  498. package/build/esm/integrations/tracing/knex/vendored/constants.js.map +0 -1
  499. package/build/esm/integrations/tracing/postgres/vendored/internal-types.js +0 -4
  500. package/build/esm/integrations/tracing/postgres/vendored/internal-types.js.map +0 -1
  501. package/build/esm/integrations/tracing/utils/sql-common.js +0 -41
  502. package/build/esm/integrations/tracing/utils/sql-common.js.map +0 -1
  503. package/build/types/integrations/tracing/dataloader/vendored/dataloader-types.d.ts +0 -14
  504. package/build/types/integrations/tracing/dataloader/vendored/dataloader-types.d.ts.map +0 -1
  505. package/build/types/integrations/tracing/knex/vendored/constants.d.ts +0 -3
  506. package/build/types/integrations/tracing/knex/vendored/constants.d.ts.map +0 -1
  507. package/build/types/integrations/tracing/knex/vendored/types.d.ts +0 -8
  508. package/build/types/integrations/tracing/knex/vendored/types.d.ts.map +0 -1
  509. package/build/types/integrations/tracing/mongo/vendored/types.d.ts +0 -51
  510. package/build/types/integrations/tracing/mongo/vendored/types.d.ts.map +0 -1
  511. package/build/types/integrations/tracing/mongoose/vendored/types.d.ts +0 -36
  512. package/build/types/integrations/tracing/mongoose/vendored/types.d.ts.map +0 -1
  513. package/build/types/integrations/tracing/mysql2/vendored/types.d.ts +0 -18
  514. package/build/types/integrations/tracing/mysql2/vendored/types.d.ts.map +0 -1
  515. package/build/types/integrations/tracing/tedious/vendored/types.d.ts +0 -10
  516. package/build/types/integrations/tracing/tedious/vendored/types.d.ts.map +0 -1
  517. package/build/types-ts3.8/integrations/tracing/dataloader/vendored/dataloader-types.d.ts +0 -14
  518. package/build/types-ts3.8/integrations/tracing/knex/vendored/constants.d.ts +0 -3
  519. package/build/types-ts3.8/integrations/tracing/knex/vendored/types.d.ts +0 -8
  520. package/build/types-ts3.8/integrations/tracing/mongo/vendored/types.d.ts +0 -51
  521. package/build/types-ts3.8/integrations/tracing/mongoose/vendored/types.d.ts +0 -36
  522. package/build/types-ts3.8/integrations/tracing/mysql2/vendored/types.d.ts +0 -18
  523. package/build/types-ts3.8/integrations/tracing/tedious/vendored/types.d.ts +0 -10
@@ -1,16 +1,31 @@
1
- import { trace, context, SpanKind, SpanStatusCode } from '@opentelemetry/api';
2
- import { SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN } from '@sentry/core';
3
- import { InstrumentationBase, semconvStabilityFromStr, InstrumentationNodeModuleDefinition, isWrapped, SemconvStability, safeExecuteInTheMiddle } from '@opentelemetry/instrumentation';
1
+ import { SpanKind } from '@opentelemetry/api';
2
+ import { InstrumentationBase, InstrumentationNodeModuleDefinition, isWrapped } from '@opentelemetry/instrumentation';
3
+ import { SDK_VERSION, startInactiveSpan, getActiveSpan, withActiveSpan, debug, SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN, SPAN_STATUS_ERROR } from '@sentry/core';
4
+ import { DEBUG_BUILD } from '../../../../debug-build.js';
4
5
  import { InstrumentationNodeModuleFile } from '../../InstrumentationNodeModuleFile.js';
5
- import { ATTR_DB_QUERY_TEXT, ATTR_DB_OPERATION_NAME, ATTR_DB_SYSTEM_NAME, ATTR_SERVER_PORT, ATTR_SERVER_ADDRESS } from '@opentelemetry/semantic-conventions';
6
6
  import { defaultDbStatementSerializer } from './redis-common.js';
7
- import { DB_SYSTEM_VALUE_REDIS, ATTR_DB_STATEMENT, ATTR_DB_SYSTEM, DB_SYSTEM_NAME_VALUE_REDIS, ATTR_NET_PEER_PORT, ATTR_NET_PEER_NAME, ATTR_DB_CONNECTION_STRING } from './semconv.js';
7
+ import { ATTR_DB_STATEMENT, DB_SYSTEM_VALUE_REDIS, ATTR_DB_SYSTEM, ATTR_NET_PEER_NAME, ATTR_NET_PEER_PORT, ATTR_DB_CONNECTION_STRING } from './semconv.js';
8
8
 
9
- const PACKAGE_NAME = "@opentelemetry/instrumentation-redis";
10
- const PACKAGE_VERSION = "0.62.0";
9
+ const PACKAGE_NAME = "@sentry/instrumentation-redis";
10
+ const ORIGIN = "auto.db.otel.redis";
11
11
  const OTEL_OPEN_SPANS = /* @__PURE__ */ Symbol("opentelemetry.instrumentation.redis.open_spans");
12
12
  const MULTI_COMMAND_OPTIONS = /* @__PURE__ */ Symbol("opentelemetry.instrumentation.redis.multi_command_options");
13
- function removeCredentialsFromDBConnectionStringAttribute(diagLogger, url) {
13
+ function endSpan(span, err) {
14
+ if (err) {
15
+ span.setStatus({ code: SPAN_STATUS_ERROR, message: err.message });
16
+ }
17
+ span.end();
18
+ }
19
+ function runResponseHook(responseHook, span, commandName, commandArgs, response) {
20
+ if (!responseHook) {
21
+ return;
22
+ }
23
+ try {
24
+ responseHook(span, commandName, commandArgs, response);
25
+ } catch {
26
+ }
27
+ }
28
+ function removeCredentialsFromDBConnectionStringAttribute(url) {
14
29
  if (typeof url !== "string" || !url) {
15
30
  return void 0;
16
31
  }
@@ -21,68 +36,22 @@ function removeCredentialsFromDBConnectionStringAttribute(diagLogger, url) {
21
36
  u.password = "";
22
37
  return u.href;
23
38
  } catch (err) {
24
- diagLogger.error("failed to sanitize redis connection url", err);
39
+ DEBUG_BUILD && debug.error("failed to sanitize redis connection url", err);
25
40
  }
26
41
  return void 0;
27
42
  }
28
- function getClientAttributes(diagLogger, options, semconvStability) {
29
- const attributes = {};
30
- if (semconvStability & SemconvStability.OLD) {
31
- Object.assign(attributes, {
32
- [ATTR_DB_SYSTEM]: DB_SYSTEM_VALUE_REDIS,
33
- [ATTR_NET_PEER_NAME]: options?.socket?.host,
34
- [ATTR_NET_PEER_PORT]: options?.socket?.port,
35
- [ATTR_DB_CONNECTION_STRING]: removeCredentialsFromDBConnectionStringAttribute(diagLogger, options?.url)
36
- });
37
- }
38
- if (semconvStability & SemconvStability.STABLE) {
39
- Object.assign(attributes, {
40
- [ATTR_DB_SYSTEM_NAME]: DB_SYSTEM_NAME_VALUE_REDIS,
41
- [ATTR_SERVER_ADDRESS]: options?.socket?.host,
42
- [ATTR_SERVER_PORT]: options?.socket?.port
43
- });
44
- }
45
- return attributes;
46
- }
47
- function endSpanV2(span, err) {
48
- if (err) {
49
- span.setStatus({
50
- code: SpanStatusCode.ERROR,
51
- message: err.message
52
- });
53
- }
54
- span.end();
55
- }
56
- function getTracedCreateClient(original) {
57
- return function createClientTrace() {
58
- const client = original.apply(this, arguments);
59
- return context.bind(context.active(), client);
60
- };
61
- }
62
- function getTracedCreateStreamTrace(original) {
63
- return function create_stream_trace() {
64
- if (!Object.prototype.hasOwnProperty.call(this, "stream")) {
65
- Object.defineProperty(this, "stream", {
66
- get() {
67
- return this._patched_redis_stream;
68
- },
69
- set(val) {
70
- context.bind(context.active(), val);
71
- this._patched_redis_stream = val;
72
- }
73
- });
74
- }
75
- return original.apply(this, arguments);
43
+ function getClientAttributes(options) {
44
+ return {
45
+ [ATTR_DB_SYSTEM]: DB_SYSTEM_VALUE_REDIS,
46
+ [ATTR_NET_PEER_NAME]: options?.socket?.host,
47
+ [ATTR_NET_PEER_PORT]: options?.socket?.port,
48
+ [ATTR_DB_CONNECTION_STRING]: removeCredentialsFromDBConnectionStringAttribute(options?.url),
49
+ [SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN]: ORIGIN
76
50
  };
77
51
  }
78
52
  const _RedisInstrumentationV2_V3 = class _RedisInstrumentationV2_V3 extends InstrumentationBase {
79
53
  constructor(config = {}) {
80
- super(PACKAGE_NAME, PACKAGE_VERSION, config);
81
- this._semconvStability = config.semconvStability ? config.semconvStability : semconvStabilityFromStr("database", process.env["OTEL_SEMCONV_STABILITY_OPT_IN"]);
82
- }
83
- setConfig(config = {}) {
84
- super.setConfig(config);
85
- this._semconvStability = config.semconvStability ? config.semconvStability : semconvStabilityFromStr("database", process.env["OTEL_SEMCONV_STABILITY_OPT_IN"]);
54
+ super(PACKAGE_NAME, SDK_VERSION, config);
86
55
  }
87
56
  init() {
88
57
  return [
@@ -94,21 +63,11 @@ const _RedisInstrumentationV2_V3 = class _RedisInstrumentationV2_V3 extends Inst
94
63
  this._unwrap(moduleExports.RedisClient.prototype, "internal_send_command");
95
64
  }
96
65
  this._wrap(moduleExports.RedisClient.prototype, "internal_send_command", this._getPatchInternalSendCommand());
97
- if (isWrapped(moduleExports.RedisClient.prototype["create_stream"])) {
98
- this._unwrap(moduleExports.RedisClient.prototype, "create_stream");
99
- }
100
- this._wrap(moduleExports.RedisClient.prototype, "create_stream", this._getPatchCreateStream());
101
- if (isWrapped(moduleExports.createClient)) {
102
- this._unwrap(moduleExports, "createClient");
103
- }
104
- this._wrap(moduleExports, "createClient", this._getPatchCreateClient());
105
66
  return moduleExports;
106
67
  },
107
68
  (moduleExports) => {
108
69
  if (moduleExports === void 0) return;
109
70
  this._unwrap(moduleExports.RedisClient.prototype, "internal_send_command");
110
- this._unwrap(moduleExports.RedisClient.prototype, "create_stream");
111
- this._unwrap(moduleExports, "createClient");
112
71
  }
113
72
  )
114
73
  ];
@@ -120,102 +79,47 @@ const _RedisInstrumentationV2_V3 = class _RedisInstrumentationV2_V3 extends Inst
120
79
  if (arguments.length !== 1 || typeof cmd !== "object") {
121
80
  return original.apply(this, arguments);
122
81
  }
123
- const config = instrumentation.getConfig();
124
- const hasNoParentSpan = trace.getSpan(context.active()) === void 0;
125
- if (config.requireParentSpan === true && hasNoParentSpan) {
126
- return original.apply(this, arguments);
127
- }
128
- const dbStatementSerializer = config?.dbStatementSerializer || defaultDbStatementSerializer;
129
- const attributes = {};
130
- if (instrumentation._semconvStability & SemconvStability.OLD) {
131
- Object.assign(attributes, {
132
- [ATTR_DB_SYSTEM]: DB_SYSTEM_VALUE_REDIS,
133
- [ATTR_DB_STATEMENT]: dbStatementSerializer(cmd.command, cmd.args)
134
- });
82
+ const attributes = {
83
+ [ATTR_DB_SYSTEM]: DB_SYSTEM_VALUE_REDIS,
84
+ [ATTR_DB_STATEMENT]: defaultDbStatementSerializer(cmd.command, cmd.args),
85
+ [SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN]: ORIGIN
86
+ };
87
+ if (this.connection_options) {
88
+ attributes[ATTR_NET_PEER_NAME] = this.connection_options.host;
89
+ attributes[ATTR_NET_PEER_PORT] = this.connection_options.port;
135
90
  }
136
- if (instrumentation._semconvStability & SemconvStability.STABLE) {
137
- Object.assign(attributes, {
138
- [ATTR_DB_SYSTEM_NAME]: DB_SYSTEM_NAME_VALUE_REDIS,
139
- [ATTR_DB_OPERATION_NAME]: cmd.command,
140
- [ATTR_DB_QUERY_TEXT]: dbStatementSerializer(cmd.command, cmd.args)
141
- });
91
+ if (this.address) {
92
+ attributes[ATTR_DB_CONNECTION_STRING] = `redis://${this.address}`;
142
93
  }
143
- attributes[SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN] = "auto.db.otel.redis";
144
- const span = instrumentation.tracer.startSpan(`${_RedisInstrumentationV2_V3.COMPONENT}-${cmd.command}`, {
94
+ const span = startInactiveSpan({
95
+ name: `${_RedisInstrumentationV2_V3.COMPONENT}-${cmd.command}`,
145
96
  kind: SpanKind.CLIENT,
146
97
  attributes
147
98
  });
148
- if (this.connection_options) {
149
- const connectionAttributes = {};
150
- if (instrumentation._semconvStability & SemconvStability.OLD) {
151
- Object.assign(connectionAttributes, {
152
- [ATTR_NET_PEER_NAME]: this.connection_options.host,
153
- [ATTR_NET_PEER_PORT]: this.connection_options.port
154
- });
155
- }
156
- if (instrumentation._semconvStability & SemconvStability.STABLE) {
157
- Object.assign(connectionAttributes, {
158
- [ATTR_SERVER_ADDRESS]: this.connection_options.host,
159
- [ATTR_SERVER_PORT]: this.connection_options.port
160
- });
161
- }
162
- span.setAttributes(connectionAttributes);
163
- }
164
- if (this.address && instrumentation._semconvStability & SemconvStability.OLD) {
165
- span.setAttribute(ATTR_DB_CONNECTION_STRING, `redis://${this.address}`);
166
- }
167
99
  const originalCallback = arguments[0].callback;
168
100
  if (originalCallback) {
169
- const originalContext = context.active();
101
+ const parentSpan = getActiveSpan();
170
102
  arguments[0].callback = function callback(err, reply) {
171
- if (config?.responseHook) {
172
- const responseHook = config.responseHook;
173
- safeExecuteInTheMiddle(
174
- () => {
175
- responseHook(span, cmd.command, cmd.args, reply);
176
- },
177
- (e) => {
178
- if (e) {
179
- instrumentation._diag.error("Error executing responseHook", e);
180
- }
181
- },
182
- true
183
- );
184
- }
185
- endSpanV2(span, err);
186
- return context.with(originalContext, originalCallback, this, ...arguments);
103
+ runResponseHook(instrumentation.getConfig().responseHook, span, cmd.command, cmd.args, reply);
104
+ endSpan(span, err);
105
+ return withActiveSpan(parentSpan ?? null, () => originalCallback.apply(this, arguments));
187
106
  };
188
107
  }
189
108
  try {
190
109
  return original.apply(this, arguments);
191
110
  } catch (rethrow) {
192
- endSpanV2(span, rethrow);
111
+ endSpan(span, rethrow);
193
112
  throw rethrow;
194
113
  }
195
114
  };
196
115
  };
197
116
  }
198
- _getPatchCreateClient() {
199
- return function createClient(original) {
200
- return getTracedCreateClient(original);
201
- };
202
- }
203
- _getPatchCreateStream() {
204
- return function createReadStream(original) {
205
- return getTracedCreateStreamTrace(original);
206
- };
207
- }
208
117
  };
209
118
  _RedisInstrumentationV2_V3.COMPONENT = "redis";
210
119
  let RedisInstrumentationV2_V3 = _RedisInstrumentationV2_V3;
211
120
  const _RedisInstrumentationV4_V5 = class _RedisInstrumentationV4_V5 extends InstrumentationBase {
212
121
  constructor(config = {}) {
213
- super(PACKAGE_NAME, PACKAGE_VERSION, config);
214
- this._semconvStability = config.semconvStability ? config.semconvStability : semconvStabilityFromStr("database", process.env["OTEL_SEMCONV_STABILITY_OPT_IN"]);
215
- }
216
- setConfig(config = {}) {
217
- super.setConfig(config);
218
- this._semconvStability = config.semconvStability ? config.semconvStability : semconvStabilityFromStr("database", process.env["OTEL_SEMCONV_STABILITY_OPT_IN"]);
122
+ super(PACKAGE_NAME, SDK_VERSION, config);
219
123
  }
220
124
  init() {
221
125
  return [
@@ -230,7 +134,7 @@ const _RedisInstrumentationV4_V5 = class _RedisInstrumentationV4_V5 extends Inst
230
134
  (moduleExports, moduleVersion) => {
231
135
  const transformCommandArguments = moduleExports.transformCommandArguments;
232
136
  if (!transformCommandArguments) {
233
- this._diag.error("internal instrumentation error, missing transformCommandArguments function");
137
+ DEBUG_BUILD && debug.error("internal instrumentation error, missing transformCommandArguments function");
234
138
  return moduleExports;
235
139
  }
236
140
  const functionToPatch = moduleVersion?.startsWith("1.0.") ? "extendWithCommands" : "attachCommands";
@@ -257,11 +161,11 @@ const _RedisInstrumentationV4_V5 = class _RedisInstrumentationV4_V5 extends Inst
257
161
  if (isWrapped(redisClientMultiCommandPrototype?.exec)) {
258
162
  this._unwrap(redisClientMultiCommandPrototype, "exec");
259
163
  }
260
- this._wrap(redisClientMultiCommandPrototype, "exec", this._getPatchMultiCommandsExec(false));
164
+ this._wrap(redisClientMultiCommandPrototype, "exec", this._getPatchMultiCommandsExec());
261
165
  if (isWrapped(redisClientMultiCommandPrototype?.execAsPipeline)) {
262
166
  this._unwrap(redisClientMultiCommandPrototype, "execAsPipeline");
263
167
  }
264
- this._wrap(redisClientMultiCommandPrototype, "execAsPipeline", this._getPatchMultiCommandsExec(true));
168
+ this._wrap(redisClientMultiCommandPrototype, "execAsPipeline", this._getPatchMultiCommandsExec());
265
169
  if (isWrapped(redisClientMultiCommandPrototype?.addCommand)) {
266
170
  this._unwrap(redisClientMultiCommandPrototype, "addCommand");
267
171
  }
@@ -349,26 +253,26 @@ const _RedisInstrumentationV4_V5 = class _RedisInstrumentationV4_V5 extends Inst
349
253
  };
350
254
  };
351
255
  }
352
- _getPatchMultiCommandsExec(isPipeline) {
256
+ _getPatchMultiCommandsExec() {
353
257
  const plugin = this;
354
258
  return function execPatchWrapper(original) {
355
259
  return function execPatch() {
356
260
  const execRes = original.apply(this, arguments);
357
261
  if (typeof execRes?.then !== "function") {
358
- plugin._diag.error("non-promise result when patching exec/execAsPipeline");
262
+ DEBUG_BUILD && debug.error("non-promise result when patching exec/execAsPipeline");
359
263
  return execRes;
360
264
  }
361
265
  return execRes.then((redisRes) => {
362
266
  const openSpans = this[OTEL_OPEN_SPANS];
363
- plugin._endSpansWithRedisReplies(openSpans, redisRes, isPipeline);
267
+ plugin._endSpansWithRedisReplies(openSpans, redisRes);
364
268
  return redisRes;
365
269
  }).catch((err) => {
366
270
  const openSpans = this[OTEL_OPEN_SPANS];
367
271
  if (!openSpans) {
368
- plugin._diag.error("cannot find open spans to end for multi/pipeline");
272
+ DEBUG_BUILD && debug.error("cannot find open spans to end for multi/pipeline");
369
273
  } else {
370
274
  const replies = err.constructor.name === "MultiErrorReply" ? err.replies : new Array(openSpans.length).fill(err);
371
- plugin._endSpansWithRedisReplies(openSpans, replies, isPipeline);
275
+ plugin._endSpansWithRedisReplies(openSpans, replies);
372
276
  }
373
277
  return Promise.reject(err);
374
278
  });
@@ -401,69 +305,44 @@ const _RedisInstrumentationV4_V5 = class _RedisInstrumentationV4_V5 extends Inst
401
305
  };
402
306
  }
403
307
  _getPatchedClientConnect() {
404
- const plugin = this;
405
308
  return function connectWrapper(original) {
406
309
  return function patchedConnect() {
407
- const options = this.options;
408
- const attributes = getClientAttributes(plugin._diag, options, plugin._semconvStability);
409
- attributes[SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN] = "auto.db.otel.redis";
410
- const span = plugin.tracer.startSpan(`${_RedisInstrumentationV4_V5.COMPONENT}-connect`, {
310
+ const attributes = getClientAttributes(this.options);
311
+ const span = startInactiveSpan({
312
+ name: `${_RedisInstrumentationV4_V5.COMPONENT}-connect`,
411
313
  kind: SpanKind.CLIENT,
412
314
  attributes
413
315
  });
414
- const res = context.with(trace.setSpan(context.active(), span), () => {
415
- return original.apply(this);
416
- });
417
- return res.then((result) => {
418
- span.end();
419
- return result;
420
- }).catch((error) => {
421
- span.recordException(error);
422
- span.setStatus({
423
- code: SpanStatusCode.ERROR,
424
- message: error.message
425
- });
426
- span.end();
427
- return Promise.reject(error);
428
- });
316
+ const res = withActiveSpan(span, () => original.apply(this));
317
+ return res.then(
318
+ (result) => {
319
+ span.end();
320
+ return result;
321
+ },
322
+ (error) => {
323
+ endSpan(span, error);
324
+ return Promise.reject(error);
325
+ }
326
+ );
429
327
  };
430
328
  };
431
329
  }
432
330
  _traceClientCommand(origFunction, origThis, origArguments, redisCommandArguments) {
433
- const hasNoParentSpan = trace.getSpan(context.active()) === void 0;
434
- if (hasNoParentSpan && this.getConfig().requireParentSpan) {
435
- return origFunction.apply(origThis, origArguments);
436
- }
437
331
  const clientOptions = origThis.options || origThis[MULTI_COMMAND_OPTIONS];
438
332
  const commandName = redisCommandArguments[0];
439
333
  const commandArgs = redisCommandArguments.slice(1);
440
- const dbStatementSerializer = this.getConfig().dbStatementSerializer || defaultDbStatementSerializer;
441
- const attributes = getClientAttributes(this._diag, clientOptions, this._semconvStability);
442
- if (this._semconvStability & SemconvStability.STABLE) {
443
- attributes[ATTR_DB_OPERATION_NAME] = commandName;
444
- }
445
- try {
446
- const dbStatement = dbStatementSerializer(commandName, commandArgs);
447
- if (dbStatement != null) {
448
- if (this._semconvStability & SemconvStability.OLD) {
449
- attributes[ATTR_DB_STATEMENT] = dbStatement;
450
- }
451
- if (this._semconvStability & SemconvStability.STABLE) {
452
- attributes[ATTR_DB_QUERY_TEXT] = dbStatement;
453
- }
454
- }
455
- } catch (e) {
456
- this._diag.error("dbStatementSerializer throw an exception", e, { commandName });
334
+ const attributes = getClientAttributes(clientOptions);
335
+ const dbStatement = defaultDbStatementSerializer(commandName, commandArgs);
336
+ if (dbStatement != null) {
337
+ attributes[ATTR_DB_STATEMENT] = dbStatement;
457
338
  }
458
- attributes[SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN] = "auto.db.otel.redis";
459
- const span = this.tracer.startSpan(`${_RedisInstrumentationV4_V5.COMPONENT}-${commandName}`, {
339
+ const span = startInactiveSpan({
340
+ name: `${_RedisInstrumentationV4_V5.COMPONENT}-${commandName}`,
460
341
  kind: SpanKind.CLIENT,
461
342
  attributes
462
343
  });
463
- const res = context.with(trace.setSpan(context.active(), span), () => {
464
- return origFunction.apply(origThis, origArguments);
465
- });
466
- if (typeof res?.then === "function") {
344
+ const res = withActiveSpan(span, () => origFunction.apply(origThis, origArguments));
345
+ if (res instanceof Promise) {
467
346
  res.then(
468
347
  (redisRes) => {
469
348
  this._endSpanWithResponse(span, commandName, commandArgs, redisRes, void 0);
@@ -483,64 +362,46 @@ const _RedisInstrumentationV4_V5 = class _RedisInstrumentationV4_V5 extends Inst
483
362
  }
484
363
  return res;
485
364
  }
486
- _endSpansWithRedisReplies(openSpans, replies, isPipeline = false) {
365
+ _endSpansWithRedisReplies(openSpans, replies) {
487
366
  if (!openSpans) {
488
- return this._diag.error("cannot find open spans to end for redis multi/pipeline");
367
+ DEBUG_BUILD && debug.error("cannot find open spans to end for redis multi/pipeline");
368
+ return;
489
369
  }
490
370
  if (replies.length !== openSpans.length) {
491
- return this._diag.error("number of multi command spans does not match response from redis");
371
+ DEBUG_BUILD && debug.error("number of multi command spans does not match response from redis");
372
+ return;
492
373
  }
493
- const allCommands = openSpans.map((s) => s.commandName);
494
- const allSameCommand = allCommands.every((cmd) => cmd === allCommands[0]);
495
- const operationName = allSameCommand ? (isPipeline ? "PIPELINE " : "MULTI ") + allCommands[0] : isPipeline ? "PIPELINE" : "MULTI";
496
374
  for (let i = 0; i < openSpans.length; i++) {
497
- const { span, commandArgs } = openSpans[i];
375
+ const { span, commandName, commandArgs } = openSpans[i];
498
376
  const currCommandRes = replies[i];
499
377
  const [res, err] = currCommandRes instanceof Error ? [null, currCommandRes] : [currCommandRes, void 0];
500
- if (this._semconvStability & SemconvStability.STABLE) {
501
- span.setAttribute(ATTR_DB_OPERATION_NAME, operationName);
502
- }
503
- this._endSpanWithResponse(span, allCommands[i], commandArgs, res, err);
378
+ this._endSpanWithResponse(span, commandName, commandArgs, res, err);
504
379
  }
505
380
  }
506
381
  _endSpanWithResponse(span, commandName, commandArgs, response, error) {
507
- const { responseHook } = this.getConfig();
508
- if (!error && responseHook) {
509
- try {
510
- responseHook(span, commandName, commandArgs, response);
511
- } catch (err) {
512
- this._diag.error("responseHook throw an exception", err);
513
- }
382
+ if (!error) {
383
+ runResponseHook(this.getConfig().responseHook, span, commandName, commandArgs, response);
514
384
  }
515
- if (error) {
516
- span.recordException(error);
517
- span.setStatus({ code: SpanStatusCode.ERROR, message: error?.message });
518
- }
519
- span.end();
385
+ endSpan(span, error);
520
386
  }
521
387
  };
522
388
  _RedisInstrumentationV4_V5.COMPONENT = "redis";
523
389
  let RedisInstrumentationV4_V5 = _RedisInstrumentationV4_V5;
524
- const DEFAULT_CONFIG = {
525
- requireParentSpan: false
526
- };
527
390
  class RedisInstrumentation extends InstrumentationBase {
528
391
  constructor(config = {}) {
529
- const resolvedConfig = { ...DEFAULT_CONFIG, ...config };
530
- super(PACKAGE_NAME, PACKAGE_VERSION, resolvedConfig);
392
+ super(PACKAGE_NAME, SDK_VERSION, config);
531
393
  this.initialized = false;
532
394
  this.instrumentationV2_V3 = new RedisInstrumentationV2_V3(this.getConfig());
533
395
  this.instrumentationV4_V5 = new RedisInstrumentationV4_V5(this.getConfig());
534
396
  this.initialized = true;
535
397
  }
536
398
  setConfig(config = {}) {
537
- const newConfig = { ...DEFAULT_CONFIG, ...config };
538
- super.setConfig(newConfig);
399
+ super.setConfig(config);
539
400
  if (!this.initialized) {
540
401
  return;
541
402
  }
542
- this.instrumentationV2_V3.setConfig(newConfig);
543
- this.instrumentationV4_V5.setConfig(newConfig);
403
+ this.instrumentationV2_V3.setConfig(config);
404
+ this.instrumentationV4_V5.setConfig(config);
544
405
  }
545
406
  init() {
546
407
  }