From 7f39aaa3d8633e9f05d2570c756e5e1fcac9b017 Mon Sep 17 00:00:00 2001 From: Thomas Lenz Date: Mon, 20 Dec 2021 08:16:01 +0100 Subject: switch from log4j to logback --- .../deploy/conf/moa-id-configuration/logback.xml | 40 ++++++++ .../conf/moa-id-configuration/logback_config.xml | 71 -------------- id/server/data/deploy/conf/moa-id-oa/logback.xml | 30 ++++++ id/server/data/deploy/conf/moa-id/log4j.properties | 62 ------------ id/server/data/deploy/conf/moa-id/logback.xml | 79 ++++++++++++++++ .../data/deploy/conf/moa-id/logback_config.xml | 105 --------------------- id/server/data/deploy/tomcat/unix/tomcat-start.sh | 3 +- id/server/data/deploy/tomcat/win32/startTomcat.bat | 3 +- 8 files changed, 151 insertions(+), 242 deletions(-) create mode 100644 id/server/data/deploy/conf/moa-id-configuration/logback.xml delete mode 100644 id/server/data/deploy/conf/moa-id-configuration/logback_config.xml create mode 100644 id/server/data/deploy/conf/moa-id-oa/logback.xml delete mode 100644 id/server/data/deploy/conf/moa-id/log4j.properties create mode 100644 id/server/data/deploy/conf/moa-id/logback.xml delete mode 100644 id/server/data/deploy/conf/moa-id/logback_config.xml (limited to 'id/server/data') diff --git a/id/server/data/deploy/conf/moa-id-configuration/logback.xml b/id/server/data/deploy/conf/moa-id-configuration/logback.xml new file mode 100644 index 000000000..fc7508598 --- /dev/null +++ b/id/server/data/deploy/conf/moa-id-configuration/logback.xml @@ -0,0 +1,40 @@ + + + + + ${catalina.base}/logs/moa-id-webgui.log + + %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n + + + 1 + ${catalina.base}/logs/moa-id-webgui.log.%i.gz + + + 10000KB + + + + + %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} |%20.20c | %10t | %m%n + + + + + + + + + + + + + + + + + + + + + diff --git a/id/server/data/deploy/conf/moa-id-configuration/logback_config.xml b/id/server/data/deploy/conf/moa-id-configuration/logback_config.xml deleted file mode 100644 index c00e62e52..000000000 --- a/id/server/data/deploy/conf/moa-id-configuration/logback_config.xml +++ /dev/null @@ -1,71 +0,0 @@ - - - - - - - - - - - - - - - - ${catalina.base}/logs/moa-id.log - - %5p | %d{dd HH:mm:ss,SSS} | %X{transactionId} | %t | %m%n - - - 1 - ${catalina.base}/logs/moa-id.log.%i - - - 10000KB - - - - - - - - ${catalina.base}/logs/moa-id-webgui.log - - %5p | %d{dd HH:mm:ss,SSS} | %X{transactionId} | %t | %m%n - - - 1 - ${catalina.base}/logs/moa-id-webgui.log.%i - - - 10000KB - - - - - %5p | %d{dd HH:mm:ss,SSS} | %X{transactionId} |%20.20c | %10t | %m%n - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/id/server/data/deploy/conf/moa-id-oa/logback.xml b/id/server/data/deploy/conf/moa-id-oa/logback.xml new file mode 100644 index 000000000..b94b7476a --- /dev/null +++ b/id/server/data/deploy/conf/moa-id-oa/logback.xml @@ -0,0 +1,30 @@ + + + + + ${catalina.base}/logs/moa-demo-sp.log + + %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n + + + 1 + ${catalina.base}/logs/moa-demo-sp.%i.gz + + + 10000KB + + + + + %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} |%20.20c | %10t | %m%n + + + + + + + + + + + diff --git a/id/server/data/deploy/conf/moa-id/log4j.properties b/id/server/data/deploy/conf/moa-id/log4j.properties deleted file mode 100644 index 2914fcff1..000000000 --- a/id/server/data/deploy/conf/moa-id/log4j.properties +++ /dev/null @@ -1,62 +0,0 @@ -# commons-logging setup -org.apache.commons.logging.LogFactory=org.apache.commons.logging.impl.Log4jFactory - -# define log4j root loggers -log4j.rootLogger=warn,stdout - -### MOA-ID process log ### -log4j.logger.at.gv.egiz.eaaf=info,moaid -log4j.logger.at.gv.egovernment.moa.id=info,moaid -log4j.logger.at.gv.egovernment.moa.spss=info,moaid - -### process revision log with event-codes ### -log4j.logger.at.gv.egiz.eventlog.plain.all=info,reversion - -### Signature verification and certificate proofing #### -log4j.logger.at.gv.egovernment.moa.spss=info,moaspss -log4j.logger.iaik.server=info,moaspss -log4j.logger.pki=info,moaspss - -### ConfigTool Logs #### -log4j.logger.at.gv.egiz.components.configuration=info,CONFIGTOOL -log4j.logger.at.gv.egovernment.moa.id.commons=info,CONFIGTOOL -log4j.logger.at.gv.egovernment.moa.id.config.webgui=info,CONFIGTOOL -log4j.logger.at.gv.egovernment.moa.id.configuration=info,CONFIGTOOL - - -### Log Appender #### -# configure the stdout appender -log4j.appender.stdout=org.apache.log4j.ConsoleAppender -log4j.appender.stdout.layout=org.apache.log4j.PatternLayout -log4j.appender.stdout.layout.ConversionPattern=%5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} |%20.20c | %10t | %m%n - -# configure the rolling file appender (moaid) -log4j.appender.moaid=org.apache.log4j.RollingFileAppender -log4j.appender.moaid.File=${catalina.base}/logs/moa-id.log -log4j.appender.moaid.MaxFileSize=10000KB -log4j.appender.moaid.MaxBackupIndex=1 -log4j.appender.moaid.layout=org.apache.log4j.PatternLayout -log4j.appender.moaid.layout.ConversionPattern=%5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n - -# configure the rolling file appender (moaid) -log4j.appender.moaspss=org.apache.log4j.RollingFileAppender -log4j.appender.moaspss.File=${catalina.base}/logs/moa-spss.log -log4j.appender.moaspss.MaxFileSize=10000KB -log4j.appender.moaspss.MaxBackupIndex=1 -log4j.appender.moaspss.layout=org.apache.log4j.PatternLayout -log4j.appender.moaspss.layout.ConversionPattern=%5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n - -log4j.appender.reversion=org.apache.log4j.RollingFileAppender -log4j.appender.reversion.File=${catalina.base}/moa-id-reversion.log -log4j.appender.reversion.MaxFileSize=10000KB -log4j.appender.reversion.MaxBackupIndex=9999 -log4j.appender.reversion.layout=org.apache.log4j.PatternLayout -log4j.appender.reversion.layout.ConversionPattern=%5p | %d{ISO8601} | %t | %m%n - -# configure the rolling file appender (configtool) -log4j.appender.CONFIGTOOL=org.apache.log4j.RollingFileAppender -log4j.appender.CONFIGTOOL.File=${catalina.base}/logs/moa-id-webgui.log -log4j.appender.CONFIGTOOL.MaxFileSize=10000KB -log4j.appender.CONFIGTOOL.MaxBackupIndex=1 -log4j.appender.CONFIGTOOL.layout=org.apache.log4j.PatternLayout -log4j.appender.CONFIGTOOL.layout.ConversionPattern=%5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n \ No newline at end of file diff --git a/id/server/data/deploy/conf/moa-id/logback.xml b/id/server/data/deploy/conf/moa-id/logback.xml new file mode 100644 index 000000000..3f0d54fe5 --- /dev/null +++ b/id/server/data/deploy/conf/moa-id/logback.xml @@ -0,0 +1,79 @@ + + + + + ${catalina.base}/logs/moa-id.log + + %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n + + + 1 + ${catalina.base}/logs/moa-id.log.%i.gz + + + 10000KB + + + + + ${catalina.base}/logs/moa-spss.log + + %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n + + + 1 + ${catalina.base}/logs/moa-spss.log.%i.gz + + + 10000KB + + + + + ${catalina.base}/moa-id-reversion.log + + %5p | %d{ISO8601} | %t | %m%n + + + 9999 + ${catalina.base}/moa-id-reversion.log.%i.gz + + + 10000KB + + + + + %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} |%20.20c | %10t | %m%n + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/id/server/data/deploy/conf/moa-id/logback_config.xml b/id/server/data/deploy/conf/moa-id/logback_config.xml deleted file mode 100644 index fa221fbc2..000000000 --- a/id/server/data/deploy/conf/moa-id/logback_config.xml +++ /dev/null @@ -1,105 +0,0 @@ - - - - - - - - - - - - - ${catalina.base}/logs/moa-id.log - - %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n - - - 1 - ${catalina.base}/logs/moa-id.log.%i - - - 10000KB - - - - - ${catalina.base}/logs/moa-spss.log - - %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n - - - 1 - ${catalina.base}/logs/moa-spss.log.%i - - - 10000KB - - - - - ${catalina.base}/logs/moa-id-webgui.log - - %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} | %t | %m%n - - - 1 - ${catalina.base}/logs/moa-id-webgui.log.%i - - - 10000KB - - - - - ${catalina.base}/moa-id-reversion.log - - %5p | %d{ISO8601} | %t | %m%n - - - 9999 - ${catalina.base}/moa-id-reversion.log.%i - - - 10000KB - - - - - %5p | %d{dd HH:mm:ss,SSS} | %X{sessionId} | %X{transactionId} | %X{oaId} |%20.20c | %10t | %m%n - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/id/server/data/deploy/tomcat/unix/tomcat-start.sh b/id/server/data/deploy/tomcat/unix/tomcat-start.sh index d717ecd25..0ad50ff0e 100644 --- a/id/server/data/deploy/tomcat/unix/tomcat-start.sh +++ b/id/server/data/deploy/tomcat/unix/tomcat-start.sh @@ -7,8 +7,7 @@ export CATALINA_BASE=$CATALINA_HOME FILE_ENCODING=-Dfile.encoding=UTF-8 RAND_FILE=-Djava.security.egd=file:///dev/urandom -LOGGING_OPT=-Dlog4j.configuration=file:$CATALINA_BASE/conf/moa-id/log4j.properties -LOGGING_LOGBACK_OPT=-Dlogback.configurationFile=$CATALINA_BASE/conf/moa-id/logback_config.xml +LOGGING_LOGBACK_OPT=-Dlogback.configurationFile=$CATALINA_BASE/conf/moa-id/logback.xml CONFIG_OPT=-Dmoa.id.configuration=file:$CATALINA_BASE/conf/moa-id/moa-id.properties SPSS_OPT=-Dmoa.spss.server.configuration=$CATALINA_BASE/conf/moa-spss/SampleMOASPSSConfiguration.xml diff --git a/id/server/data/deploy/tomcat/win32/startTomcat.bat b/id/server/data/deploy/tomcat/win32/startTomcat.bat index afdd907c8..93eb3ea80 100644 --- a/id/server/data/deploy/tomcat/win32/startTomcat.bat +++ b/id/server/data/deploy/tomcat/win32/startTomcat.bat @@ -12,8 +12,7 @@ rem ---------------------------------------------------------------------------- set FILE_ENCODING=-Dfile.encoding=UTF-8 set RAND_FILE=-Djava.security.egd=file:///dev/urandom -set LOGGING_OPT=-Dlog4j.configuration=file:%CATALINA_HOME%/conf/moa-id/log4j.properties -set LOGGING_LOGBACK_OPT=-Dlogback.configurationFile=%CATALINA_HOME%/conf/moa-id/logback_config.xml +set LOGGING_LOGBACK_OPT=-Dlogback.configurationFile=%CATALINA_HOME%/conf/moa-id/logback.xml set CONFIG_OPT_SPSS=-Dmoa.spss.server.configuration=%CATALINA_HOME%/conf/moa-spss/SampleMOASPSSConfiguration.xml set CONFIG_OPT_ID=-Dmoa.id.configuration=file:%CATALINA_HOME%/conf/moa-id/moa-id.properties -- cgit v1.2.3