forked from Evolveum/midpoint
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
OpenDataNode/open-data-node#257 - Evolveum#10 - logrotation and disab…
…le logging into stdout
- Loading branch information
Jan Marcek
committed
Jun 3, 2016
1 parent
c4f0fb3
commit 23ead65
Showing
2 changed files
with
76 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
/var/log/odn-midpoint/* { | ||
copytruncate | ||
weekly | ||
rotate 52 | ||
compress | ||
missingok | ||
create 640 odn-midpoint nogroup | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
~ Copyright (c) 2010-2013 Evolveum | ||
~ | ||
~ Licensed under the Apache License, Version 2.0 (the "License"); | ||
~ you may not use this file except in compliance with the License. | ||
~ You may obtain a copy of the License at | ||
~ | ||
~ http://www.apache.org/licenses/LICENSE-2.0 | ||
~ | ||
~ Unless required by applicable law or agreed to in writing, software | ||
~ distributed under the License is distributed on an "AS IS" BASIS, | ||
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
~ See the License for the specific language governing permissions and | ||
~ limitations under the License. | ||
--> | ||
|
||
<configuration> | ||
<appender name="IDM_LOG" class="ch.qos.logback.core.rolling.RollingFileAppender"> | ||
<!--See http://logback.qos.ch/manual/appenders.html#RollingFileAppender--> | ||
<!--and http://logback.qos.ch/manual/appenders.html#TimeBasedRollingPolicy--> | ||
<!--for further documentation--> | ||
<Append>true</Append> | ||
<File>${catalina.base}/logs/idm.log</File> | ||
<encoder> | ||
<pattern>%date [%X{subsystem}] [%thread] %level \(%logger\): %msg%n</pattern> | ||
</encoder> | ||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> | ||
<fileNamePattern>${catalina.base}/logs/idm-%d{yyyy-MM-dd}.%i.log</fileNamePattern> | ||
<timeBasedFileNamingAndTriggeringPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP"> | ||
<maxFileSize>100MB</maxFileSize> | ||
</timeBasedFileNamingAndTriggeringPolicy> | ||
<maxHistory>10</maxHistory> | ||
<cleanHistoryOnStart>true</cleanHistoryOnStart> | ||
</rollingPolicy> | ||
</appender> | ||
|
||
<!-- Appender for profiling purposes --> | ||
<appender name="IDM-PROFILE_LOG" class="ch.qos.logback.core.rolling.RollingFileAppender"> | ||
<!--See http://logback.qos.ch/manual/appenders.html#RollingFileAppender--> | ||
<!--and http://logback.qos.ch/manual/appenders.html#TimeBasedRollingPolicy--> | ||
<!--for further documentation--> | ||
<Append>true</Append> | ||
<File>${catalina.base}/logs/idm-profile.log</File> | ||
<encoder> | ||
<pattern>%date %level: %msg%n</pattern> | ||
</encoder> | ||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> | ||
<fileNamePattern>${catalina.base}/logs/idm-profile-%d{yyyy-MM-dd}.%i.log</fileNamePattern> | ||
<timeBasedFileNamingAndTriggeringPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP"> | ||
<maxFileSize>100MB</maxFileSize> | ||
</timeBasedFileNamingAndTriggeringPolicy> | ||
<maxHistory>10</maxHistory> | ||
</rollingPolicy> | ||
</appender> | ||
<!-- Appender for profiling purposes --> | ||
|
||
<logger name="org.hibernate.engine.jdbc.spi.SqlExceptionHelper" level="OFF"/> | ||
<logger name="org.hibernate.engine.jdbc.batch.internal.BatchingBatch" level="OFF"/> | ||
<logger name="PROFILING" level="INFO"/> | ||
<logger name="com.evolveum.midpoint" level="WARN" /> | ||
<logger name="com.evolveum.midpoint.web.util.MidPointProfilingServletFilter" level="TRACE"> | ||
<appender-ref ref="IDM-PROFILE_LOG"/> | ||
</logger> | ||
<root level="WARN"> | ||
<appender-ref ref="IDM_LOG"/> | ||
</root> | ||
</configuration> |