Skip to content

Commit

Permalink
Upped grisu dep version. Changed log4j to xml based config and added …
Browse files Browse the repository at this point in the history
…gzipping of archive logs.
  • Loading branch information
Markus Binsteiner committed Nov 11, 2010
1 parent 48d03cb commit 0541f93
Show file tree
Hide file tree
Showing 4 changed files with 58 additions and 16 deletions.
7 changes: 7 additions & 0 deletions backend-modules/enunciate-backend/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,13 @@
<!-- <scope>compile</scope> -->
<!-- </dependency> -->

<dependency>
<groupId>log4j</groupId>
<artifactId>apache-log4j-extras</artifactId>
<version>1.0</version>
<type>jar</type>
<scope>compile</scope>
</dependency>
</dependencies>

<build>
Expand Down

This file was deleted.

50 changes: 50 additions & 0 deletions backend-modules/enunciate-backend/src/main/resources/log4j.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">

<!-- Note that this file is refreshed by the server every 60seconds, as specified in web.xml -->

<log4j:configuration debug="true">

<appender name="ROLL" class="org.apache.log4j.rolling.RollingFileAppender">
<!-- The active file to log to -->
<param name="file" value="/var/log/grisu/grisu.log" />
<param name="append" value="true" />
<param name="encoding" value="UTF-8" />

<rollingPolicy class="org.apache.log4j.rolling.TimeBasedRollingPolicy">
<!-- The file to roll to, this is a fairly intelligent parameter, if the file
ends in .gz, it gzips it, based on the date stamp it rolls at that time,
default is yyyy-MM-dd, (rolls at midnight)
See: http://logging.apache.org/log4j/companions/extras/apidocs/org/apache/log4j/rolling/TimeBasedRollingPolicy.html -->
<param name="FileNamePattern" value="/var/log/grisu/grisu.%d.log.gz" />
</rollingPolicy>

<layout class="org.apache.log4j.PatternLayout">
<!-- The log message pattern -->
<param name="ConversionPattern" value="%5p %d{ISO8601} [%t][%x] %c - %m%n" />
</layout>
</appender>

<!-- Loggers to filter out various class paths -->

<logger name="org.hibernate.engine.loading.LoadContexts" additivity="false">
<level value="error"/>
<appender-ref ref="ROLL" />
</logger>

<!-- Debugging loggers -->

<!-- Uncomment to enable debug on calpoly code only -->

<logger name="org.vpac.grisu">
<level value="debug"/>
<appender-ref ref="ROLL" />
</logger>


<root>
<priority value="info" />
<appender-ref ref="ROLL" />
</root>

</log4j:configuration>
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<url>http://maven.apache.org</url>

<properties>
<grisu.dependency.version>0.3-beta3</grisu.dependency.version>
<grisu.dependency.version>0.3-beta4-SNAPSHOT</grisu.dependency.version>
</properties>

<scm>
Expand Down

0 comments on commit 0541f93

Please sign in to comment.