blob: 7d773830cd2fd6e7d93a2c6996049741ecab99f5 [file] [log] [blame]
econwar378cf192019-01-08 16:19:59 +00001<!--
2 ============LICENSE_START=======================================================
3 Copyright (C) 2019 Nordix Foundation.
4 ================================================================================
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at
8
9 http://www.apache.org/licenses/LICENSE-2.0
10
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16
17 SPDX-License-Identifier: Apache-2.0
18 ============LICENSE_END=========================================================
19-->
efiacor7b9a0872019-08-28 21:20:22 +000020<configuration scan="true" scanPeriod="3 seconds" debug="false">
econwar378cf192019-01-08 16:19:59 +000021
efiacor7b9a0872019-08-28 21:20:22 +000022 <property name="logDir" value="/var/log/onap/datarouter" />
23 <!-- log file names -->
24 <property name="auditLog" value="audit" />
25 <property name="errorLog" value="error" />
26 <property name="debugLog" value="debug" />
27 <property name="metricsLog" value="metrics" />
28 <property name="jettyLog" value="jetty" />
econwar378cf192019-01-08 16:19:59 +000029
efiacor7b9a0872019-08-28 21:20:22 +000030 <!-- log file names -->
31 <property name="defaultPattern" value="%d{MM/dd-HH:mm:ss.SSS}|%logger|%X{RequestId}|%X{InvocationId}|%X{ServiceInstanceId}|%thread|%X{ServiceName}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{ServerFQDN}|%X{RemoteHost}|%X{Timer}%n|%msg%n" />
32 <property name="logDirectory" value="${logDir}" />
econwar378cf192019-01-08 16:19:59 +000033
efiacor7b9a0872019-08-28 21:20:22 +000034 <!-- Example evaluator filter applied against console appender -->
econwar378cf192019-01-08 16:19:59 +000035 <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
36 <encoder>
37 <pattern>${defaultPattern}</pattern>
38 </encoder>
39 </appender>
40
41 <!-- ============================================================================ -->
42 <!-- EELF Appenders -->
43 <!-- ============================================================================ -->
44
efiacor7b9a0872019-08-28 21:20:22 +000045 <!-- The EELFAppender is used to record events to the general application
46 log -->
47
48
49 <appender name="Audit"
econwar378cf192019-01-08 16:19:59 +000050 class="ch.qos.logback.core.rolling.RollingFileAppender">
efiacor7b9a0872019-08-28 21:20:22 +000051 <file>${logDirectory}/${auditLog}.log</file>
52 <filter class="org.onap.dmaap.datarouter.node.eelf.AuditFilter">
econwar378cf192019-01-08 16:19:59 +000053 </filter>
54 <rollingPolicy
55 class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
efiacor7b9a0872019-08-28 21:20:22 +000056 <fileNamePattern>${logDirectory}/${auditLog}.%i.log.zip
econwar378cf192019-01-08 16:19:59 +000057 </fileNamePattern>
58 <minIndex>1</minIndex>
59 <maxIndex>9</maxIndex>
60 </rollingPolicy>
61 <triggeringPolicy
62 class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
efiacor7b9a0872019-08-28 21:20:22 +000063 <maxFileSize>50MB</maxFileSize>
econwar378cf192019-01-08 16:19:59 +000064 </triggeringPolicy>
65 <encoder>
66 <pattern>${defaultPattern}</pattern>
67 </encoder>
68 </appender>
69
efiacor7b9a0872019-08-28 21:20:22 +000070 <appender name="asyncAudit" class="ch.qos.logback.classic.AsyncAppender">
econwar378cf192019-01-08 16:19:59 +000071 <queueSize>256</queueSize>
efiacor7b9a0872019-08-28 21:20:22 +000072 <appender-ref ref="Audit" />
econwar378cf192019-01-08 16:19:59 +000073 </appender>
74
efiacor7b9a0872019-08-28 21:20:22 +000075 <!-- ============================================================================ -->
76
77 <appender name="Metrics"
78 class="ch.qos.logback.core.rolling.RollingFileAppender">
79 <file>${logDirectory}/${metricsLog}.log</file>
80 <filter class="org.onap.dmaap.datarouter.node.eelf.MetricsFilter">
econwar378cf192019-01-08 16:19:59 +000081 </filter>
82 <rollingPolicy
efiacor7b9a0872019-08-28 21:20:22 +000083 class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
84 <fileNamePattern>${logDirectory}/${metricsLog}.%i.log.zip
econwar378cf192019-01-08 16:19:59 +000085 </fileNamePattern>
86 <minIndex>1</minIndex>
87 <maxIndex>9</maxIndex>
88 </rollingPolicy>
89 <triggeringPolicy
efiacor7b9a0872019-08-28 21:20:22 +000090 class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
91 <maxFileSize>50MB</maxFileSize>
econwar378cf192019-01-08 16:19:59 +000092 </triggeringPolicy>
93 <encoder>
94 <pattern>${defaultPattern}</pattern>
95 </encoder>
96 </appender>
97
efiacor7b9a0872019-08-28 21:20:22 +000098 <appender name="asyncMetrics" class="ch.qos.logback.classic.AsyncAppender">
econwar378cf192019-01-08 16:19:59 +000099 <queueSize>256</queueSize>
efiacor7b9a0872019-08-28 21:20:22 +0000100 <appender-ref ref="Metrics" />
econwar378cf192019-01-08 16:19:59 +0000101 </appender>
102
103 <!-- ============================================================================ -->
efiacor7b9a0872019-08-28 21:20:22 +0000104
105
106 <appender name="Debug"
107 class="ch.qos.logback.core.rolling.RollingFileAppender">
108 <file>${logDirectory}/${debugLog}.log</file>
109 <filter class="org.onap.dmaap.datarouter.node.eelf.DebugFilter">
110 </filter>
111 <rollingPolicy
112 class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
113 <fileNamePattern>${logDirectory}/${debugLog}.%i.log.zip
114 </fileNamePattern>
115 <minIndex>1</minIndex>
116 <maxIndex>9</maxIndex>
117 </rollingPolicy>
118 <triggeringPolicy
119 class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
120 <maxFileSize>50MB</maxFileSize>
121 </triggeringPolicy>
122 <encoder>
123 <pattern>${defaultPattern}</pattern>
124 </encoder>
125 </appender>
126
127 <appender name="asyncDebug" class="ch.qos.logback.classic.AsyncAppender">
128 <queueSize>256</queueSize>
129 <appender-ref ref="Debug" />
130 </appender>
131
132 <!-- ============================================================================ -->
133
134 <appender name="Error"
econwar378cf192019-01-08 16:19:59 +0000135 class="ch.qos.logback.core.rolling.RollingFileAppender">
efiacor7b9a0872019-08-28 21:20:22 +0000136 <file>${logDirectory}/${errorLog}.log</file>
137 <filter class="org.onap.dmaap.datarouter.node.eelf.ErrorFilter">
138 </filter>
econwar378cf192019-01-08 16:19:59 +0000139 <rollingPolicy
140 class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
efiacor7b9a0872019-08-28 21:20:22 +0000141 <fileNamePattern>${logDirectory}/${errorLog}.%i.log.zip
econwar378cf192019-01-08 16:19:59 +0000142 </fileNamePattern>
143 <minIndex>1</minIndex>
144 <maxIndex>9</maxIndex>
145 </rollingPolicy>
146 <triggeringPolicy
147 class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
efiacor7b9a0872019-08-28 21:20:22 +0000148 <maxFileSize>50MB</maxFileSize>
econwar378cf192019-01-08 16:19:59 +0000149 </triggeringPolicy>
150 <encoder>
efiacor7b9a0872019-08-28 21:20:22 +0000151 <pattern>${defaultPattern}</pattern>
econwar378cf192019-01-08 16:19:59 +0000152 </encoder>
153 </appender>
154
efiacor7b9a0872019-08-28 21:20:22 +0000155 <appender name="asyncError" class="ch.qos.logback.classic.AsyncAppender">
econwar378cf192019-01-08 16:19:59 +0000156 <queueSize>256</queueSize>
efiacor7b9a0872019-08-28 21:20:22 +0000157 <appender-ref ref="Error"/>
158 </appender>
159
160 <!-- ============================================================================ -->
161 <appender name="Jetty"
162 class="ch.qos.logback.core.rolling.RollingFileAppender">
163 <file>${logDirectory}/${jettyLog}.log</file>
164 <filter class="org.onap.dmaap.datarouter.node.eelf.JettyFilter" />
165 <rollingPolicy
166 class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
167 <fileNamePattern>${logDirectory}/${jettyLog}.%i.log.zip
168 </fileNamePattern>
169 <minIndex>1</minIndex>
170 <maxIndex>9</maxIndex>
171 </rollingPolicy>
172 <triggeringPolicy
173 class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
174 <maxFileSize>50MB</maxFileSize>
175 </triggeringPolicy>
176 <encoder>
177 <pattern>${defaultPattern}</pattern>
178 </encoder>
179 </appender>
180
181 <appender name="asyncJettyLog" class="ch.qos.logback.classic.AsyncAppender">
182 <queueSize>256</queueSize>
183 <appender-ref ref="Jetty" />
econwar378cf192019-01-08 16:19:59 +0000184 <includeCallerData>true</includeCallerData>
185 </appender>
186
efiacor7b9a0872019-08-28 21:20:22 +0000187 <!-- ============================================================================ -->
188
189
econwar378cf192019-01-08 16:19:59 +0000190 <!-- ============================================================================ -->
191 <!-- EELF loggers -->
192 <!-- ============================================================================ -->
193 <logger name="com.att.eelf" level="info" additivity="false">
efiacor7b9a0872019-08-28 21:20:22 +0000194 <appender-ref ref="asyncAudit" />
econwar378cf192019-01-08 16:19:59 +0000195 </logger>
196
efiacor7b9a0872019-08-28 21:20:22 +0000197 <logger name="com.att.eelf" additivity="false">
198 <appender-ref ref="asyncMetrics" />
199 </logger>
econwar378cf192019-01-08 16:19:59 +0000200
efiacor7b9a0872019-08-28 21:20:22 +0000201 <logger name="com.att.eelf" additivity="false">
202 <appender-ref ref="asyncDebug" />
203 </logger>
204
205 <logger name="com.att.eelf.error" additivity="false">
206 <appender-ref ref="asyncError" />
207 </logger>
208
209 <logger name="log4j.logger.org.eclipse.jetty" additivity="false">
210 <appender-ref ref="asyncJettyLog"/>
211 </logger>
212
econwar378cf192019-01-08 16:19:59 +0000213
efiacor2123fec2022-12-09 13:40:55 +0000214 <root level="{{.Values.logLevel}}">
efiacor7b9a0872019-08-28 21:20:22 +0000215 <appender-ref ref="asyncAudit" />
216 <appender-ref ref="asyncMetrics" />
217 <appender-ref ref="asyncDebug" />
218 <appender-ref ref="asyncError" />
219 <appender-ref ref="asyncJettyLog" />
Dominik Mizyn3e54d4e2020-09-03 11:04:44 +0200220 <appender-ref ref="STDOUT" />
econwar378cf192019-01-08 16:19:59 +0000221 </root>
222
efiacor7b9a0872019-08-28 21:20:22 +0000223</configuration>