blob: 7c2725d800a43df55a8b5e6d67a314b34544f7d7 [file] [log] [blame]
Jorge Hernandez9e69cc22017-06-26 08:05:30 -05001<!--
2 ============LICENSE_START=======================================================
3 feature-eelf
4 ================================================================================
5 Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6 ================================================================================
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
10
11 http://www.apache.org/licenses/LICENSE-2.0
12
13 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
Jorge Hernandezae4a9352017-07-18 01:06:39 -050021<configuration scan="true" scanPeriod="60 seconds" debug="false">
Jorge Hernandez9e69cc22017-06-26 08:05:30 -050022
23 <property name="errorLogName" value="error" />
24 <property name="metricsLogName" value="metrics" />
25 <property name="auditLogName" value="audit" />
26 <property name="debugLogName" value="debug" />
27 <property name="networkLogName" value="network" />
28
29 <property name="defaultPattern"
30 value="%X{BeginTimestamp}|%X{EndTimestamp}|%X{RequestId}|%X{ServiceInstanceId}|%thread|%X{ServerName}|%X{ServiceName}|%X{PartnerName}|%X{TargetEntity}|%X{TargetServiceName}|%X{StatusCode}|%X{ResponseCode}|%X{ResponseDescription}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{ElapsedTime}|%X{ServerFQDN}|%X{RemoteHost}|%X{ClassName}||%X{ProcessKey}|%X{TargetVirtualEntity}|%X{CustomField1}|%X{CustomField2}|%X{CustomField3}|%X{CustomField4}|%msg%n" />
31 <property name="defaultMetricPattern"
32 value="%X{BeginTimestamp}|%X{EndTimestamp}|%X{RequestId}|%X{ServiceInstanceId}|%thread|%X{ServerName}|%X{ServiceName}|%X{PartnerName}|%X{TargetEntity}|%X{TargetServiceName}|%X{StatusCode}|%X{ResponseCode}|%X{ResponseDescription}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{ElapsedTime}|%X{ServerFQDN}|%X{RemoteHost}|%X{ClassName}||%X{ProcessKey}|%X{TargetVirtualEntity}|%X{CustomField1}|%X{CustomField2}|%X{CustomField3}|%X{CustomField4}|%msg%n" />
33 <property name="defaultAuditPattern"
34 value="%X{BeginTimestamp}|%X{EndTimestamp}|%X{RequestId}|%X{ServiceInstanceId}|%thread|%X{ServerName}|%X{ServiceName}|%X{PartnerName}|%X{StatusCode}|%X{ResponseCode}|%X{ResponseDescription}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{ElapsedTime}|%X{ServerFQDN}|%X{RemoteHost}|%X{ClassName}||%X{ProcessKey}|%X{CustomField1}|%X{CustomField2}|%X{CustomField3}|%X{CustomField4}|%msg%n" />
35 <property name="defaultErrorPattern"
Jorge Hernandezae4a9352017-07-18 01:06:39 -050036 value="%d{yyyy-MM-dd'T'HH:mm:ss.SSS+00:00, UTC}|%X{RequestId}|%thread|%X{ServiceName}|%X{PartnerName}|%X{TargetEntity}|%X{TargetServiceName}|%X{ErrorCategory}|%X{ErrorCode}|%X{ErrorDesciption}|%msg%replace(%xException){'\n',' - '}%nopex%n" />
37
Jorge Hernandez9e69cc22017-06-26 08:05:30 -050038 <property name="networkPattern" value="[%d|%t]%m%n" />
Jorge Hernandezae4a9352017-07-18 01:06:39 -050039 <property name="debugPattern" value="[%date|%level|%logger{0}|%thread] %replace(%msg){'\n', ' '}%n" />
Jorge Hernandez9e69cc22017-06-26 08:05:30 -050040
41 <property name="logDirectory" value="logs/Policy" />
42 <property name="debugLogDirectory" value="logs/Policy" />
43
44 <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
45 <encoder>
46 <pattern>${defaultPattern}</pattern>
47 </encoder>
48 </appender>
49
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.FixedWindowRollingPolicy">
54 <fileNamePattern>${logDirectory}/${auditLogName}.%i.log.zip
55 </fileNamePattern>
56 <minIndex>1</minIndex>
57 <maxIndex>5</maxIndex>
58 </rollingPolicy>
59 <triggeringPolicy
60 class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
61 <maxFileSize>10MB</maxFileSize>
62 </triggeringPolicy>
63 <encoder>
64 <pattern>${defaultAuditPattern}</pattern>
65 </encoder>
66 </appender>
67
68 <appender name="asyncEELFAudit" class="ch.qos.logback.classic.AsyncAppender">
69 <appender-ref ref="EELFAudit" />
70 </appender>
71
72 <appender name="EELFMetrics"
73 class="ch.qos.logback.core.rolling.RollingFileAppender">
74 <file>${logDirectory}/${metricsLogName}.log</file>
75 <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
76 <fileNamePattern>${logDirectory}/${metricsLogName}.%i.log.zip
77 </fileNamePattern>
78 <minIndex>1</minIndex>
79 <maxIndex>5</maxIndex>
80 </rollingPolicy>
81 <triggeringPolicy
82 class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
83 <maxFileSize>15MB</maxFileSize>
84 </triggeringPolicy>
85 <encoder>
86 <pattern>${defaultMetricPattern}</pattern>
87 </encoder>
88 </appender>
89
90
91 <appender name="asyncEELFMetrics" class="ch.qos.logback.classic.AsyncAppender">
92 <appender-ref ref="EELFMetrics" />
93 </appender>
94
95 <appender name="EELFError"
96 class="ch.qos.logback.core.rolling.RollingFileAppender">
97 <file>${logDirectory}/${errorLogName}.log</file>
98 <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
99 <fileNamePattern>${logDirectory}/${errorLogName}.%i.log.zip
100 </fileNamePattern>
101 <minIndex>1</minIndex>
102 <maxIndex>5</maxIndex>
103 </rollingPolicy>
104 <filter class="ch.qos.logback.classic.filter.ThresholdFilter">
105 <level>ERROR</level>
106 </filter>
107 <triggeringPolicy
108 class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
109 <maxFileSize>20MB</maxFileSize>
110 </triggeringPolicy>
111 <encoder>
112 <pattern>${defaultErrorPattern}</pattern>
113 </encoder>
114 </appender>
115
116 <appender name="asyncEELFError" class="ch.qos.logback.classic.AsyncAppender">
117 <appender-ref ref="EELFError" />
118 </appender>
119
120 <appender name="EELFDebug"
121 class="ch.qos.logback.core.rolling.RollingFileAppender">
122 <file>${debugLogDirectory}/${debugLogName}.log</file>
123 <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
124 <fileNamePattern>${debugLogDirectory}/${debugLogName}.%i.log.zip
125 </fileNamePattern>
126 <minIndex>1</minIndex>
127 <maxIndex>5</maxIndex>
128 </rollingPolicy>
129 <triggeringPolicy
130 class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
131 <maxFileSize>20MB</maxFileSize>
132 </triggeringPolicy>
133 <encoder>
134 <pattern>${debugPattern}</pattern>
135 </encoder>
136 </appender>
137
138 <appender name="asyncEELFDebug" class="ch.qos.logback.classic.AsyncAppender">
139 <appender-ref ref="EELFDebug" />
140 </appender>
141
142 <appender name="NetworkOut" class="ch.qos.logback.core.rolling.RollingFileAppender">
143 <file>${logDirectory}/${networkLogName}.log</file>
144 <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
145 <fileNamePattern>logs/network.log.%i.zip</fileNamePattern>
146 <minIndex>1</minIndex>
147 <maxIndex>5</maxIndex>
148 </rollingPolicy>
149 <triggeringPolicy class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
150 <maxFileSize>15MB</maxFileSize>
151 </triggeringPolicy>
152 <encoder>
153 <pattern>${networkPattern}</pattern>
154 </encoder>
155 </appender>
156
157 <appender name="AsyncNetworkOut" class="ch.qos.logback.classic.AsyncAppender">
158 <appender-ref ref="NetworkOut" />
159 </appender>
160
161 <logger name="com.att.eelf.audit" level="info" additivity="false">
162 <appender-ref ref="asyncEELFAudit" />
163 </logger>
164
165 <logger name="com.att.eelf.metrics" level="info" additivity="false">
166 <appender-ref ref="asyncEELFMetrics" />
167 </logger>
168
169 <logger name="com.att.eelf.error" level="error" additivity="false">
170 <appender-ref ref="asyncEELFError" />
171 </logger>
172
Jorge Hernandezae4a9352017-07-18 01:06:39 -0500173 <logger name="com.att.eelf.debug" level="info">
Jorge Hernandez9e69cc22017-06-26 08:05:30 -0500174 <appender-ref ref="asyncEELFDebug" />
175 </logger>
176
177 <logger name="network" level="INFO" additivity="false">
178 <appender-ref ref="AsyncNetworkOut" />
179 </logger>
180
181 <root level="INFO">
182 <appender-ref ref="asyncEELFDebug" />
183 <appender-ref ref="asyncEELFError" />
184 </root>
185
186</configuration>