diff options
author | 2018-02-21 10:40:47 -0500 | |
---|---|---|
committer | 2018-02-21 14:43:54 -0500 | |
commit | 457910274afc5f0b66705c0b38380219fb178f3a (patch) | |
tree | 93fedc14903a8afe894a9141767abbfcf7820b48 /ONAP-SDK-APP/src/main/resources/logback.xml | |
parent | 90d00371ecff702432203f7df882e0a8144ea43f (diff) |
Updated the Policy Logging Pattern
Updated the logback.xml to save logs for 30 days.
Issue-ID: POLICY-644
Change-Id: I578570fa5a7f86ba464c37cddab43a2fabcdae7f
Signed-off-by: rb7147 <rb7147@att.com>
Diffstat (limited to 'ONAP-SDK-APP/src/main/resources/logback.xml')
-rw-r--r-- | ONAP-SDK-APP/src/main/resources/logback.xml | 168 |
1 files changed, 26 insertions, 142 deletions
diff --git a/ONAP-SDK-APP/src/main/resources/logback.xml b/ONAP-SDK-APP/src/main/resources/logback.xml index 42535510b..d19b1ba5a 100644 --- a/ONAP-SDK-APP/src/main/resources/logback.xml +++ b/ONAP-SDK-APP/src/main/resources/logback.xml @@ -3,7 +3,7 @@ ================================================================================ ONAP Portal SDK ================================================================================ - Copyright (C) 2017 AT&T Intellectual Property + Copyright (C) 2017-2018 AT&T Intellectual Property ================================================================================ Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -87,13 +87,14 @@ <appender name="EELF" class="ch.qos.logback.core.rolling.RollingFileAppender"> <file>${logDirectory}/${generalLogName}.log</file> - <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> + <rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy"> <!-- daily rollover --> - <fileNamePattern>${logDirectory}/${generalLogName}.%d{yyyy-MM-dd}.log.zip</fileNamePattern> + <fileNamePattern>${logDirectory}/${generalLogName}.%d{yyyy-MM-dd}.%i.log.zip</fileNamePattern> <!-- keep 30 days' worth of history capped at 3GB total size --> - <maxHistory>30</maxHistory> - <totalSizeCap>3GB</totalSizeCap> + <maxFileSize>50MB</maxFileSize> + <maxHistory>30</maxHistory> + <totalSizeCap>10GB</totalSizeCap> </rollingPolicy> <encoder> @@ -108,127 +109,6 @@ <includeCallerData>true</includeCallerData> <appender-ref ref="EELF" /> </appender> - - <!-- EELF Security Appender. This appender is used to record security events - to the security log file. Security events are separate from other loggers - in EELF so that security log records can be captured and managed in a secure - way separate from the other logs. This appender is set to never discard any - events. --> - <!-- - <appender name="EELFSecurity" - class="ch.qos.logback.core.rolling.RollingFileAppender"> - <file>${logDirectory}/${securityLogName}.log</file> - <rollingPolicy - class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> - <fileNamePattern>${logDirectory}/${securityLogName}.%i.log.zip - </fileNamePattern> - <minIndex>1</minIndex> - <maxIndex>9</maxIndex> - </rollingPolicy> - <triggeringPolicy - class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy"> - <maxFileSize>5MB</maxFileSize> - </triggeringPolicy> - <encoder> - <pattern>${defaultPattern}</pattern> - </encoder> - </appender> - - <appender name="asyncEELFSecurity" class="ch.qos.logback.classic.AsyncAppender"> - <queueSize>256</queueSize> - <discardingThreshold>0</discardingThreshold> - <appender-ref ref="EELFSecurity" /> - </appender> - --> - - <!-- EELF Performance Appender. This appender is used to record performance - records. --> - <!-- - <appender name="EELFPerformance" - class="ch.qos.logback.core.rolling.RollingFileAppender"> - <file>${logDirectory}/${performanceLogName}.log</file> - <rollingPolicy - class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> - <fileNamePattern>${logDirectory}/${performanceLogName}.%i.log.zip - </fileNamePattern> - <minIndex>1</minIndex> - <maxIndex>9</maxIndex> - </rollingPolicy> - <triggeringPolicy - class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy"> - <maxFileSize>5MB</maxFileSize> - </triggeringPolicy> - <encoder> - <outputPatternAsHeader>true</outputPatternAsHeader> - <pattern>${defaultPattern}</pattern> - </encoder> - </appender> - <appender name="asyncEELFPerformance" class="ch.qos.logback.classic.AsyncAppender"> - <queueSize>256</queueSize> - <appender-ref ref="EELFPerformance" /> - </appender> - --> - - <!-- EELF Server Appender. This appender is used to record Server related - logging events. The Server logger and appender are specializations of the - EELF application root logger and appender. This can be used to segregate Server - events from other components, or it can be eliminated to record these events - as part of the application root log. --> - <!-- - <appender name="EELFServer" - class="ch.qos.logback.core.rolling.RollingFileAppender"> - <file>${logDirectory}/${serverLogName}.log</file> - <rollingPolicy - class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> - <fileNamePattern>${logDirectory}/${serverLogName}.%i.log.zip - </fileNamePattern> - <minIndex>1</minIndex> - <maxIndex>9</maxIndex> - </rollingPolicy> - <triggeringPolicy - class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy"> - <maxFileSize>5MB</maxFileSize> - </triggeringPolicy> - <encoder> - <pattern>${defaultPattern}</pattern> - </encoder> - </appender> - <appender name="asyncEELFServer" class="ch.qos.logback.classic.AsyncAppender"> - <queueSize>256</queueSize> - <appender-ref ref="EELFServer" /> - </appender> - --> - - <!-- EELF Policy Appender. This appender is used to record Policy engine - related logging events. The Policy logger and appender are specializations - of the EELF application root logger and appender. This can be used to segregate - Policy engine events from other components, or it can be eliminated to record - these events as part of the application root log. --> - <!-- - <appender name="EELFPolicy" - class="ch.qos.logback.core.rolling.RollingFileAppender"> - <file>${logDirectory}/${policyLogName}.log</file> - <rollingPolicy - class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> - <fileNamePattern>${logDirectory}/${policyLogName}.%i.log.zip - </fileNamePattern> - <minIndex>1</minIndex> - <maxIndex>9</maxIndex> - </rollingPolicy> - <triggeringPolicy - class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy"> - <maxFileSize>5MB</maxFileSize> - </triggeringPolicy> - <encoder> - <pattern>${defaultPattern}</pattern> - </encoder> - </appender> - <appender name="asyncEELFPolicy" class="ch.qos.logback.classic.AsyncAppender"> - <queueSize>256</queueSize> - <appender-ref ref="EELFPolicy" /> - </appender> - --> - <!-- EELF Audit Appender. This appender is used to record audit engine related logging events. The audit logger and appender are specializations of the EELF application root logger and appender. This can be used to segregate @@ -238,13 +118,14 @@ <appender name="EELFAudit" class="ch.qos.logback.core.rolling.RollingFileAppender"> <file>${logDirectory}/${auditLogName}.log</file> - <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> + <rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy"> <!-- daily rollover --> - <fileNamePattern>${logDirectory}/${auditLogName}.%d{yyyy-MM-dd}.log.zip</fileNamePattern> + <fileNamePattern>${logDirectory}/${auditLogName}.%d{yyyy-MM-dd}.%i.log.zip</fileNamePattern> <!-- keep 30 days' worth of history capped at 3GB total size --> - <maxHistory>30</maxHistory> - <totalSizeCap>3GB</totalSizeCap> + <maxFileSize>50MB</maxFileSize> + <maxHistory>30</maxHistory> + <totalSizeCap>10GB</totalSizeCap> </rollingPolicy> <encoder> @@ -259,13 +140,14 @@ <appender name="EELFMetrics" class="ch.qos.logback.core.rolling.RollingFileAppender"> <file>${logDirectory}/${metricsLogName}.log</file> - <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> + <rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy"> <!-- daily rollover --> - <fileNamePattern>${logDirectory}/${metricsLogName}.%d{yyyy-MM-dd}.log.zip</fileNamePattern> + <fileNamePattern>${logDirectory}/${metricsLogName}.%d{yyyy-MM-dd}.%i.log.zip</fileNamePattern> <!-- keep 30 days' worth of history capped at 3GB total size --> - <maxHistory>30</maxHistory> - <totalSizeCap>3GB</totalSizeCap> + <maxFileSize>50MB</maxFileSize> + <maxHistory>30</maxHistory> + <totalSizeCap>10GB</totalSizeCap> </rollingPolicy> <encoder> @@ -282,13 +164,14 @@ <appender name="EELFError" class="ch.qos.logback.core.rolling.RollingFileAppender"> <file>${logDirectory}/${errorLogName}.log</file> - <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> + <rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy"> <!-- daily rollover --> - <fileNamePattern>${logDirectory}/${errorLogName}.%d{yyyy-MM-dd}.log.zip</fileNamePattern> + <fileNamePattern>${logDirectory}/${errorLogName}.%d{yyyy-MM-dd}.%i.log.zip</fileNamePattern> <!-- keep 30 days' worth of history capped at 3GB total size --> - <maxHistory>30</maxHistory> - <totalSizeCap>3GB</totalSizeCap> + <maxFileSize>50MB</maxFileSize> + <maxHistory>30</maxHistory> + <totalSizeCap>10GB</totalSizeCap> </rollingPolicy> <encoder> @@ -304,13 +187,14 @@ <appender name="EELFDebug" class="ch.qos.logback.core.rolling.RollingFileAppender"> <file>${debugLogDirectory}/${debugLogName}.log</file> - <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> + <rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy"> <!-- daily rollover --> - <fileNamePattern>${logDirectory}/${debugLogName}.%d{yyyy-MM-dd}.log.zip</fileNamePattern> + <fileNamePattern>${logDirectory}/${debugLogName}.%d{yyyy-MM-dd}.%i.log.zip</fileNamePattern> <!-- keep 30 days' worth of history capped at 3GB total size --> - <maxHistory>30</maxHistory> - <totalSizeCap>3GB</totalSizeCap> + <maxFileSize>50MB</maxFileSize> + <maxHistory>30</maxHistory> + <totalSizeCap>10GB</totalSizeCap> </rollingPolicy> <encoder> |