Logging (logback-spring.xml)
Easit Process Runner uses Spring Boots Logback Extension for its logging. This file (logback-spring.xml) holds all configuration needed for that extension and here we can, for example, set the number of days log files should be saved, the name of the log file, total size of "log archive" and more.
You can change / update the settings in this file "on the fly", no restart of application need, as the application looks for changes each 60 seconds.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
|
Settings of interest
LOGS
Path to where the logs for EPR will be written. This path can be relative, by starting the path with ./, or absolute, by starting the path with driveletter://. When starting with ./ the path is relative to catalina.base, meaning the tomcat directory in the instance installation directory.
FILE_NAME
Name of the log file. .log will be appended to this value and when logs a rolled todays date will also be appended to the value.
- Today's log = FILE_NAME.log
- Yesterdays log = FILE_NAME.YesterdaysDate.log
LOG_TOTAL_SIZE_CAP
This value controls the total size of all archive log files. Oldest archives are deleted asynchronously when the total size cap is exceeded. The totalSizeCap property requires maxHistory property to be set as well. Moreover, the "max history" restriction is always applied first and the "total size cap" restriction applied second.
LOG_MAX_HISTORY
This value controls the maximum number of archive files to keep, asynchronously deleting older files. For example, we start each line with todays date (%d{yyyy-MM-dd}) and the timestamp (%d{HH:mm:ss.SSS}) and we separate each "column" in the log file with ' - '.
LOG_PATTERN_FILE
This value specifies how each message from the application is outputted to the log.
Further reading
You can find more information about logging at Spring documentation - Logging and LogBack Manual.