@rudderjs/pulse 6.3.1 → 6.3.2
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exception.d.ts","sourceRoot":"","sources":["../../src/recorders/exception.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAEzD;;GAEG;AACH,qBAAa,iBAAkB,YAAW,QAAQ;IAGpC,OAAO,CAAC,QAAQ,CAAC,OAAO;IAFpC,QAAQ,CAAC,IAAI,wBAAuB;gBAEP,OAAO,EAAE,YAAY;IAE5C,QAAQ,IAAI,OAAO,CAAC,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"exception.d.ts","sourceRoot":"","sources":["../../src/recorders/exception.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAEzD;;GAEG;AACH,qBAAa,iBAAkB,YAAW,QAAQ;IAGpC,OAAO,CAAC,QAAQ,CAAC,OAAO;IAFpC,QAAQ,CAAC,IAAI,wBAAuB;gBAEP,OAAO,EAAE,YAAY;IAE5C,QAAQ,IAAI,OAAO,CAAC,IAAI,CAAC;CA4BhC"}
|
|
@@ -9,16 +9,23 @@ export class ExceptionRecorder {
|
|
|
9
9
|
}
|
|
10
10
|
async register() {
|
|
11
11
|
try {
|
|
12
|
-
const { setExceptionReporter
|
|
12
|
+
const { setExceptionReporter } = await import('@rudderjs/core');
|
|
13
13
|
const storage = this.storage;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
14
|
+
// Capture the reporter installed *before* us and chain to it. Capturing
|
|
15
|
+
// `report` instead would call whatever the current reporter is — i.e.
|
|
16
|
+
// this very wrapper — and recurse until the stack overflows.
|
|
17
|
+
const previousReport = setExceptionReporter((err) => {
|
|
18
|
+
try {
|
|
19
|
+
storage.record('exceptions', 1);
|
|
20
|
+
const isError = err instanceof Error;
|
|
21
|
+
storage.storeEntry('exception', {
|
|
22
|
+
class: isError ? err.constructor.name : 'Unknown',
|
|
23
|
+
message: isError ? err.message : String(err),
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
catch {
|
|
27
|
+
// Recording must never break the reporter chain.
|
|
28
|
+
}
|
|
22
29
|
previousReport(err);
|
|
23
30
|
});
|
|
24
31
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exception.js","sourceRoot":"","sources":["../../src/recorders/exception.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,OAAO,iBAAiB;IAGC;IAFpB,IAAI,GAAG,oBAAoB,CAAA;IAEpC,YAA6B,OAAqB;QAArB,YAAO,GAAP,OAAO,CAAc;IAAG,CAAC;IAEtD,KAAK,CAAC,QAAQ;QACZ,IAAI,CAAC;YACH,MAAM,EAAE,oBAAoB,EAAE,
|
|
1
|
+
{"version":3,"file":"exception.js","sourceRoot":"","sources":["../../src/recorders/exception.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,OAAO,iBAAiB;IAGC;IAFpB,IAAI,GAAG,oBAAoB,CAAA;IAEpC,YAA6B,OAAqB;QAArB,YAAO,GAAP,OAAO,CAAc;IAAG,CAAC;IAEtD,KAAK,CAAC,QAAQ;QACZ,IAAI,CAAC;YACH,MAAM,EAAE,oBAAoB,EAAE,GAAG,MAAM,MAAM,CAAC,gBAAgB,CAE7D,CAAA;YAED,MAAM,OAAO,GAAG,IAAI,CAAC,OAAO,CAAA;YAE5B,wEAAwE;YACxE,sEAAsE;YACtE,6DAA6D;YAC7D,MAAM,cAAc,GAAG,oBAAoB,CAAC,CAAC,GAAY,EAAE,EAAE;gBAC3D,IAAI,CAAC;oBACH,OAAO,CAAC,MAAM,CAAC,YAAY,EAAE,CAAC,CAAC,CAAA;oBAC/B,MAAM,OAAO,GAAG,GAAG,YAAY,KAAK,CAAA;oBACpC,OAAO,CAAC,UAAU,CAAC,WAAW,EAAE;wBAC9B,KAAK,EAAI,OAAO,CAAC,CAAC,CAAC,GAAG,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS;wBACnD,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC;qBAC7C,CAAC,CAAA;gBACJ,CAAC;gBAAC,MAAM,CAAC;oBACP,iDAAiD;gBACnD,CAAC;gBACD,cAAc,CAAC,GAAG,CAAC,CAAA;YACrB,CAAC,CAAC,CAAA;QACJ,CAAC;QAAC,MAAM,CAAC;YACP,kBAAkB;QACpB,CAAC;IACH,CAAC;CACF"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rudderjs/pulse",
|
|
3
|
-
"version": "6.3.
|
|
3
|
+
"version": "6.3.2",
|
|
4
4
|
"rudderjs": {
|
|
5
5
|
"provider": "PulseProvider",
|
|
6
6
|
"stage": "monitoring"
|
|
@@ -33,16 +33,16 @@
|
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@rudderjs/console": "^1.4.0",
|
|
36
|
-
"@rudderjs/core": "^1.
|
|
37
|
-
"@rudderjs/contracts": "^1.
|
|
36
|
+
"@rudderjs/core": "^1.13.0",
|
|
37
|
+
"@rudderjs/contracts": "^1.17.1"
|
|
38
38
|
},
|
|
39
39
|
"peerDependencies": {
|
|
40
|
-
"@rudderjs/router": "^1.
|
|
41
|
-
"@rudderjs/middleware": "^1.2.
|
|
40
|
+
"@rudderjs/router": "^1.9.1",
|
|
41
|
+
"@rudderjs/middleware": "^1.2.2",
|
|
42
42
|
"@rudderjs/log": "^1.1.0",
|
|
43
|
-
"@rudderjs/orm": "^1.
|
|
44
|
-
"@rudderjs/cache": "^1.
|
|
45
|
-
"@rudderjs/queue": "^4.4.
|
|
43
|
+
"@rudderjs/orm": "^1.21.2",
|
|
44
|
+
"@rudderjs/cache": "^1.5.0",
|
|
45
|
+
"@rudderjs/queue": "^4.4.2"
|
|
46
46
|
},
|
|
47
47
|
"peerDependenciesMeta": {
|
|
48
48
|
"@rudderjs/log": {
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"@types/node": "^20.0.0",
|
|
66
66
|
"@types/better-sqlite3": "^7.6.0",
|
|
67
67
|
"typescript": "^5.4.0",
|
|
68
|
-
"@rudderjs/queue": "^4.4.
|
|
68
|
+
"@rudderjs/queue": "^4.4.2"
|
|
69
69
|
},
|
|
70
70
|
"author": "Suleiman Shahbari",
|
|
71
71
|
"scripts": {
|