Aharoni, Pavel (pa0916) | ca3cb01 | 2018-10-22 15:29:57 +0300 | [diff] [blame] | 1 | <?xml version="1.0" encoding="UTF-8"?>
|
| 2 | <!--/*-
|
| 3 | * ============LICENSE_START=======================================================
|
| 4 | * OSAM Core
|
| 5 | * ================================================================================
|
| 6 | * Copyright (C) 2018 AT&T
|
| 7 | * ================================================================================
|
| 8 | * Licensed under the Apache License, Version 2.0 (the "License");
|
| 9 | * you may not use this file except in compliance with the License.
|
| 10 | * You may obtain a copy of the License at
|
| 11 | *
|
| 12 | * http://www.apache.org/licenses/LICENSE-2.0
|
| 13 | *
|
| 14 | * Unless required by applicable law or agreed to in writing, software
|
| 15 | * distributed under the License is distributed on an "AS IS" BASIS,
|
| 16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
| 17 | * See the License for the specific language governing permissions and
|
| 18 | * limitations under the License.
|
| 19 | * ============LICENSE_END=========================================================
|
| 20 | */
|
| 21 | -->
|
| 22 |
|
| 23 | <configuration scan="true" scanPeriod="3 seconds" debug="true">
|
| 24 | <!-- specify the component name -->
|
| 25 | <property name="componentName" value="vid"></property>
|
| 26 |
|
| 27 | <!-- specify the base path of the log directory -->
|
| 28 | <property name="logDirPrefix" value="${VID_LOG_DIR}"></property>
|
| 29 |
|
| 30 | <!-- The directories where logs are written -->
|
| 31 | <property name="logDirectory" value="${logDirPrefix}/${componentName}" />
|
| 32 | <!-- Can easily relocate debug logs by modifying this path. -->
|
| 33 | <property name="debugLogDirectory" value="${logDirPrefix}/${componentName}" />
|
| 34 |
|
| 35 | <!-- log file names -->
|
| 36 | <property name="generalLogName" value="application" />
|
| 37 | <property name="errorLogName" value="error" />
|
| 38 | <property name="metricsLogName" value="metrics" />
|
| 39 | <property name="auditLogName" value="audit" />
|
| 40 | <property name="debugLogName" value="debug" />
|
| 41 | <!--
|
| 42 | These loggers are not used in code (yet).
|
| 43 | <property name="securityLogName" value="security" />
|
| 44 | <property name="policyLogName" value="policy" />
|
| 45 | <property name="performanceLogName" value="performance" />
|
| 46 | <property name="serverLogName" value="server" />
|
| 47 | -->
|
| 48 |
|
| 49 | <property name="defaultPattern" value="%date{ISO8601}|%X{RequestId}|%X{ServiceInstanceId}|%thread|%X{VirtualServerName}|%X{ServiceName}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{ServerFQDN}|%X{RemoteHost}|%X{ClassName}|%X{Timer}| %msg%n" />
|
| 50 | <property name="debugLoggerPattern" value="%date{ISO8601}|%X{RequestId}|%X{ServiceInstanceId}|%thread|%X{VirtualServerName}|%X{ServiceName}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{ServerFQDN}|%X{RemoteHost}|%X{ClassName}|%X{Timer}| %msg%n" />
|
| 51 | <!-- <property name="debugLoggerPattern" value="%date{ISO8601}|%X{RequestId}|%X{ServiceInstanceId}|%thread|%X{ServiceName}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{ServerFQDN}|%X{RemoteHost}|%X{Timer}|[%caller{3}]|%msg%n" />-->
|
| 52 |
|
| 53 | <!-- Example evaluator filter applied against console appender -->
|
| 54 | <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
|
| 55 | <encoder>
|
| 56 | <pattern>${defaultPattern}</pattern>
|
| 57 | </encoder>
|
| 58 | </appender>
|
| 59 |
|
| 60 | <!-- ============================================================================ -->
|
| 61 | <!-- EELF Appenders -->
|
| 62 | <!-- ============================================================================ -->
|
| 63 |
|
| 64 | <!-- The EELFAppender is used to record events to the general application
|
| 65 | log -->
|
| 66 |
|
| 67 |
|
| 68 | <appender name="EELF"
|
| 69 | class="ch.qos.logback.core.rolling.RollingFileAppender">
|
| 70 | <file>${logDirectory}/${generalLogName}.log</file>
|
| 71 | <rollingPolicy
|
| 72 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
| 73 | <fileNamePattern>${logDirectory}/${generalLogName}.%i.log.zip
|
| 74 | </fileNamePattern>
|
| 75 | <minIndex>1</minIndex>
|
| 76 | <maxIndex>9</maxIndex>
|
| 77 | </rollingPolicy>
|
| 78 | <triggeringPolicy
|
| 79 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
| 80 | <maxFileSize>5MB</maxFileSize>
|
| 81 | </triggeringPolicy>
|
| 82 | <encoder>
|
| 83 | <pattern>${defaultPattern}</pattern>
|
| 84 | </encoder>
|
| 85 | <filter class="org.onap.portalapp.util.CustomLoggingFilter" />
|
| 86 | </appender>
|
| 87 |
|
| 88 | <appender name="asyncEELF" class="ch.qos.logback.classic.AsyncAppender">
|
| 89 | <queueSize>256</queueSize>
|
| 90 | <appender-ref ref="EELF" />
|
| 91 | </appender>
|
| 92 |
|
| 93 | <!-- EELF Security Appender. This appender is used to record security events
|
| 94 | to the security log file. Security events are separate from other loggers
|
| 95 | in EELF so that security log records can be captured and managed in a secure
|
| 96 | way separate from the other logs. This appender is set to never discard any
|
| 97 | events. -->
|
| 98 | <!--
|
| 99 | <appender name="EELFSecurity"
|
| 100 | class="ch.qos.logback.core.rolling.RollingFileAppender">
|
| 101 | <file>${logDirectory}/${securityLogName}.log</file>
|
| 102 | <rollingPolicy
|
| 103 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
| 104 | <fileNamePattern>${logDirectory}/${securityLogName}.%i.log.zip
|
| 105 | </fileNamePattern>
|
| 106 | <minIndex>1</minIndex>
|
| 107 | <maxIndex>9</maxIndex>
|
| 108 | </rollingPolicy>
|
| 109 | <triggeringPolicy
|
| 110 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
| 111 | <maxFileSize>5MB</maxFileSize>
|
| 112 | </triggeringPolicy>
|
| 113 | <encoder>
|
| 114 | <pattern>${defaultPattern}</pattern>
|
| 115 | </encoder>
|
| 116 | </appender>
|
| 117 |
|
| 118 | <appender name="asyncEELFSecurity" class="ch.qos.logback.classic.AsyncAppender">
|
| 119 | <queueSize>256</queueSize>
|
| 120 | <discardingThreshold>0</discardingThreshold>
|
| 121 | <appender-ref ref="EELFSecurity" />
|
| 122 | </appender>
|
| 123 | -->
|
| 124 |
|
| 125 | <!-- EELF Performance Appender. This appender is used to record performance
|
| 126 | records. -->
|
| 127 | <!--
|
| 128 | <appender name="EELFPerformance"
|
| 129 | class="ch.qos.logback.core.rolling.RollingFileAppender">
|
| 130 | <file>${logDirectory}/${performanceLogName}.log</file>
|
| 131 | <rollingPolicy
|
| 132 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
| 133 | <fileNamePattern>${logDirectory}/${performanceLogName}.%i.log.zip
|
| 134 | </fileNamePattern>
|
| 135 | <minIndex>1</minIndex>
|
| 136 | <maxIndex>9</maxIndex>
|
| 137 | </rollingPolicy>
|
| 138 | <triggeringPolicy
|
| 139 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
| 140 | <maxFileSize>5MB</maxFileSize>
|
| 141 | </triggeringPolicy>
|
| 142 | <encoder>
|
| 143 | <outputPatternAsHeader>true</outputPatternAsHeader>
|
| 144 | <pattern>${defaultPattern}</pattern>
|
| 145 | </encoder>
|
| 146 | </appender>
|
| 147 | <appender name="asyncEELFPerformance" class="ch.qos.logback.classic.AsyncAppender">
|
| 148 | <queueSize>256</queueSize>
|
| 149 | <appender-ref ref="EELFPerformance" />
|
| 150 | </appender>
|
| 151 | -->
|
| 152 |
|
| 153 | <!-- EELF Server Appender. This appender is used to record Server related
|
| 154 | logging events. The Server logger and appender are specializations of the
|
| 155 | EELF application root logger and appender. This can be used to segregate Server
|
| 156 | events from other components, or it can be eliminated to record these events
|
| 157 | as part of the application root log. -->
|
| 158 | <!--
|
| 159 | <appender name="EELFServer"
|
| 160 | class="ch.qos.logback.core.rolling.RollingFileAppender">
|
| 161 | <file>${logDirectory}/${serverLogName}.log</file>
|
| 162 | <rollingPolicy
|
| 163 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
| 164 | <fileNamePattern>${logDirectory}/${serverLogName}.%i.log.zip
|
| 165 | </fileNamePattern>
|
| 166 | <minIndex>1</minIndex>
|
| 167 | <maxIndex>9</maxIndex>
|
| 168 | </rollingPolicy>
|
| 169 | <triggeringPolicy
|
| 170 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
| 171 | <maxFileSize>5MB</maxFileSize>
|
| 172 | </triggeringPolicy>
|
| 173 | <encoder>
|
| 174 | <pattern>${defaultPattern}</pattern>
|
| 175 | </encoder>
|
| 176 | </appender>
|
| 177 | <appender name="asyncEELFServer" class="ch.qos.logback.classic.AsyncAppender">
|
| 178 | <queueSize>256</queueSize>
|
| 179 | <appender-ref ref="EELFServer" />
|
| 180 | </appender>
|
| 181 | -->
|
| 182 |
|
| 183 | <!-- EELF Policy Appender. This appender is used to record Policy engine
|
| 184 | related logging events. The Policy logger and appender are specializations
|
| 185 | of the EELF application root logger and appender. This can be used to segregate
|
| 186 | Policy engine events from other components, or it can be eliminated to record
|
| 187 | these events as part of the application root log. -->
|
| 188 | <!--
|
| 189 | <appender name="EELFPolicy"
|
| 190 | class="ch.qos.logback.core.rolling.RollingFileAppender">
|
| 191 | <file>${logDirectory}/${policyLogName}.log</file>
|
| 192 | <rollingPolicy
|
| 193 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
| 194 | <fileNamePattern>${logDirectory}/${policyLogName}.%i.log.zip
|
| 195 | </fileNamePattern>
|
| 196 | <minIndex>1</minIndex>
|
| 197 | <maxIndex>9</maxIndex>
|
| 198 | </rollingPolicy>
|
| 199 | <triggeringPolicy
|
| 200 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
| 201 | <maxFileSize>5MB</maxFileSize>
|
| 202 | </triggeringPolicy>
|
| 203 | <encoder>
|
| 204 | <pattern>${defaultPattern}</pattern>
|
| 205 | </encoder>
|
| 206 | </appender>
|
| 207 | <appender name="asyncEELFPolicy" class="ch.qos.logback.classic.AsyncAppender">
|
| 208 | <queueSize>256</queueSize>
|
| 209 | <appender-ref ref="EELFPolicy" />
|
| 210 | </appender>
|
| 211 | -->
|
| 212 |
|
| 213 | <!-- EELF Audit Appender. This appender is used to record audit engine
|
| 214 | related logging events. The audit logger and appender are specializations
|
| 215 | of the EELF application root logger and appender. This can be used to segregate
|
| 216 | Policy engine events from other components, or it can be eliminated to record
|
| 217 | these events as part of the application root log. -->
|
| 218 |
|
| 219 | <appender name="EELFAudit"
|
| 220 | class="ch.qos.logback.core.rolling.RollingFileAppender">
|
| 221 | <file>${logDirectory}/${auditLogName}.log</file>
|
| 222 | <rollingPolicy
|
| 223 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
| 224 | <fileNamePattern>${logDirectory}/${auditLogName}.%i.log.zip
|
| 225 | </fileNamePattern>
|
| 226 | <minIndex>1</minIndex>
|
| 227 | <maxIndex>9</maxIndex>
|
| 228 | </rollingPolicy>
|
| 229 | <triggeringPolicy
|
| 230 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
| 231 | <maxFileSize>5MB</maxFileSize>
|
| 232 | </triggeringPolicy>
|
| 233 | <encoder>
|
| 234 | <pattern>${defaultPattern}</pattern>
|
| 235 | </encoder>
|
| 236 | </appender>
|
| 237 | <appender name="asyncEELFAudit" class="ch.qos.logback.classic.AsyncAppender">
|
| 238 | <queueSize>256</queueSize>
|
| 239 | <appender-ref ref="EELFAudit" />
|
| 240 | </appender>
|
| 241 |
|
| 242 | <appender name="EELFMetrics"
|
| 243 | class="ch.qos.logback.core.rolling.RollingFileAppender">
|
| 244 | <file>${logDirectory}/${metricsLogName}.log</file>
|
| 245 | <rollingPolicy
|
| 246 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
| 247 | <fileNamePattern>${logDirectory}/${metricsLogName}.%i.log.zip
|
| 248 | </fileNamePattern>
|
| 249 | <minIndex>1</minIndex>
|
| 250 | <maxIndex>9</maxIndex>
|
| 251 | </rollingPolicy>
|
| 252 | <triggeringPolicy
|
| 253 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
| 254 | <maxFileSize>5MB</maxFileSize>
|
| 255 | </triggeringPolicy>
|
| 256 | <encoder>
|
| 257 | <!-- <pattern>"%d{HH:mm:ss.SSS} [%thread] %-5level %logger{1024} -
|
| 258 | %msg%n"</pattern> -->
|
| 259 | <pattern>${defaultPattern}</pattern>
|
| 260 | </encoder>
|
| 261 | </appender>
|
| 262 |
|
| 263 |
|
| 264 | <appender name="asyncEELFMetrics" class="ch.qos.logback.classic.AsyncAppender">
|
| 265 | <queueSize>256</queueSize>
|
| 266 | <appender-ref ref="EELFMetrics"/>
|
| 267 | </appender>
|
| 268 |
|
| 269 | <appender name="EELFError"
|
| 270 | class="ch.qos.logback.core.rolling.RollingFileAppender">
|
| 271 | <file>${logDirectory}/${errorLogName}.log</file>
|
| 272 | <rollingPolicy
|
| 273 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
| 274 | <fileNamePattern>${logDirectory}/${errorLogName}.%i.log.zip
|
| 275 | </fileNamePattern>
|
| 276 | <minIndex>1</minIndex>
|
| 277 | <maxIndex>9</maxIndex>
|
| 278 | </rollingPolicy>
|
| 279 | <triggeringPolicy
|
| 280 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
| 281 | <maxFileSize>5MB</maxFileSize>
|
| 282 | </triggeringPolicy>
|
| 283 | <encoder>
|
| 284 | <pattern>${defaultPattern}</pattern>
|
| 285 | </encoder>
|
| 286 | </appender>
|
| 287 |
|
| 288 | <appender name="asyncEELFError" class="ch.qos.logback.classic.AsyncAppender">
|
| 289 | <queueSize>256</queueSize>
|
| 290 | <appender-ref ref="EELFError"/>
|
| 291 | </appender>
|
| 292 |
|
| 293 | <appender name="EELFDebug"
|
| 294 | class="ch.qos.logback.core.rolling.RollingFileAppender">
|
| 295 | <file>${debugLogDirectory}/${debugLogName}.log</file>
|
| 296 | <rollingPolicy
|
| 297 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
| 298 | <fileNamePattern>${debugLogDirectory}/${debugLogName}.%i.log.zip
|
| 299 | </fileNamePattern>
|
| 300 | <minIndex>1</minIndex>
|
| 301 | <maxIndex>9</maxIndex>
|
| 302 | </rollingPolicy>
|
| 303 | <triggeringPolicy
|
| 304 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
| 305 | <maxFileSize>5MB</maxFileSize>
|
| 306 | </triggeringPolicy>
|
| 307 | <encoder>
|
| 308 | <pattern>${debugLoggerPattern}</pattern>
|
| 309 | </encoder>
|
| 310 | </appender>
|
| 311 |
|
| 312 | <appender name="asyncEELFDebug" class="ch.qos.logback.classic.AsyncAppender">
|
| 313 | <queueSize>256</queueSize>
|
| 314 | <appender-ref ref="EELFDebug" />
|
| 315 | <includeCallerData>true</includeCallerData>
|
| 316 | </appender>
|
| 317 |
|
| 318 |
|
| 319 | <!-- ============================================================================ -->
|
| 320 | <!-- EELF loggers -->
|
| 321 | <!-- ============================================================================ -->
|
| 322 | <logger name="com.att.eelf" level="debug" additivity="false">
|
| 323 | <appender-ref ref="asyncEELF" />
|
| 324 | </logger>
|
| 325 |
|
| 326 | <!--
|
| 327 | <logger name="com.att.eelf.security" level="info" additivity="false">
|
| 328 | <appender-ref ref="asyncEELFSecurity" />
|
| 329 | </logger>
|
| 330 | <logger name="com.att.eelf.perf" level="info" additivity="false">
|
| 331 | <appender-ref ref="asyncEELFPerformance" />
|
| 332 | </logger>
|
| 333 | <logger name="com.att.eelf.server" level="info" additivity="false">
|
| 334 | <appender-ref ref="asyncEELFServer" />
|
| 335 | </logger>
|
| 336 | <logger name="com.att.eelf.policy" level="info" additivity="false">
|
| 337 | <appender-ref ref="asyncEELFPolicy" />
|
| 338 | </logger>
|
| 339 | -->
|
| 340 |
|
| 341 | <logger name="com.att.eelf.audit" level="info" additivity="false">
|
| 342 | <appender-ref ref="asyncEELFAudit" />
|
| 343 | </logger>
|
| 344 |
|
| 345 | <logger name="com.att.eelf.metrics" level="info" additivity="false">
|
| 346 | <appender-ref ref="asyncEELFMetrics" />
|
| 347 | </logger>
|
| 348 |
|
| 349 | <logger name="com.att.eelf.error" level="info" additivity="false">
|
| 350 | <appender-ref ref="asyncEELFError" />
|
| 351 | </logger>
|
| 352 |
|
| 353 | <logger name="com.att.eelf.debug" level="debug" additivity="false">
|
| 354 | <appender-ref ref="asyncEELFDebug" />
|
| 355 | </logger>
|
| 356 |
|
| 357 |
|
| 358 | <root level="${VID_LOG_LEVEL}">
|
| 359 | <appender-ref ref="asyncEELF" />
|
| 360 | </root>
|
| 361 |
|
| 362 | </configuration>
|