MS-12645: add file appender in logback config#152
MS-12645: add file appender in logback config#152damienlibouton wants to merge 2 commits intoicure:mainfrom
Conversation
|
Hey Damien 👋 |
|
Hello Clément, Thank you for your review ! To enable a conditional activation, I need to update the Logback dependency to aversion > 1.5.24 (currently 1.5.18). However, it seems there is a conflict with the Logback version in kmap, or I might be missing something... In short, I'm stuck with this solution ! I also tried activating it using a specific spring profile. To do this, I had to rename the logback.xml to logback-spring.xml to access the spring profile values. However, after renaming the file, for some reason, Logback could no longer find the configuration xml, and I couldn’t figure out why.... My other proposal is to add the Janino dependency to enable the use of if conditions in the xml configuration file. Let me know if this approach is acceptable to you. |
The idea is to have the possibility to log the application server in files.
Then we can use the parameter
-Dlogging.file.name="/your/path/to/app.log"to expose the logs in a file when starting the fatjar.