[jboss-user] [JBoss Seam] - Re: Configuring the Seam Logger to write to disk
c_eric_ray
do-not-reply at jboss.com
Tue Sep 12 20:51:18 EDT 2006
An alternative is to add an appender and a category for your application like so...
| <appender name="YOUR_APP" class="org.jboss.logging.appender.DailyRollingFileAppender">
| <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
| <param name="File" value="${jboss.server.log.dir}/some_filename.log"/>
| <param name="Append" value="false"/>
|
| <!-- Rollover at midnight each day -->
| <param name="DatePattern" value="'.'yyyy-MM-dd"/>
|
| <!-- Rollover at the top of each hour
| <param name="DatePattern" value="'.'yyyy-MM-dd-HH"/>
| -->
|
| <layout class="org.apache.log4j.PatternLayout">
| <!-- The default pattern: Date Priority [Category] Message\n -->
| <param name="ConversionPattern" value="%d %-5p [%c] %m%n"/>
|
| <!-- The full pattern: Date MS Priority [Category] (Thread:NDC) Message\n
| <param name="ConversionPattern" value="%d %-5r %-5p [%c] (%t:%x) %m%n"/>
| -->
| </layout>
| </appender>
|
|
| <category name="com.yourcompany.whatever">
| <priority value="DEBUG"/>
| </category>
|
This tells the appender to log at the DEBUG level all log calls from package level com.yourcompany.whatever.
See this for the official word http://wiki.jboss.org/wiki/Wiki.jsp?page=SeparatingApplicationLogs
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3971155#3971155
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3971155
More information about the jboss-user
mailing list