logging-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ggreg...@apache.org
Subject svn commit: r1537170 - /logging/log4j/log4j2/trunk/src/site/xdoc/manual/appenders.xml
Date Wed, 30 Oct 2013 16:40:18 GMT
Author: ggregory
Date: Wed Oct 30 16:40:18 2013
New Revision: 1537170

URL: http://svn.apache.org/r1537170
Log:
Add an example for the Composite Triggering Policy.

Modified:
    logging/log4j/log4j2/trunk/src/site/xdoc/manual/appenders.xml

Modified: logging/log4j/log4j2/trunk/src/site/xdoc/manual/appenders.xml
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/src/site/xdoc/manual/appenders.xml?rev=1537170&r1=1537169&r2=1537170&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/src/site/xdoc/manual/appenders.xml (original)
+++ logging/log4j/log4j2/trunk/src/site/xdoc/manual/appenders.xml Wed Oct 30 16:40:18 2013
@@ -2242,6 +2242,16 @@ public class JpaLogEntity extends Abstra
                 any of the configured policies return true. The <code>CompositeTriggeringPolicy</code>
is configured 
                 simply by wrapping other policies in a <code>Policies</code>
element.
               </p>
+              <p>
+                For example, the following XML fragment defines policies that rollover the
log when the JVM starts, 
+                when the log size reaches twenty megabytes, and when the current date no
longer matches the log’s 
+                start date.
+              </p>
+            <pre class="prettyprint linenums"><![CDATA[<Policies>
+  <OnStartupTriggeringPolicy />
+  <SizeBasedTriggeringPolicy size="20 MB" />
+  <TimeBasedTriggeringPolicy />
+</Policies>]]></pre>              
             <h5>OnStartup Triggering Policy</h5>
               <p>
                 The <code>OnStartupTriggeringPolicy</code> policy takes no parameters
and causes a rollover if the log



Mime
View raw message