blob: 8e1160ec6b919942abce5e9038abe9ba51714232 [file] [log] [blame]
Mukul2b4e7532018-08-03 10:41:29 +00001# Modifications Copyright © 2018 AT&T, Amdocs, Bell Canada Intellectual Property. All rights reserved.
Itay Hasside2da86d2017-08-24 12:54:42 +00002################################################################################
3#
4# Licensed to the Apache Software Foundation (ASF) under one or more
5# contributor license agreements. See the NOTICE file distributed with
6# this work for additional information regarding copyright ownership.
7# The ASF licenses this file to You under the Apache License, Version 2.0
8# (the "License"); you may not use this file except in compliance with
9# the License. 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#
19################################################################################
20
21# Root logger
22log4j.rootLogger=INFO, async, osgi:*
23log4j.throwableRenderer=org.apache.log4j.OsgiThrowableRenderer
24
25maxFileSize=100MB
26maxBackupIndex=20
27logDir=/var/log/onap
28componentName=appc
29logDirectory=${logDir}/${componentName}
30karafLogName=karaf
31errorLogName=error
32metricsLogName=metrics
33auditLogName=audit
34debugLogName=debug
35
36
37# CONSOLE appender not used by default
38log4j.appender.stdout=org.apache.log4j.ConsoleAppender
39log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
40log4j.appender.stdout.layout.ConversionPattern=%d{yyyy-MM-dd'T'HH:mm:ss.SSS}\t%-16.16t\t%-5.5p\t%c{36}\t%X{bundle.id} - %X{bundle.name} - %X{bundle.version}\t%m%n
41
42# Async appender forwarding to file appender
43log4j.appender.async=org.apache.log4j.AsyncAppender
44log4j.appender.async.appenders=out
45
46# File appender
47log4j.appender.out=org.apache.log4j.RollingFileAppender
48log4j.appender.out.layout=org.apache.log4j.xml.XMLLayout
49log4j.appender.out.layout.Properties=true
50log4j.appender.out.file=${logDirectory}/${karafLogName}.log
51log4j.appender.out.append=true
52log4j.appender.out.maxFileSize=${maxFileSize}
53log4j.appender.out.maxBackupIndex=${maxBackupIndex}
54
55# Sift appender
56log4j.appender.sift=org.apache.log4j.sift.MDCSiftingAppender
57log4j.appender.sift.key=bundle.name
58log4j.appender.sift.default=karaf
59log4j.appender.sift.appender=org.apache.log4j.RollingFileAppender
60log4j.appender.sift.appender.layout=org.apache.log4j.xml.XMLLayout
61log4j.appender.sift.appender.layout.Properties=true
62log4j.appender.sift.appender.file=${logDirectory}/$\\{bundle.name\\}.log
63log4j.appender.sift.appender.append=true
64
65
66
67log4j.category.org.opendaylight.controller.netconf.persist.impl.osgi.ConfigPusherImpl=DEBUG
68log4j.category.org.opendaylight.controller.netconf.persist.impl.osgi.ConfigPersisterActivator=DEBUG
69
70
71#ECOMP Debug appender
72log4j.appender.debug=org.apache.log4j.RollingFileAppender
73log4j.appender.debug.key=bundle.name
74log4j.appender.debug.default=karaf
75log4j.appender.debug.appName=EELFDebug
76log4j.appender.debug.layout=org.apache.log4j.xml.XMLLayout
77log4j.appender.debug.layout.Properties=true
78log4j.appender.debug.file=${logDirectory}/${debugLogName}.log
79log4j.appender.debug.append=true
80log4j.appender.debug.maxFileSize=${maxFileSize}
81log4j.appender.debug.maxBackupIndex=${maxBackupIndex}
82#log4j.appender.debug.filter.f1=org.apache.log4j.varia.LevelRangeFilter
83#log4j.appender.debug.filter.f1.LevelMax=WARN
84#log4j.appender.debug.filter.f1.LevelMin=TRACE
85
86
87#Error appender
88log4j.appender.error=org.apache.log4j.RollingFileAppender
89log4j.appender.error.appName=EELFError
90log4j.appender.error.File=${logDirectory}/${errorLogName}.log
91log4j.appender.error.Threshold=ERROR
92log4j.appender.error.maxFileSize=${maxFileSize}
93log4j.appender.error.maxBackupIndex=${maxBackupIndex}
94log4j.appender.error.layout=org.apache.log4j.xml.XMLLayout
95log4j.appender.error.layout.Properties=true
96
97#Metrics appender
98log4j.appender.metric=org.apache.log4j.RollingFileAppender
99log4j.appender.metric.appName=EELFMetrics
100log4j.appender.metric.File=${logDirectory}/${metricsLogName}.log
101log4j.appender.metric.maxFileSize=${maxFileSize}
102log4j.appender.metric.maxBackupIndex=${maxBackupIndex}
103log4j.appender.metric.layout=org.apache.log4j.xml.XMLLayout
104log4j.appender.metric.layout.Properties=true
105
106#Audit appender
107log4j.appender.audit=org.apache.log4j.RollingFileAppender
108log4j.appender.audit.appName=EELFAudit
109log4j.appender.audit.File=${logDirectory}/${auditLogName}.log
110log4j.appender.audit.maxFileSize=${maxFileSize}
111log4j.appender.audit.maxBackupIndex=${maxBackupIndex}
112log4j.appender.audit.layout=org.apache.log4j.xml.XMLLayout
113log4j.appender.audit.layout.Properties=true
114
115#Loggers
116#Routing of all messages from root logger
117log4j.logger.com.att=TRACE, debug, error
118#Store to the same log file messages from upper level appender or not
119log4j.additivity.com.att=false
120
121#EELFManager loggers
122#EELF parent logger
123log4j.logger.com.att.eelf=TRACE, debug
124log4j.additivity.com.att.eelf=false
125
126#Audit logger routing
127log4j.logger.com.att.eelf.audit=DEBUG, audit
128log4j.additivity.com.att.eelf.audit=false
129
130#Metric logger routing
131log4j.logger.com.att.eelf.metrics=DEBUG, metric
132log4j.additivity.com.att.eelf.metrics=false
133
134#Performance logger routing
135log4j.logger.com.att.eelf.perf=DEBUG, metric
136log4j.additivity.com.att.eelf.perf=false
137
138#Server logger routing
139log4j.logger.com.att.eelf.server=DEBUG, debug
140log4j.additivity.com.att.eelf.server=false
141
142#Policy logger routing
143log4j.logger.com.att.eelf.policy=DEBUG, debug
144log4j.additivity.com.att.eelf.policy=false
145
146#Error logger routing
147log4j.logger.com.att.eelf.error=DEBUG, error
148log4j.additivity.com.att.eelf.error=false
149
150#Debug logger routing
151log4j.logger.com.att.eelf.debug=DEBUG, debug
152log4j.additivity.com.att.eelf.debug=false