add proper logging

This commit is contained in:
Ecorous 2024-06-18 18:08:19 +01:00
parent 8427003d37
commit 21ed28b3a1
Signed by: Ecorous
SSH key fingerprint: SHA256:ni7WK6Ud51dVmDv8DctoqLEr3XXhAI51s6IFMYvJKDM

View file

@ -6,9 +6,18 @@ def environment = System.getenv("ENVIRONMENT") ?: "production"
def defaultLevel = INFO def defaultLevel = INFO
def defaultTarget = ConsoleTarget.SystemErr def defaultTarget = ConsoleTarget.SystemErr
appender("FILE", FileAppender) {
file = "logs_meta.log"
append = true
encoder(PatternLayoutEncoder) {
pattern = "%d{yyyy-MM-dd HH:mm:ss} [%thread] %-5level %logger{35} - %msg%n"
}
}
appender("CONSOLE", ConsoleAppender) { appender("CONSOLE", ConsoleAppender) {
encoder(PatternLayoutEncoder) { encoder(PatternLayoutEncoder) {
pattern = "WAWA:: %boldGreen(%d{yyyy-MM-dd}) %boldYellow(%d{HH:mm:ss}) %gray(|) %highlight(%5level) %gray(|) %boldMagenta(%40.40logger{40}) %gray(|) %msg%n" pattern = "%boldGreen(%d{yyyy-MM-dd}) %boldYellow(%d{HH:mm:ss}) %gray(|) %highlight(%5level) %gray(|) %boldMagenta(%40.40logger{40}) %gray(|) %msg%n"
withJansi = true withJansi = true
} }