econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 1 | <!-- |
| 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 | --> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 20 | <configuration scan="true" scanPeriod="3 seconds" debug="false"> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 21 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 22 | <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" /> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 29 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 30 | <!-- 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}" /> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 33 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 34 | <!-- Example evaluator filter applied against console appender --> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 35 | <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 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 45 | <!-- The EELFAppender is used to record events to the general application |
| 46 | log --> |
| 47 | |
| 48 | |
| 49 | <appender name="Audit" |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 50 | class="ch.qos.logback.core.rolling.RollingFileAppender"> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 51 | <file>${logDirectory}/${auditLog}.log</file> |
| 52 | <filter class="org.onap.dmaap.datarouter.node.eelf.AuditFilter"> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 53 | </filter> |
| 54 | <rollingPolicy |
| 55 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 56 | <fileNamePattern>${logDirectory}/${auditLog}.%i.log.zip |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 57 | </fileNamePattern> |
| 58 | <minIndex>1</minIndex> |
| 59 | <maxIndex>9</maxIndex> |
| 60 | </rollingPolicy> |
| 61 | <triggeringPolicy |
| 62 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy"> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 63 | <maxFileSize>50MB</maxFileSize> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 64 | </triggeringPolicy> |
| 65 | <encoder> |
| 66 | <pattern>${defaultPattern}</pattern> |
| 67 | </encoder> |
| 68 | </appender> |
| 69 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 70 | <appender name="asyncAudit" class="ch.qos.logback.classic.AsyncAppender"> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 71 | <queueSize>256</queueSize> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 72 | <appender-ref ref="Audit" /> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 73 | </appender> |
| 74 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 75 | <!-- ============================================================================ --> |
| 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"> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 81 | </filter> |
| 82 | <rollingPolicy |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 83 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> |
| 84 | <fileNamePattern>${logDirectory}/${metricsLog}.%i.log.zip |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 85 | </fileNamePattern> |
| 86 | <minIndex>1</minIndex> |
| 87 | <maxIndex>9</maxIndex> |
| 88 | </rollingPolicy> |
| 89 | <triggeringPolicy |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 90 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy"> |
| 91 | <maxFileSize>50MB</maxFileSize> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 92 | </triggeringPolicy> |
| 93 | <encoder> |
| 94 | <pattern>${defaultPattern}</pattern> |
| 95 | </encoder> |
| 96 | </appender> |
| 97 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 98 | <appender name="asyncMetrics" class="ch.qos.logback.classic.AsyncAppender"> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 99 | <queueSize>256</queueSize> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 100 | <appender-ref ref="Metrics" /> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 101 | </appender> |
| 102 | |
| 103 | <!-- ============================================================================ --> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 104 | |
| 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" |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 135 | class="ch.qos.logback.core.rolling.RollingFileAppender"> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 136 | <file>${logDirectory}/${errorLog}.log</file> |
| 137 | <filter class="org.onap.dmaap.datarouter.node.eelf.ErrorFilter"> |
| 138 | </filter> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 139 | <rollingPolicy |
| 140 | class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 141 | <fileNamePattern>${logDirectory}/${errorLog}.%i.log.zip |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 142 | </fileNamePattern> |
| 143 | <minIndex>1</minIndex> |
| 144 | <maxIndex>9</maxIndex> |
| 145 | </rollingPolicy> |
| 146 | <triggeringPolicy |
| 147 | class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy"> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 148 | <maxFileSize>50MB</maxFileSize> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 149 | </triggeringPolicy> |
| 150 | <encoder> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 151 | <pattern>${defaultPattern}</pattern> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 152 | </encoder> |
| 153 | </appender> |
| 154 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 155 | <appender name="asyncError" class="ch.qos.logback.classic.AsyncAppender"> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 156 | <queueSize>256</queueSize> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 157 | <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" /> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 184 | <includeCallerData>true</includeCallerData> |
| 185 | </appender> |
| 186 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 187 | <!-- ============================================================================ --> |
| 188 | |
| 189 | |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 190 | <!-- ============================================================================ --> |
| 191 | <!-- EELF loggers --> |
| 192 | <!-- ============================================================================ --> |
| 193 | <logger name="com.att.eelf" level="info" additivity="false"> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 194 | <appender-ref ref="asyncAudit" /> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 195 | </logger> |
| 196 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 197 | <logger name="com.att.eelf" additivity="false"> |
| 198 | <appender-ref ref="asyncMetrics" /> |
| 199 | </logger> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 200 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 201 | <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 | |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 213 | |
efiacor | 2123fec | 2022-12-09 13:40:55 +0000 | [diff] [blame] | 214 | <root level="{{.Values.logLevel}}"> |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 215 | <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 Mizyn | 3e54d4e | 2020-09-03 11:04:44 +0200 | [diff] [blame] | 220 | <appender-ref ref="STDOUT" /> |
econwar | 378cf19 | 2019-01-08 16:19:59 +0000 | [diff] [blame] | 221 | </root> |
| 222 | |
efiacor | 7b9a087 | 2019-08-28 21:20:22 +0000 | [diff] [blame] | 223 | </configuration> |