This is an automated email from the ASF dual-hosted git repository.

jleroux pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git

commit 57acd94478ccceb0477596f911ccb583360d9074
Author: Jacques Le Roux <jacques.le.r...@les7arts.com>
AuthorDate: Sun Apr 28 08:46:52 2024 +0200

    Improved: Rework the log4j2.xml configuration to limit the number of log 
files generated (OFBIZ-12897)
    
    Changes the log4j2 config to allow 30 rollover ofbiz and 10 error log files.
    We have enough space and it's the same for any OFBIz user now.
    From my experience that can be useful to have a such backup sometimes.
---
 framework/base/config/log4j2.xml | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/framework/base/config/log4j2.xml b/framework/base/config/log4j2.xml
index 25417ebac2..6ce27b8166 100644
--- a/framework/base/config/log4j2.xml
+++ b/framework/base/config/log4j2.xml
@@ -32,8 +32,8 @@ under the License.
        * all log messages of any severity, generated by OFBiz, are logged in 
the ofbiz.log file and in the console
        * all log messages of severity "error" or greater are also logged in 
the error.log file
 
-      Log file ofbiz.log is configured to rollover when it reaches 10MB in 
size, and to keep up to 9 rolled over files.
-      Log file error.log is configured to rollover when it reaches 10MB in 
size, and to keep up to 3 rolled over files.
+      Log file ofbiz.log is configured to rollover when it reaches 10MB in 
size, and to keep up to 30 rolled over files.
+      Log file error.log is configured to rollover when it reaches 10MB in 
size, and to keep up to 10 rolled over files.
 
       The settings in this configuration file can be changed without 
restarting the instance: every 60 seconds the file
       is checked for modifications.
@@ -49,7 +49,7 @@ under the License.
                 <OnStartupTriggeringPolicy/>
                 <SizeBasedTriggeringPolicy size="10 MB"/>
             </Policies>
-            <DefaultRolloverStrategy fileIndex="min" max="9"/>
+            <DefaultRolloverStrategy fileIndex="min" max="30"/>
         </RollingFile>
 
         <RollingFile name="error" fileName="runtime/logs/error.log" 
filePattern="runtime/logs/error.log.%i">
@@ -59,7 +59,7 @@ under the License.
                 <OnStartupTriggeringPolicy/>
                 <SizeBasedTriggeringPolicy size="10 MB"/>
             </Policies>
-            <DefaultRolloverStrategy fileIndex="min" max="3"/>
+            <DefaultRolloverStrategy fileIndex="min" max="10"/>
         </RollingFile>
 
         <Async name="async">

Reply via email to