Improve CLogger fallback when reaching 100 files in /log folder

Description

At this moment the CLogFile class (used by CLogger) tries to create log files with the name idempiere.[yyyy-mm-dd]_[seq].log in the /log folder

The algorithm just creates 100 files (max seq 99) and then falls back creating a log file in /tmp folder.

Falling back to /tmp is inconvenient as usually this folder is cleared periodically or in some cases on reboot.

So, idea is to implement a better fallback mechanism to use a file name like:
idempiere.[yyyy-mm-dd-HH-MM-SS].log
and still use the /log folder when possible

Environment

None

Activity

Show:
Fixed

Details

Assignee

Reporter

Fix versions

Priority

Created December 30, 2020 at 11:17 AM
Updated March 1, 2021 at 12:17 PM
Resolved December 30, 2020 at 12:30 PM

Flag notifications