Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 1 | ################################################################################ |
| 2 | # |
| 3 | # Licensed to the Apache Software Foundation (ASF) under one or more |
| 4 | # contributor license agreements. See the NOTICE file distributed with |
| 5 | # this work for additional information regarding copyright ownership. |
| 6 | # The ASF licenses this file to You under the Apache License, Version 2.0 |
| 7 | # (the "License"); you may not use this file except in compliance with |
| 8 | # the License. You may obtain a copy of the License at |
| 9 | # |
| 10 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | # |
| 12 | # Unless required by applicable law or agreed to in writing, software |
| 13 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 15 | # See the License for the specific language governing permissions and |
| 16 | # limitations under the License. |
| 17 | # |
| 18 | ################################################################################ |
| 19 | |
| 20 | # Root logger |
| 21 | log4j.rootLogger=INFO, async, osgi:* |
| 22 | log4j.throwableRenderer=org.apache.log4j.OsgiThrowableRenderer |
| 23 | |
| 24 | maxFileSize=100MB |
| 25 | maxBackupIndex=20 |
| 26 | logDir=/var/log/onap |
| 27 | componentName=appc |
| 28 | logDirectory=${logDir}/${componentName} |
| 29 | karafLogName=karaf |
| 30 | errorLogName=error |
| 31 | metricsLogName=metrics |
| 32 | auditLogName=audit |
| 33 | debugLogName=debug |
| 34 | |
| 35 | |
| 36 | # CONSOLE appender not used by default |
| 37 | log4j.appender.stdout=org.apache.log4j.ConsoleAppender |
| 38 | log4j.appender.stdout.layout=org.apache.log4j.PatternLayout |
| 39 | log4j.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 |
| 40 | |
| 41 | # Async appender forwarding to file appender |
| 42 | log4j.appender.async=org.apache.log4j.AsyncAppender |
| 43 | log4j.appender.async.appenders=out |
| 44 | |
| 45 | # File appender |
| 46 | log4j.appender.out=org.apache.log4j.RollingFileAppender |
| 47 | log4j.appender.out.layout=org.apache.log4j.xml.XMLLayout |
| 48 | log4j.appender.out.layout.Properties=true |
| 49 | log4j.appender.out.file=${logDirectory}/${karafLogName}.log |
| 50 | log4j.appender.out.append=true |
| 51 | log4j.appender.out.maxFileSize=${maxFileSize} |
| 52 | log4j.appender.out.maxBackupIndex=${maxBackupIndex} |
| 53 | |
| 54 | # Sift appender |
| 55 | log4j.appender.sift=org.apache.log4j.sift.MDCSiftingAppender |
| 56 | log4j.appender.sift.key=bundle.name |
| 57 | log4j.appender.sift.default=karaf |
| 58 | log4j.appender.sift.appender=org.apache.log4j.RollingFileAppender |
| 59 | log4j.appender.sift.appender.layout=org.apache.log4j.xml.XMLLayout |
| 60 | log4j.appender.sift.appender.layout.Properties=true |
| 61 | log4j.appender.sift.appender.file=${logDirectory}/$\\{bundle.name\\}.log |
| 62 | log4j.appender.sift.appender.append=true |
| 63 | |
| 64 | |
| 65 | |
| 66 | log4j.category.org.opendaylight.controller.netconf.persist.impl.osgi.ConfigPusherImpl=DEBUG |
| 67 | log4j.category.org.opendaylight.controller.netconf.persist.impl.osgi.ConfigPersisterActivator=DEBUG |
| 68 | |
| 69 | |
| 70 | #ECOMP Debug appender |
| 71 | log4j.appender.debug=org.apache.log4j.RollingFileAppender |
| 72 | log4j.appender.debug.key=bundle.name |
| 73 | log4j.appender.debug.default=karaf |
| 74 | log4j.appender.debug.appName=EELFDebug |
| 75 | log4j.appender.debug.layout=org.apache.log4j.xml.XMLLayout |
| 76 | log4j.appender.debug.layout.Properties=true |
| 77 | log4j.appender.debug.file=${logDirectory}/${debugLogName}.log |
| 78 | log4j.appender.debug.append=true |
| 79 | log4j.appender.debug.maxFileSize=${maxFileSize} |
| 80 | log4j.appender.debug.maxBackupIndex=${maxBackupIndex} |
| 81 | #log4j.appender.debug.filter.f1=org.apache.log4j.varia.LevelRangeFilter |
| 82 | #log4j.appender.debug.filter.f1.LevelMax=WARN |
| 83 | #log4j.appender.debug.filter.f1.LevelMin=TRACE |
| 84 | |
| 85 | |
| 86 | #Error appender |
| 87 | log4j.appender.error=org.apache.log4j.RollingFileAppender |
| 88 | log4j.appender.error.appName=EELFError |
| 89 | log4j.appender.error.File=${logDirectory}/${errorLogName}.log |
| 90 | log4j.appender.error.Threshold=ERROR |
| 91 | log4j.appender.error.maxFileSize=${maxFileSize} |
| 92 | log4j.appender.error.maxBackupIndex=${maxBackupIndex} |
| 93 | log4j.appender.error.layout=org.apache.log4j.xml.XMLLayout |
| 94 | log4j.appender.error.layout.Properties=true |
| 95 | |
| 96 | #Metrics appender |
| 97 | log4j.appender.metric=org.apache.log4j.RollingFileAppender |
| 98 | log4j.appender.metric.appName=EELFMetrics |
| 99 | log4j.appender.metric.File=${logDirectory}/${metricsLogName}.log |
| 100 | log4j.appender.metric.maxFileSize=${maxFileSize} |
| 101 | log4j.appender.metric.maxBackupIndex=${maxBackupIndex} |
| 102 | log4j.appender.metric.layout=org.apache.log4j.xml.XMLLayout |
| 103 | log4j.appender.metric.layout.Properties=true |
| 104 | |
| 105 | #Audit appender |
| 106 | log4j.appender.audit=org.apache.log4j.RollingFileAppender |
| 107 | log4j.appender.audit.appName=EELFAudit |
| 108 | log4j.appender.audit.File=${logDirectory}/${auditLogName}.log |
| 109 | log4j.appender.audit.maxFileSize=${maxFileSize} |
| 110 | log4j.appender.audit.maxBackupIndex=${maxBackupIndex} |
| 111 | log4j.appender.audit.layout=org.apache.log4j.xml.XMLLayout |
| 112 | log4j.appender.audit.layout.Properties=true |
| 113 | |
| 114 | #Loggers |
| 115 | #Routing of all messages from root logger |
| 116 | log4j.logger.com.att=TRACE, debug, error |
| 117 | #Store to the same log file messages from upper level appender or not |
| 118 | log4j.additivity.com.att=false |
| 119 | |
| 120 | #EELFManager loggers |
| 121 | #EELF parent logger |
| 122 | log4j.logger.com.att.eelf=TRACE, debug |
| 123 | log4j.additivity.com.att.eelf=false |
| 124 | |
| 125 | #Audit logger routing |
| 126 | log4j.logger.com.att.eelf.audit=DEBUG, audit |
| 127 | log4j.additivity.com.att.eelf.audit=false |
| 128 | |
| 129 | #Metric logger routing |
| 130 | log4j.logger.com.att.eelf.metrics=DEBUG, metric |
| 131 | log4j.additivity.com.att.eelf.metrics=false |
| 132 | |
| 133 | #Performance logger routing |
| 134 | log4j.logger.com.att.eelf.perf=DEBUG, metric |
| 135 | log4j.additivity.com.att.eelf.perf=false |
| 136 | |
| 137 | #Server logger routing |
| 138 | log4j.logger.com.att.eelf.server=DEBUG, debug |
| 139 | log4j.additivity.com.att.eelf.server=false |
| 140 | |
| 141 | #Policy logger routing |
| 142 | log4j.logger.com.att.eelf.policy=DEBUG, debug |
| 143 | log4j.additivity.com.att.eelf.policy=false |
| 144 | |
| 145 | #Error logger routing |
| 146 | log4j.logger.com.att.eelf.error=DEBUG, error |
| 147 | log4j.additivity.com.att.eelf.error=false |
| 148 | |
| 149 | #Debug logger routing |
| 150 | log4j.logger.com.att.eelf.debug=DEBUG, debug |
| 151 | log4j.additivity.com.att.eelf.debug=false |