数数:log4js配置

This commit is contained in:
luying
2022-05-24 09:30:05 +08:00
parent 8486d3fee8
commit 6559fc8bfb
2 changed files with 16 additions and 4 deletions

View File

@@ -1,8 +1,7 @@
module.exports = {
'appenders': {
'console': {
'type': 'console',
'prefix': '${opts:serverId}'
'type': 'console'
},
'con-log': {
'type': 'file',

View File

@@ -102,6 +102,17 @@ module.exports = {
'type': 'basic'
},
'backups': 5
},
'ta': {
'type': 'file',
'filename': '/zyz_logs/ta/log',
'pattern': 'yyyy-MM-dd-hh',
'alwaysIncludePattern': true,
'layout': {
'type': 'pattern',
'pattern': '%m',
},
}
},
@@ -153,11 +164,13 @@ module.exports = {
'err': {
'appenders': ['console', 'error'],
'level': 'debug'
},
'ta': {
'appenders': ['console', 'ta'],
'level': 'info'
}
},
'prefix': '${opts:serverId} ',
'replaceConsole': true,
'lineDebug': false,
'errorStack': true