summaryrefslogtreecommitdiffstats
path: root/ecomp-portal-widget-ms/widget-ms/src/main/resources/logback.xml
diff options
context:
space:
mode:
Diffstat (limited to 'ecomp-portal-widget-ms/widget-ms/src/main/resources/logback.xml')
-rw-r--r--ecomp-portal-widget-ms/widget-ms/src/main/resources/logback.xml138
1 files changed, 138 insertions, 0 deletions
diff --git a/ecomp-portal-widget-ms/widget-ms/src/main/resources/logback.xml b/ecomp-portal-widget-ms/widget-ms/src/main/resources/logback.xml
new file mode 100644
index 00000000..204a6598
--- /dev/null
+++ b/ecomp-portal-widget-ms/widget-ms/src/main/resources/logback.xml
@@ -0,0 +1,138 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<configuration>
+
+ <property name="WIDGET_LOG_HOME" value="logs" />
+
+
+ <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
+ <layout class="ch.qos.logback.classic.PatternLayout">
+ <Pattern>
+ %d{yyyy-MM-dd HH:mm:ss} [%thread] %-5level %logger{36} - %msg%n
+ </Pattern>
+ </layout>
+ </appender>
+
+ <logger name="org.springframework.web" level="info" additivity="false">
+ <appender-ref ref="STDOUT" />
+ </logger>
+
+ <contextName>${HOSTNAME}</contextName>
+
+
+ <appender name="ADUIT"
+ class="ch.qos.logback.core.rolling.RollingFileAppender">
+ <file>${WIDGET_LOG_HOME}/aduit.log</file>
+ <encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
+ <Pattern>
+ %date{yyyy-MM-dd'T'HH:mm:ss.SSSXXX}|%X{RequestId}|%logger{0}|%-5level|%contextName| %msg%n"
+ </Pattern>
+ </encoder>
+ <!-- %d{yyyy-MM-dd HH:mm:ss} - %msg%n -->
+ <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
+ <fileNamePattern>${WIDGET_LOG_HOME}/archived/aduit.%d{yyyy-MM-dd}.%i.zip
+ </fileNamePattern>
+ <maxHistory>30</maxHistory>
+ <timeBasedFileNamingAndTriggeringPolicy
+ class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
+ <maxFileSize>100KB</maxFileSize>
+ </timeBasedFileNamingAndTriggeringPolicy>
+ </rollingPolicy>
+ </appender>
+
+ <appender name="APPLICATION"
+ class="ch.qos.logback.core.rolling.RollingFileAppender">
+ <file>${WIDGET_LOG_HOME}/application.log</file>
+ <encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
+ <Pattern>
+ %date{yyyy-MM-dd'T'HH:mm:ss.SSSXXX}|%X{RequestId}|%logger{0}|%-5level|%contextName| %msg%n"
+ </Pattern>
+ </encoder>
+ <!-- %d{yyyy-MM-dd HH:mm:ss} - %msg%n -->
+ <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
+ <fileNamePattern>${WIDGET_LOG_HOME}/archived/application.%d{yyyy-MM-dd}.%i.zip
+ </fileNamePattern>
+ <maxHistory>30</maxHistory>
+ <timeBasedFileNamingAndTriggeringPolicy
+ class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
+ <maxFileSize>100KB</maxFileSize>
+ </timeBasedFileNamingAndTriggeringPolicy>
+ </rollingPolicy>
+ </appender>
+
+
+ <appender name="DEBUG"
+ class="ch.qos.logback.core.rolling.RollingFileAppender">
+ <file>${WIDGET_LOG_HOME}/debug.log</file>
+ <encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
+ <Pattern>
+ %date{yyyy-MM-dd'T'HH:mm:ss.SSSXXX}|%X{RequestId}|%logger{0}|%-5level|%contextName| %msg%n"
+ </Pattern>
+ </encoder>
+ <!-- %d{yyyy-MM-dd HH:mm:ss} - %msg%n -->
+ <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
+ <fileNamePattern>${WIDGET_LOG_HOME}/archived/debug.%d{yyyy-MM-dd}.%i.zip
+ </fileNamePattern>
+ <maxHistory>30</maxHistory>
+ <timeBasedFileNamingAndTriggeringPolicy
+ class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
+ <maxFileSize>100KB</maxFileSize>
+ </timeBasedFileNamingAndTriggeringPolicy>
+ </rollingPolicy>
+ </appender>
+
+
+ <appender name="ERROR"
+ class="ch.qos.logback.core.rolling.RollingFileAppender">
+ <file>${WIDGET_LOG_HOME}/error.log</file>
+ <encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
+ <Pattern>
+ %date{yyyy-MM-dd'T'HH:mm:ss.SSSXXX}|%X{RequestId}|%logger{0}|%-5level|%contextName| %msg%n"
+ </Pattern>
+ </encoder>
+
+ <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
+ <fileNamePattern>${WIDGET_LOG_HOME}/archived/error.%d{yyyy-MM-dd}.%i.zip
+ </fileNamePattern>
+ <maxHistory>30</maxHistory>
+ <timeBasedFileNamingAndTriggeringPolicy
+ class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
+ <maxFileSize>100KB</maxFileSize>
+ </timeBasedFileNamingAndTriggeringPolicy>
+ </rollingPolicy>
+ </appender>
+
+
+ <appender name="METRICS"
+ class="ch.qos.logback.core.rolling.RollingFileAppender">
+ <file>${WIDGET_LOG_HOME}/metrics.log</file>
+ <encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
+ <Pattern>
+ %date{yyyy-MM-dd'T'HH:mm:ss.SSSXXX}|%X{RequestId}|%logger{0}|%-5level|%contextName| %msg%n"
+ </Pattern>
+ </encoder>
+
+ <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
+ <fileNamePattern>${WIDGET_LOG_HOME}/archived/metrics.%d{yyyy-MM-dd}.%i.zip
+ </fileNamePattern>
+ <maxHistory>30</maxHistory>
+ <timeBasedFileNamingAndTriggeringPolicy
+ class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
+ <maxFileSize>100KB</maxFileSize>
+ </timeBasedFileNamingAndTriggeringPolicy>
+ </rollingPolicy>
+ </appender>
+
+ <logger name="org.openecomp.portalapp.widget" level="debug" additivity="false">
+ <appender-ref ref="ERROR" />
+ <appender-ref ref="DEBUG" />
+ <appender-ref ref="APPLICATION" />
+ <appender-ref ref="STDOUT" />
+ </logger>
+
+ <root level="info">
+ <appender-ref ref="DEBUG" />
+ <appender-ref ref="APPLICATION" />
+ <appender-ref ref="STDOUT" />
+ </root>
+
+</configuration> \ No newline at end of file