I've got a logback.xml config file as follows:
<?xml version="1.0" encoding="UTF-8"?>
<configuration scan="true" scanPeriod="30 seconds">
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%d{HH:mm:ss,GMT} %-5p [%t] %c{10} %X{hub}/%X{device}/%X{channel} %m%n</pattern>
</encoder>
</appender>
<logger name="org.hibernate" level="WARN"/>
<root level="WARN">
<appender-ref ref="console"/>
</root>
</configuration>
And i am wondering if i am able to load an external appender and logger from another .xml file into this file for use? Any ideas?
I don't want this external appender and logger directly in the main .xml.
Thanks D
Previous link provided by @Spencer Kormos was not working hence updating the link http://logback.qos.ch/manual/configuration.html#fileInclusion so that for future user its readily accessible.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With