| <?xml version="1.0" encoding="UTF-8" ?> |
| <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd"> |
| |
| <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"> |
| <appender name="file" class="org.apache.log4j.RollingFileAppender"> |
| <param name="append" value="false" /> |
| <param name="maxFileSize" value="1MB" /> |
| <param name="maxBackupIndex" value="5" /> |
| <param name="file" value="logs/server.log" /> |
| <layout class="org.apache.log4j.PatternLayout"> |
| <param name="ConversionPattern" |
| value="%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n" /> |
| </layout> |
| </appender> |
| <appender name="console" class="org.apache.log4j.ConsoleAppender"> |
| <param name="Threshold" value="WARN"/> |
| <param name="Target" value="System.out"/> |
| <layout class="org.apache.log4j.PatternLayout"> |
| <param name="ConversionPattern" value="%-5p %c{1} - %m%n"/> |
| </layout> |
| </appender> |
| |
| <root> |
| <priority value="info" /> |
| <appender-ref ref="file" /> |
| <appender-ref ref="console" /> |
| </root> |
| |
| </log4j:configuration> |