[logback-user] A new ReconfigureOnChangeFilter at each reload of the config file

Ceki Gulcu ceki at qos.ch
Wed Jul 20 23:10:31 CEST 2011

On 20.07.2011 22:56, dunand wrote:
> Ceki Gulcu wrote:
>> By the way, what is the value of
> I'm using : "C:\tmp\logging\logback.xml"
> I also tried "\\server\x\y\logback.xml" with the same output.

OK. The configuration file is external to your application. You can 
package logback.xml within your web-app and include 
C:\tmp\logging\logback.xml from logback.xml:

Example logback.xml file:

<configuration scan="true">
   <include file="C:\tmp\logging\logback.xml"/>

The included file must list its contents within <included> element. See 
[1]. The file C:\tmp\logging\logback.xml becomes:

   <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">

   <root level="debug">
     <appender-ref ref="STDOUT" />

With this inclusion trick you no longer need initialization code in 

By the way, another alternative is the logback.configurationFile system 
property. See [2] for more details.

[1] http://logback.qos.ch/manual/configuration.html#fileInclusion
[2] http://logback.qos.ch/manual/configuration.html#configFileProperty

More information about the Logback-user mailing list