blob: e3867e791a90446d4f6b0d41d9adc094f4068b76 [file] [log] [blame]
Jim Hahne8711322018-02-13 14:16:47 -05001<!--
2 ============LICENSE_START=======================================================
3 Integrity Audit
4 ================================================================================
Jim Hahn00747e52019-08-27 14:13:25 -04005 Copyright (C) 2018-2019 AT&T Intellectual Property. All rights reserved.
Jim Hahne8711322018-02-13 14:16:47 -05006 ================================================================================
7 Licensed under the Apache License, Version 2.0 (the "License");
8 you may not use this file except in compliance with the License.
9 You may obtain a copy of the License at
Jim Hahn00747e52019-08-27 14:13:25 -040010
Jim Hahne8711322018-02-13 14:16:47 -050011 http://www.apache.org/licenses/LICENSE-2.0
Jim Hahn00747e52019-08-27 14:13:25 -040012
Jim Hahne8711322018-02-13 14:16:47 -050013 Unless required by applicable law or agreed to in writing, software
14 distributed under the License is distributed on an "AS IS" BASIS,
15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 See the License for the specific language governing permissions and
17 limitations under the License.
18 ============LICENSE_END=========================================================
19 -->
20
21<!-- Controls the output of logs for JUnit tests -->
22
liamfallon3073f502019-12-04 10:24:58 +000023<configuration
24 scan="false"
25 debug="true">
Jim Hahne8711322018-02-13 14:16:47 -050026 <!--<jmxConfigurator /> -->
27 <!-- directory path for all other type logs -->
liamfallon3073f502019-12-04 10:24:58 +000028 <property
29 name="logDir"
30 value="testingLogs" />
Jim Hahn00747e52019-08-27 14:13:25 -040031
Jim Hahne8711322018-02-13 14:16:47 -050032 <!-- directory path for debugging type logs -->
liamfallon3073f502019-12-04 10:24:58 +000033 <property
34 name="debugDir"
35 value="testingLogs" />
Jim Hahn00747e52019-08-27 14:13:25 -040036
37 <!-- specify the component name
Jim Hahne8711322018-02-13 14:16:47 -050038 <ONAP-component-name>::= "MSO" | "DCAE" | "ASDC " | "AAI" |"Policy" | "SDNC" | "AC" -->
liamfallon3073f502019-12-04 10:24:58 +000039 <property
40 name="componentName"
41 value="common-modules"></property>
42 <property
43 name="subComponentName"
44 value="integrity-audit"></property>
Jim Hahn00747e52019-08-27 14:13:25 -040045
Jim Hahne8711322018-02-13 14:16:47 -050046 <!-- log file names -->
liamfallon3073f502019-12-04 10:24:58 +000047 <property
48 name="errorLogName"
49 value="error" />
50 <property
51 name="metricsLogName"
52 value="metrics" />
53 <property
54 name="auditLogName"
55 value="audit" />
56 <property
57 name="debugLogName"
58 value="debug" />
Jim Hahn00747e52019-08-27 14:13:25 -040059
liamfallon3073f502019-12-04 10:24:58 +000060 <property
61 name="defaultPatternTimestamp"
62 value="%d{yyyy-MM-dd'T'HH:mm:ss.SSSXXX, UTC}" />
63
64 <property
65 name="defaultPatternTarget"
66 value="%X{requestId}|%X{serviceInstanceId}|%t|%X{serverName}|%X{serviceName}|%X{instanceUuid}" />
67
68
69 <property
70 name="defaultPatternDetails"
71 value="%X{severity}|%X{serverIpAddress}|%X{server}|%X{clientIpAddress}" />
72
73 <property
74 name="defaultPattern"
75 value="${defaultPatternTimestamp}|${defaultPatternTarget}|%p|${defaultPatternDetails}|%c||%msg%n" />
76
77 <property
78 name="logDirectory"
79 value="${logDir}/${componentName}/${subComponentName}" />
80 <property
81 name="debugLogDirectory"
82 value="${debugDir}/${componentName}/${subComponentName}" />
Jim Hahne8711322018-02-13 14:16:47 -050083 <!--
84 <property name="logDirectory" value="${logDir}/${componentName}/${subComponentName}" />
85 <property name="debugLogDirectory" value="${debugDir}/${componentName}/${subComponentName}" />
86 -->
Jim Hahn00747e52019-08-27 14:13:25 -040087 <!-- example from old log4j.properties: ${catalina.base}/logs/pdp-rest.log -->
Jim Hahne8711322018-02-13 14:16:47 -050088 <!-- Example evaluator filter applied against console appender -->
liamfallon3073f502019-12-04 10:24:58 +000089 <appender
90 name="STDOUT"
91 class="ch.qos.logback.core.ConsoleAppender">
92 <encoder>
93 <pattern>${defaultPattern}</pattern>
94 </encoder>
95 </appender>
Jim Hahne8711322018-02-13 14:16:47 -050096
97 <!-- ============================================================================ -->
98 <!-- EELF Appenders -->
99 <!-- ============================================================================ -->
100
Jim Hahn00747e52019-08-27 14:13:25 -0400101 <!-- The EELFAppender is used to record events to the general application
Jim Hahne8711322018-02-13 14:16:47 -0500102 log -->
Jim Hahne8711322018-02-13 14:16:47 -0500103
Jim Hahn00747e52019-08-27 14:13:25 -0400104
105
106
107 <!-- EELF Audit Appender. This appender is used to record audit engine
108 related logging events. The audit logger and appender are specializations
109 of the EELF application root logger and appender. This can be used to segregate
110 Policy engine events from other components, or it can be eliminated to record
Jim Hahne8711322018-02-13 14:16:47 -0500111 these events as part of the application root log. -->
Jim Hahn00747e52019-08-27 14:13:25 -0400112
liamfallon3073f502019-12-04 10:24:58 +0000113 <appender
114 name="EELFAudit"
115 class="ch.qos.logback.core.FileAppender">
116 <file>${logDirectory}/${auditLogName}.log</file>
117 <param
118 name="Append"
119 value="false" />
120 <encoder>
121 <pattern>${defaultPattern}</pattern>
122 </encoder>
123 </appender>
124 <appender
125 name="asyncEELFAudit"
126 class="ch.qos.logback.classic.AsyncAppender">
127 <queueSize>256</queueSize>
128 <appender-ref ref="EELFAudit" />
129 </appender>
Jim Hahne8711322018-02-13 14:16:47 -0500130
liamfallon3073f502019-12-04 10:24:58 +0000131 <appender
132 name="EELFMetrics"
133 class="ch.qos.logback.core.FileAppender">
134 <file>${logDirectory}/${metricsLogName}.log</file>
135 <param
136 name="Append"
137 value="false" />
138 <encoder>
139 <pattern>${defaultPattern}</pattern>
140 </encoder>
141 </appender>
Jim Hahn00747e52019-08-27 14:13:25 -0400142
143
liamfallon3073f502019-12-04 10:24:58 +0000144 <appender
145 name="asyncEELFMetrics"
146 class="ch.qos.logback.classic.AsyncAppender">
147 <queueSize>256</queueSize>
148 <appender-ref ref="EELFMetrics" />
149 </appender>
Jim Hahn00747e52019-08-27 14:13:25 -0400150
liamfallon3073f502019-12-04 10:24:58 +0000151 <appender
152 name="EELFError"
153 class="ch.qos.logback.core.FileAppender">
154 <file>${logDirectory}/${errorLogName}.log</file>
155 <param
156 name="Append"
157 value="false" />
158 <filter class="ch.qos.logback.classic.filter.ThresholdFilter">
159 <level>ERROR</level>
160 </filter>
161 <encoder>
162 <pattern>${defaultPattern}</pattern>
163 </encoder>
164 </appender>
Jim Hahn00747e52019-08-27 14:13:25 -0400165
liamfallon3073f502019-12-04 10:24:58 +0000166 <appender
167 name="asyncEELFError"
168 class="ch.qos.logback.classic.AsyncAppender">
169 <queueSize>256</queueSize>
170 <appender-ref ref="EELFError" />
171 </appender>
Jim Hahn00747e52019-08-27 14:13:25 -0400172
liamfallon3073f502019-12-04 10:24:58 +0000173 <appender
174 name="EELFDebug"
175 class="ch.qos.logback.core.FileAppender">
176 <file>${debugLogDirectory}/${debugLogName}.log</file>
177 <param
178 name="Append"
179 value="false" />
180 <filter class="ch.qos.logback.classic.filter.ThresholdFilter">
181 <level>DEBUG</level>
182 </filter>
183 <encoder>
184 <pattern>${defaultPattern}</pattern>
185 </encoder>
186 </appender>
Jim Hahn00747e52019-08-27 14:13:25 -0400187
liamfallon3073f502019-12-04 10:24:58 +0000188 <appender
189 name="asyncEELFDebug"
190 class="ch.qos.logback.classic.AsyncAppender">
191 <queueSize>256</queueSize>
192 <appender-ref ref="EELFDebug" />
193 <includeCallerData>true</includeCallerData>
194 </appender>
195
196 <!-- Appender for log testing -->
197 <appender
198 name="LoggingPatternTestAppender"
199 class="ch.qos.logback.core.FileAppender">
200 <file>${logDirectory}/logging-pattern-test.log</file>
201 <param
202 name="Append"
203 value="false" />
204 <encoder>
205 <pattern>${defaultPattern}</pattern>
206 </encoder>
207 </appender>
Jim Hahn00747e52019-08-27 14:13:25 -0400208
209
Jim Hahne8711322018-02-13 14:16:47 -0500210 <!-- ============================================================================ -->
211 <!-- EELF loggers -->
212 <!-- ============================================================================ -->
Jim Hahn00747e52019-08-27 14:13:25 -0400213
liamfallon3073f502019-12-04 10:24:58 +0000214 <logger
215 name="com.att.eelf.audit"
216 level="info"
217 additivity="false">
218 <appender-ref ref="asyncEELFAudit" />
219 </logger>
Jim Hahn00747e52019-08-27 14:13:25 -0400220
liamfallon3073f502019-12-04 10:24:58 +0000221 <logger
222 name="com.att.eelf.metrics"
223 level="info"
224 additivity="false">
Jim Hahne8711322018-02-13 14:16:47 -0500225 <appender-ref ref="asyncEELFMetrics" />
liamfallon3073f502019-12-04 10:24:58 +0000226 </logger>
Jim Hahn00747e52019-08-27 14:13:25 -0400227
liamfallon3073f502019-12-04 10:24:58 +0000228 <logger
229 name="com.att.eelf.error"
230 level="error"
231 additivity="false">
232 <appender-ref ref="asyncEELFError" />
233 </logger>
Jim Hahn00747e52019-08-27 14:13:25 -0400234
Jim Hahne8711322018-02-13 14:16:47 -0500235 <!-- <logger name="com.att.eelf.debug" level="info" additivity="false"> -->
liamfallon3073f502019-12-04 10:24:58 +0000236 <logger
237 name="com.att.eelf.debug"
238 level="debug"
239 additivity="false">
Jim Hahne8711322018-02-13 14:16:47 -0500240 <appender-ref ref="asyncEELFDebug" />
liamfallon3073f502019-12-04 10:24:58 +0000241 </logger>
Jim Hahn00747e52019-08-27 14:13:25 -0400242
243
Jim Hahne8711322018-02-13 14:16:47 -0500244 <!-- <root level="INFO"> -->
liamfallon3073f502019-12-04 10:24:58 +0000245 <root level="DEBUG">
Jim Hahne8711322018-02-13 14:16:47 -0500246 <appender-ref ref="asyncEELFDebug" />
247 <appender-ref ref="asyncEELFError" />
liamfallon3073f502019-12-04 10:24:58 +0000248 </root>
249
250 <!-- Logger for default pattern test -->
251 <logger
252 name="org.onap.policy.common.ia.DefaultLoggingPatternTest"
253 level="trace"
254 additivity="false">
255 <appender-ref ref="LoggingPatternTestAppender" />
256 </logger>
Jim Hahne8711322018-02-13 14:16:47 -0500257
258</configuration>