blob: 2774b580aa7c7c26b0bccbc342e70d27a8f24628 [file] [log] [blame]
Li Zic5290dc2018-08-06 09:26:27 +00001<configuration scan="false" debug="true">
2 <property name="p_tim" value="%d{&quot;yyyy-MM-dd'T'HH:mm:ss.SSSXXX&quot;, UTC}"/>
3 <property name="p_lvl" value="%level"/>
4 <property name="p_log" value="%logger"/>
5 <property name="p_mdc" value="%replace(%replace(%mdc){'\t','\\\\t'}){'\n', '\\\\n'}"/>
6 <property name="p_msg" value="%replace(%replace(%msg){'\t', '\\\\t'}){'\n','\\\\n'}"/>
7 <property name="p_exc" value="%replace(%replace(%rootException){'\t', '\\\\t'}){'\n','\\\\n'}"/>
8 <property name="p_mak" value="%replace(%replace(%marker){'\t', '\\\\t'}){'\n','\\\\n'}"/>
9 <property name="p_thr" value="%thread"/>
10 <property name="pattern" value="%nopexception${p_tim}\t${p_thr}\t${p_lvl}\t${p_log}\t${p_mdc}\t${p_msg}\t${p_exc}\t${p_mak}\t%n"/>
11
12 <property name="logDir" value="/var/log/onap" />
13 <property name="debugDir" value="/var/log/onap" />
14
15 <property name="componentName" value="msb"></property>
16 <property name="subComponentName" value="msb-iag"></property>
17
18 <property name="errorLogName" value="error" />
19 <property name="metricsLogName" value="metrics" />
20 <property name="auditLogName" value="audit" />
21 <property name="debugLogName" value="debug" />
22
23 <property name="errorPattern" value="%d{&quot;yyyy-MM-dd'T'HH:mm:ss.SSSXXX&quot;, UTC}|%X{RequestId}|%thread|%X{ServiceName}|%X{PartnerName}|%X{TargetEntity}|%X{TargetServiceName}|%.-5level|%X{ErrorCode}|%X{ErrorDesc}|%msg%n\t${p_mdc}\t${p_msg}\t${p_exc}\t${p_mak}\t%n" />
24 <property name="debugPattern" value="%d{&quot;yyyy-MM-dd'T'HH:mm:ss.SSSXXX&quot;, UTC}|%X{RequestId}|%msg%n\t${p_mdc}\t${p_msg}\t${p_exc}\t${p_mak}\t%n" />
25
26 <property name="auditPattern" value="%X{BeginTimestamp}|%X{EndTimestamp}|%X{RequestId}|%X{ServiceInstanceId}|%thread||%X{ServiceName}|%X{PartnerName}|%X{StatusCode}|%X{ResponseCode}|%X{ResponseDesc}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{Timer}|%X{ServerFQDN}|%X{RemoteHost}||||||||%msg%n" />
27 <property name="metricPattern" value="%X{BeginTimestamp}|%X{EndTimestamp}|%X{RequestId}|%X{ServiceInstanceId}|%thread||%X{ServiceName}|%X{PartnerName}|%X{TargetEntity}|%X{TargetServiceName}|%X{StatusCode}|%X{ResponseCode}|%X{ResponseDesc}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{Timer}|%X{ServerFQDN}|%X{RemoteHost}||||%X{TargetVirtualEntity}|||||%msg%n" />
28 <property name="logDirectory" value="${logDir}/${componentName}/${subComponentName}" />
29 <property name="debugLogDirectory" value="${debugDir}/${componentName}/${subComponentName}" />
30
31 <appender name="EELFAudit"
32 class="ch.qos.logback.core.rolling.RollingFileAppender">
33 <file>${logDirectory}/${auditLogName}.log</file>
34 <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
35 <fileNamePattern>${logDirectory}/${auditLogName}.log.%d</fileNamePattern>
36 </rollingPolicy>
37 <encoder>
38 <pattern>${auditPattern}</pattern>
39 </encoder>
40 </appender>
41
42 <appender name="asyncEELFAudit" class="ch.qos.logback.classic.AsyncAppender">
43 <queueSize>256</queueSize>
44 <appender-ref ref="EELFAudit" />
45 </appender>
46
47 <appender name="EELFMetrics" class="ch.qos.logback.core.rolling.RollingFileAppender">
48 <file>${logDirectory}/${metricsLogName}.log</file>
49 <rollingPolicy
50 class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
51 <fileNamePattern>${logDirectory}/${metricsLogName}.log.%d</fileNamePattern>
52 </rollingPolicy>
53 <encoder>
54 <pattern>${metricPattern}</pattern>
55 </encoder>
56 </appender>
57
58 <appender name="asyncEELFMetrics" class="ch.qos.logback.classic.AsyncAppender">
59 <queueSize>256</queueSize>
60 <appender-ref ref="EELFMetrics"/>
61 </appender>
62
63 <appender name="EELFError"
64 class="ch.qos.logback.core.rolling.RollingFileAppender">
65 <file>${logDirectory}/${errorLogName}.log</file>
66 <rollingPolicy
67 class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
68 <fileNamePattern>${logDirectory}/${errorLogName}.log.%d</fileNamePattern>
69 </rollingPolicy>
70 <filter class="ch.qos.logback.classic.filter.ThresholdFilter">
71 <level>INFO</level>
72 </filter>
73 <encoder>
74 <pattern>${errorPattern}</pattern>
75 </encoder>
76 </appender>
77
78 <appender name="asyncEELFError" class="ch.qos.logback.classic.AsyncAppender">
79 <queueSize>256</queueSize>
80 <appender-ref ref="EELFError"/>
81 </appender>
82
83 <appender name="EELFDebug"
84 class="ch.qos.logback.core.rolling.RollingFileAppender">
85 <file>${debugLogDirectory}/${debugLogName}.log</file>
86 <rollingPolicy
87 class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
88 <fileNamePattern>${debugLogDirectory}/${debugLogName}.log.%d</fileNamePattern>
89 </rollingPolicy>
90 <encoder>
91 <pattern>${debugPattern}</pattern>
92 </encoder>
93 </appender>
94
95 <appender name="asyncEELFDebug" class="ch.qos.logback.classic.AsyncAppender">
96 <queueSize>256</queueSize>
97 <appender-ref ref="EELFDebug" />
98 <includeCallerData>true</includeCallerData>
99 </appender>
100
101 <logger name="com.att.eelf.audit" level="info" additivity="false">
102 <appender-ref ref="asyncEELFAudit" />
103 </logger>
104
105 <logger name="com.att.eelf.metrics" level="info" additivity="false">
106 <appender-ref ref="asyncEELFMetrics" />
107 </logger>
108
109 <logger name="com.att.eelf.error" level="debug" additivity="false">
110 <appender-ref ref="asyncEELFError" />
111 </logger>
112
113 <root level="INFO">
114 <appender-ref ref="asyncEELFDebug" />
115 </root>
116
117</configuration>
118