Prateekinlinux | 445a18e | 2018-08-01 06:48:33 +0000 | [diff] [blame] | 1 | <!--# Copyright © 2018 Amdocs, Bell Canada , ZTE |
| 2 | # |
| 3 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | # you may not use this file except in compliance with the License. |
| 5 | # You may obtain a copy of the License at |
| 6 | # |
| 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | # See the License for the specific language governing permissions and |
| 13 | # limitations under the License. --> |
Li Zi | c5290dc | 2018-08-06 09:26:27 +0000 | [diff] [blame] | 14 | <configuration scan="false" debug="true"> |
| 15 | <property name="p_tim" value="%d{"yyyy-MM-dd'T'HH:mm:ss.SSSXXX", UTC}"/> |
| 16 | <property name="p_lvl" value="%level"/> |
| 17 | <property name="p_log" value="%logger"/> |
| 18 | <property name="p_mdc" value="%replace(%replace(%mdc){'\t','\\\\t'}){'\n', '\\\\n'}"/> |
| 19 | <property name="p_msg" value="%replace(%replace(%msg){'\t', '\\\\t'}){'\n','\\\\n'}"/> |
| 20 | <property name="p_exc" value="%replace(%replace(%rootException){'\t', '\\\\t'}){'\n','\\\\n'}"/> |
| 21 | <property name="p_mak" value="%replace(%replace(%marker){'\t', '\\\\t'}){'\n','\\\\n'}"/> |
| 22 | <property name="p_thr" value="%thread"/> |
| 23 | <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"/> |
| 24 | |
| 25 | <property name="logDir" value="/var/log/onap" /> |
| 26 | <property name="debugDir" value="/var/log/onap" /> |
| 27 | |
| 28 | <property name="componentName" value="msb"></property> |
| 29 | <property name="subComponentName" value="msb-eag"></property> |
| 30 | |
| 31 | <property name="errorLogName" value="error" /> |
| 32 | <property name="metricsLogName" value="metrics" /> |
| 33 | <property name="auditLogName" value="audit" /> |
| 34 | <property name="debugLogName" value="debug" /> |
| 35 | |
| 36 | <property name="errorPattern" value="%d{"yyyy-MM-dd'T'HH:mm:ss.SSSXXX", 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" /> |
| 37 | <property name="debugPattern" value="%d{"yyyy-MM-dd'T'HH:mm:ss.SSSXXX", UTC}|%X{RequestId}|%msg%n\t${p_mdc}\t${p_msg}\t${p_exc}\t${p_mak}\t%n" /> |
| 38 | |
| 39 | <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" /> |
| 40 | <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" /> |
| 41 | <property name="logDirectory" value="${logDir}/${componentName}/${subComponentName}" /> |
| 42 | <property name="debugLogDirectory" value="${debugDir}/${componentName}/${subComponentName}" /> |
| 43 | |
Dominik Mizyn | 606d2a9 | 2020-09-08 10:30:14 +0200 | [diff] [blame] | 44 | <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender"> |
| 45 | <encoder> |
| 46 | <pattern>${errorPattern}</pattern> |
| 47 | </encoder> |
| 48 | </appender> |
| 49 | |
Li Zi | c5290dc | 2018-08-06 09:26:27 +0000 | [diff] [blame] | 50 | <appender name="EELFAudit" |
| 51 | class="ch.qos.logback.core.rolling.RollingFileAppender"> |
| 52 | <file>${logDirectory}/${auditLogName}.log</file> |
| 53 | <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> |
| 54 | <fileNamePattern>${logDirectory}/${auditLogName}.log.%d</fileNamePattern> |
| 55 | </rollingPolicy> |
| 56 | <encoder> |
| 57 | <pattern>${auditPattern}</pattern> |
| 58 | </encoder> |
| 59 | </appender> |
guillaume.lambert | 30ec390 | 2021-09-14 12:32:24 +0200 | [diff] [blame] | 60 | |
Li Zi | c5290dc | 2018-08-06 09:26:27 +0000 | [diff] [blame] | 61 | <appender name="asyncEELFAudit" class="ch.qos.logback.classic.AsyncAppender"> |
| 62 | <queueSize>256</queueSize> |
| 63 | <appender-ref ref="EELFAudit" /> |
| 64 | </appender> |
| 65 | |
| 66 | <appender name="EELFMetrics" class="ch.qos.logback.core.rolling.RollingFileAppender"> |
| 67 | <file>${logDirectory}/${metricsLogName}.log</file> |
| 68 | <rollingPolicy |
| 69 | class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> |
| 70 | <fileNamePattern>${logDirectory}/${metricsLogName}.log.%d</fileNamePattern> |
| 71 | </rollingPolicy> |
| 72 | <encoder> |
| 73 | <pattern>${metricPattern}</pattern> |
| 74 | </encoder> |
| 75 | </appender> |
| 76 | |
| 77 | <appender name="asyncEELFMetrics" class="ch.qos.logback.classic.AsyncAppender"> |
| 78 | <queueSize>256</queueSize> |
| 79 | <appender-ref ref="EELFMetrics"/> |
| 80 | </appender> |
| 81 | |
| 82 | <appender name="EELFError" |
| 83 | class="ch.qos.logback.core.rolling.RollingFileAppender"> |
| 84 | <file>${logDirectory}/${errorLogName}.log</file> |
| 85 | <rollingPolicy |
| 86 | class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> |
| 87 | <fileNamePattern>${logDirectory}/${errorLogName}.log.%d</fileNamePattern> |
| 88 | </rollingPolicy> |
| 89 | <filter class="ch.qos.logback.classic.filter.ThresholdFilter"> |
| 90 | <level>INFO</level> |
| 91 | </filter> |
| 92 | <encoder> |
| 93 | <pattern>${errorPattern}</pattern> |
| 94 | </encoder> |
| 95 | </appender> |
| 96 | |
| 97 | <appender name="asyncEELFError" class="ch.qos.logback.classic.AsyncAppender"> |
| 98 | <queueSize>256</queueSize> |
| 99 | <appender-ref ref="EELFError"/> |
| 100 | </appender> |
| 101 | |
| 102 | <appender name="EELFDebug" |
| 103 | class="ch.qos.logback.core.rolling.RollingFileAppender"> |
| 104 | <file>${debugLogDirectory}/${debugLogName}.log</file> |
| 105 | <rollingPolicy |
| 106 | class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> |
| 107 | <fileNamePattern>${debugLogDirectory}/${debugLogName}.log.%d</fileNamePattern> |
| 108 | </rollingPolicy> |
| 109 | <encoder> |
| 110 | <pattern>${debugPattern}</pattern> |
| 111 | </encoder> |
| 112 | </appender> |
| 113 | |
| 114 | <appender name="asyncEELFDebug" class="ch.qos.logback.classic.AsyncAppender"> |
| 115 | <queueSize>256</queueSize> |
| 116 | <appender-ref ref="EELFDebug" /> |
| 117 | <includeCallerData>true</includeCallerData> |
| 118 | </appender> |
| 119 | |
| 120 | <logger name="com.att.eelf.audit" level="info" additivity="false"> |
| 121 | <appender-ref ref="asyncEELFAudit" /> |
| 122 | </logger> |
| 123 | |
| 124 | <logger name="com.att.eelf.metrics" level="info" additivity="false"> |
| 125 | <appender-ref ref="asyncEELFMetrics" /> |
| 126 | </logger> |
| 127 | |
| 128 | <logger name="com.att.eelf.error" level="debug" additivity="false"> |
| 129 | <appender-ref ref="asyncEELFError" /> |
| 130 | </logger> |
guillaume.lambert | 30ec390 | 2021-09-14 12:32:24 +0200 | [diff] [blame] | 131 | |
Li Zi | c5290dc | 2018-08-06 09:26:27 +0000 | [diff] [blame] | 132 | <root level="INFO"> |
| 133 | <appender-ref ref="asyncEELFDebug" /> |
Dominik Mizyn | 606d2a9 | 2020-09-08 10:30:14 +0200 | [diff] [blame] | 134 | <appender-ref ref="STDOUT" /> |
Li Zi | c5290dc | 2018-08-06 09:26:27 +0000 | [diff] [blame] | 135 | </root> |
| 136 | |
| 137 | </configuration> |
| 138 | |