DailyRollingFileAppender
The daily rolling file appender rotates the log file every day. You can use the parameters provided here to perform the same.
When the output file is rolled it is given a name consisting
of the base name plus a date pattern string (for example, filename.yyyy-mm-dd.)
Parameters are:
- File Path
- Specify the path name for the base log file. The default value is empty.
- Append to file
- Check this box to append to the file when the log is initialized, cleared to overwrite. The default value is cleared.
- Date Pattern
- Specifies the Date pattern that logfile names are suffixed with,
and which controls when rollover occurs (i.e. when the filename changes.)
You can select from the following pre-defined values or specify your
own:
- .'yyyy-MM
- '.'yyyy-MM-dd
- '.'yyyy-MM-dd-HH
- '.'yyyy-MM-dd-HH-mm
- '.'dd-MM-yyyy
- Layout
- Select a Layout for the Appender. Available values are:
- Pattern (the default)
- Simple
- HTML
- XML
- Pattern
- Specifies the substitution mask that defines log formatting. Only
used when Layout is Pattern. You can select from the following pre-defined
patterns, or specify your own:
- %d{ISO8601} %-5p [%c] - %m%n (the default)
- %d{HH:mm:ss} %p [%t] - %m%n
- %p [%t] %c %d{HH:mm:ss,SSS} - %m%n
- Character Encoding
- Specifies the output character encoding (for example, UTF-8); the default value is empty.