autotel 2.25.0 → 2.25.1
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.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "autotel",
|
|
3
|
-
"version": "2.25.
|
|
3
|
+
"version": "2.25.1",
|
|
4
4
|
"description": "Write Once, Observe Anywhere",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -139,11 +139,13 @@
|
|
|
139
139
|
},
|
|
140
140
|
"./register": {
|
|
141
141
|
"types": "./dist/register.d.ts",
|
|
142
|
-
"import": "./dist/register.js"
|
|
142
|
+
"import": "./dist/register.js",
|
|
143
|
+
"require": "./dist/register.cjs"
|
|
143
144
|
},
|
|
144
145
|
"./auto": {
|
|
145
146
|
"types": "./dist/auto.d.ts",
|
|
146
|
-
"import": "./dist/auto.js"
|
|
147
|
+
"import": "./dist/auto.js",
|
|
148
|
+
"require": "./dist/auto.cjs"
|
|
147
149
|
},
|
|
148
150
|
"./hook.mjs": {
|
|
149
151
|
"import": "./src/hook.mjs"
|
|
@@ -274,7 +276,7 @@
|
|
|
274
276
|
"@traceloop/node-server-sdk": "^0.22.8",
|
|
275
277
|
"pino": "^10.3.1",
|
|
276
278
|
"pino-pretty": "^13.1.3",
|
|
277
|
-
"yaml": "^2.8.
|
|
279
|
+
"yaml": "^2.8.3"
|
|
278
280
|
},
|
|
279
281
|
"peerDependenciesMeta": {
|
|
280
282
|
"@opentelemetry/auto-instrumentations-node": {
|
|
@@ -334,7 +336,7 @@
|
|
|
334
336
|
"@opentelemetry/resource-detector-gcp": "^0.48.0",
|
|
335
337
|
"@opentelemetry/sdk-logs": "^0.213.0",
|
|
336
338
|
"@opentelemetry/sdk-trace-node": "^2.6.0",
|
|
337
|
-
"@swc/core": "^1.15.
|
|
339
|
+
"@swc/core": "^1.15.21",
|
|
338
340
|
"@total-typescript/ts-reset": "^0.6.1",
|
|
339
341
|
"@total-typescript/tsconfig": "^1.0.4",
|
|
340
342
|
"@types/eslint-config-prettier": "^6.11.3",
|
|
@@ -355,7 +357,7 @@
|
|
|
355
357
|
"vitest": "^4.1.0",
|
|
356
358
|
"vitest-mock-extended": "^3.1.0",
|
|
357
359
|
"winston": "^3.19.0",
|
|
358
|
-
"yaml": "^2.8.
|
|
360
|
+
"yaml": "^2.8.3"
|
|
359
361
|
},
|
|
360
362
|
"repository": {
|
|
361
363
|
"type": "git",
|
|
@@ -20,18 +20,24 @@ const mockedModules = [
|
|
|
20
20
|
'@opentelemetry/sdk-metrics',
|
|
21
21
|
];
|
|
22
22
|
|
|
23
|
-
// Mock instrumentation classes with exact names from OpenTelemetry
|
|
24
|
-
|
|
23
|
+
// Mock instrumentation classes with exact names from OpenTelemetry.
|
|
24
|
+
// NodeSDK.start() calls lifecycle hooks on each instrumentation instance.
|
|
25
|
+
class MockInstrumentationBase {
|
|
25
26
|
constructor(public config?: Record<string, unknown>) {}
|
|
26
|
-
}
|
|
27
27
|
|
|
28
|
-
|
|
29
|
-
|
|
28
|
+
setConfig(_config: Record<string, unknown>) {}
|
|
29
|
+
setTracerProvider(_provider: unknown) {}
|
|
30
|
+
setMeterProvider(_provider: unknown) {}
|
|
31
|
+
setLoggerProvider(_provider: unknown) {}
|
|
32
|
+
enable() {}
|
|
33
|
+
disable() {}
|
|
30
34
|
}
|
|
31
35
|
|
|
32
|
-
class
|
|
33
|
-
|
|
34
|
-
}
|
|
36
|
+
class MongoDBInstrumentation extends MockInstrumentationBase {}
|
|
37
|
+
|
|
38
|
+
class MongooseInstrumentation extends MockInstrumentationBase {}
|
|
39
|
+
|
|
40
|
+
class HttpInstrumentation extends MockInstrumentationBase {}
|
|
35
41
|
|
|
36
42
|
async function loadInitWithMocks() {
|
|
37
43
|
const sdkInstances: SdkRecord[] = [];
|