@forklaunch/core 0.9.2 → 0.9.3
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/lib/src/http/index.js +19 -0
- package/lib/src/http/index.js.map +1 -1
- package/lib/src/http/index.mjs +19 -0
- package/lib/src/http/index.mjs.map +1 -1
- package/lib/src/mappers/index.d.mts +1 -1
- package/lib/src/mappers/index.d.ts +1 -1
- package/lib/src/mappers/index.js +2 -2
- package/lib/src/mappers/index.js.map +1 -1
- package/lib/src/mappers/index.mjs +2 -2
- package/lib/src/mappers/index.mjs.map +1 -1
- package/package.json +8 -14
- package/lib/src/persistence/index.d.mts +0 -120
- package/lib/src/persistence/index.d.ts +0 -120
- package/lib/src/persistence/index.js +0 -169
- package/lib/src/persistence/index.js.map +0 -1
- package/lib/src/persistence/index.mjs +0 -144
- package/lib/src/persistence/index.mjs.map +0 -1
package/lib/src/http/index.js
CHANGED
@@ -1383,6 +1383,25 @@ var ForklaunchExpressLikeApplication = class extends ForklaunchExpressLikeRouter
|
|
1383
1383
|
this.postEnrichMiddleware = postEnrichMiddleware;
|
1384
1384
|
this.openTelemetryCollector = openTelemetryCollector;
|
1385
1385
|
this.appOptions = appOptions;
|
1386
|
+
process.on("uncaughtException", (err) => {
|
1387
|
+
this.openTelemetryCollector.log("error", "Uncaught exception", {
|
1388
|
+
err
|
1389
|
+
});
|
1390
|
+
process.exit(1);
|
1391
|
+
});
|
1392
|
+
process.on("unhandledRejection", (reason) => {
|
1393
|
+
this.openTelemetryCollector.log("error", "Unhandled rejection", {
|
1394
|
+
reason
|
1395
|
+
});
|
1396
|
+
process.exit(1);
|
1397
|
+
});
|
1398
|
+
process.on("exit", () => {
|
1399
|
+
this.openTelemetryCollector.log("info", "Shutting down application");
|
1400
|
+
});
|
1401
|
+
process.on("SIGINT", () => {
|
1402
|
+
this.openTelemetryCollector.log("info", "Shutting down application");
|
1403
|
+
process.exit(0);
|
1404
|
+
});
|
1386
1405
|
this.internal.use(createContext(this.schemaValidator));
|
1387
1406
|
this.internal.use(cors(this.appOptions?.cors ?? {}));
|
1388
1407
|
}
|