I configurated my Wildfly-Swarm Logging using the project-defaults.yml
.
The Logging works well in regards to File-output and Pattern.
However, the Log-level gets ignored and is set to INFO all the time.
I went with the "explanation" on https://reference.wildfly-swarm.io/fractions/logging.html however it's not working.
My project-defaults.yml
is
swarm:
logging:
pattern-formatters:
NORMAL:
pattern: "%p [%c] %s%e%n"
EXCEPTION:
pattern: "%p [%c.%m] %s%e%n"
periodic-rotating-file-handlers:
DEBUGLOG:
file:
path: logs/shaker.log
suffix: .yyyy-MM-dd
named-formatter: NORMAL
level: DEBUG
EXCEPTIONLOG:
file:
path: logs/exception.log
suffix: .yyyy-MM-dd
named-formatter: EXCEPTION
level: WARN
root-logger:
handlers:
- CONSOLE
- DEBUGLOG
- EXCEPTIONLOG
In both log-files and in the console the log is set to INFO. I've tried adding
logging:
loggers:
de.mypackage:
level: DEBUG
But it only changes the log level of console. Any idea?
Nevermind, it turns out I've misspelled de.mypackage
.
Setting
logging:
loggers:
de.mypackage:
level: DEBUG
sets the level to DEBUG in all logs under de.mypackage
.