@athenna/cron 5.6.0 → 5.8.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.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@athenna/cron",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.8.0",
|
|
4
4
|
"description": "Athenna scheduler application. Built on top of node-cron.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "João Lenon <lenon@athenna.io>",
|
|
@@ -57,26 +57,26 @@
|
|
|
57
57
|
"node-cron": "^3.0.3"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
60
|
-
"@athenna/artisan": "^5.
|
|
61
|
-
"@athenna/common": "^5.
|
|
62
|
-
"@athenna/config": "^5.
|
|
63
|
-
"@athenna/ioc": "^5.
|
|
64
|
-
"@athenna/logger": "^5.
|
|
65
|
-
"@athenna/test": "^5.
|
|
60
|
+
"@athenna/artisan": "^5.7.0",
|
|
61
|
+
"@athenna/common": "^5.14.0",
|
|
62
|
+
"@athenna/config": "^5.4.0",
|
|
63
|
+
"@athenna/ioc": "^5.2.0",
|
|
64
|
+
"@athenna/logger": "^5.7.0",
|
|
65
|
+
"@athenna/test": "^5.5.0",
|
|
66
66
|
"@athenna/tsconfig": "^5.0.0",
|
|
67
67
|
"@athenna/view": "^5.3.0",
|
|
68
68
|
"@types/node-cron": "^3.0.11",
|
|
69
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
70
|
-
"@typescript-eslint/parser": "^8.
|
|
69
|
+
"@typescript-eslint/eslint-plugin": "^8.38.0",
|
|
70
|
+
"@typescript-eslint/parser": "^8.38.0",
|
|
71
71
|
"cls-rtracer": "^2.6.3",
|
|
72
72
|
"commitizen": "^4.3.1",
|
|
73
73
|
"cz-conventional-changelog": "^3.3.0",
|
|
74
74
|
"eslint": "^8.57.1",
|
|
75
|
-
"eslint-config-prettier": "^8.10.
|
|
75
|
+
"eslint-config-prettier": "^8.10.2",
|
|
76
76
|
"eslint-config-standard": "^17.1.0",
|
|
77
|
-
"eslint-plugin-import": "^2.
|
|
77
|
+
"eslint-plugin-import": "^2.32.0",
|
|
78
78
|
"eslint-plugin-n": "^15.7.0",
|
|
79
|
-
"eslint-plugin-prettier": "^4.2.
|
|
79
|
+
"eslint-plugin-prettier": "^4.2.5",
|
|
80
80
|
"eslint-plugin-promise": "^6.6.0",
|
|
81
81
|
"husky": "^3.1.0",
|
|
82
82
|
"lint-staged": "^12.5.0",
|
|
@@ -42,21 +42,11 @@ export class CronExceptionHandler {
|
|
|
42
42
|
if (!this.canBeLogged(error)) {
|
|
43
43
|
return;
|
|
44
44
|
}
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
Log.channelOrVanilla('exception').error({
|
|
48
|
-
name: error.name,
|
|
49
|
-
code: error.code,
|
|
50
|
-
status: error.status,
|
|
51
|
-
message: error.message,
|
|
52
|
-
help: error.help,
|
|
53
|
-
cause: error.cause,
|
|
54
|
-
details: error.details,
|
|
55
|
-
stack: error.stack
|
|
56
|
-
});
|
|
45
|
+
if (Config.is('cron.logger.prettifyException', true)) {
|
|
46
|
+
Log.channelOrVanilla('exception').error(await error.prettify());
|
|
57
47
|
return;
|
|
58
48
|
}
|
|
59
|
-
Log.channelOrVanilla('exception').error(
|
|
49
|
+
Log.channelOrVanilla('exception').error(error);
|
|
60
50
|
}
|
|
61
51
|
/**
|
|
62
52
|
* Return a boolean indicating if the error can be logged or not.
|
|
@@ -10,12 +10,8 @@ export class CronKernel {
|
|
|
10
10
|
/**
|
|
11
11
|
* Register the cls-rtracer plugin in the Cron.
|
|
12
12
|
*/
|
|
13
|
-
async registerRTracer(
|
|
14
|
-
if (
|
|
15
|
-
debug('Not able to register rTracer plugin. Set the trace option as true in your cron options.');
|
|
16
|
-
return;
|
|
17
|
-
}
|
|
18
|
-
if (trace === undefined && Config.is('cron.rTracer.enabled', false)) {
|
|
13
|
+
async registerRTracer() {
|
|
14
|
+
if (Config.is('cron.rTracer.enabled', false)) {
|
|
19
15
|
debug('Not able to register rTracer plugin. Set the cron.rTracer.enabled configuration as true.');
|
|
20
16
|
return;
|
|
21
17
|
}
|