root / src / log4j.properties
Historique | Voir | Annoter | Télécharger (2,06 ko)
| 1 | 14 | kreverch | # Licensed to the Apache Software Foundation (ASF) under one or more |
|---|---|---|---|
| 2 | 14 | kreverch | # contributor license agreements. See the NOTICE file distributed with |
| 3 | 14 | kreverch | # this work for additional information regarding copyright ownership. |
| 4 | 14 | kreverch | # The ASF licenses this file to You under the Apache License, Version 2.0 |
| 5 | 14 | kreverch | # (the "License"); you may not use this file except in compliance with |
| 6 | 14 | kreverch | # the License. You may obtain a copy of the License at |
| 7 | 14 | kreverch | # |
| 8 | 14 | kreverch | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | 14 | kreverch | # |
| 10 | 14 | kreverch | # Unless required by applicable law or agreed to in writing, software |
| 11 | 14 | kreverch | # distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | 14 | kreverch | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | 14 | kreverch | # See the License for the specific language governing permissions and |
| 14 | 14 | kreverch | # limitations under the License. |
| 15 | 14 | kreverch | |
| 16 | 14 | kreverch | |
| 17 | 14 | kreverch | # An example log4j configuration file that outputs to System.out. The |
| 18 | 14 | kreverch | # output information consists of relative time, log level, thread |
| 19 | 14 | kreverch | # name, logger name, nested diagnostic context and the message in that |
| 20 | 14 | kreverch | # order. |
| 21 | 14 | kreverch | |
| 22 | 14 | kreverch | # For the general syntax of property based configuration files see the |
| 23 | 14 | kreverch | # documenation of org.apache.log4j.PropertyConfigurator. |
| 24 | 14 | kreverch | |
| 25 | 14 | kreverch | log4j.rootLogger=INFO, A1, A2 |
| 26 | 14 | kreverch | log4j.appender.A2.append=false |
| 27 | 14 | kreverch | log4j.appender.A2=org.apache.log4j.RollingFileAppender |
| 28 | 14 | kreverch | log4j.appender.A2.File=${user.home}/gZFS.log
|
| 29 | 14 | kreverch | |
| 30 | 14 | kreverch | # A1 is set to be a ConsoleAppender which outputs to System.out. |
| 31 | 14 | kreverch | log4j.appender.A1=org.apache.log4j.ConsoleAppender |
| 32 | 14 | kreverch | |
| 33 | 14 | kreverch | # A1 uses PatternLayout. |
| 34 | 14 | kreverch | log4j.appender.A1.layout=org.apache.log4j.PatternLayout |
| 35 | 14 | kreverch | log4j.appender.A2.layout=org.apache.log4j.PatternLayout |
| 36 | 14 | kreverch | |
| 37 | 14 | kreverch | # The conversion pattern uses format specifiers. You might want to |
| 38 | 14 | kreverch | # change the pattern an watch the output format change. |
| 39 | 14 | kreverch | log4j.appender.A1.layout.ConversionPattern=%-4r %-5p [%t] %37c %3x - %m%n |
| 40 | 14 | kreverch | log4j.appender.A2.layout.ConversionPattern=%-4r %-5p [%t] %37c %3x - %m%n |
| 41 | 14 | kreverch | |
| 42 | 14 | kreverch | # In this example, we are not really interested in INNER loop or SWAP |
| 43 | 14 | kreverch | # messages. See the effects of uncommenting and changing the levels of |
| 44 | 14 | kreverch | # the following loggers. |
| 45 | 14 | kreverch | # log4j.logger.org.apache.log4j.examples.SortAlgo.INNER=WARN |
| 46 | 14 | kreverch | # log4j.logger.org.apache.log4j.examples.SortAlgo.SWAP=WARN |