[logback-user] logback config scan doesn't detect changes in included files

ceki ceki at qos.ch
Sun May 5 22:40:10 CEST 2013


<configuration debug="true"  ....> is your friend.

On 05.05.2013 19:25, Richard Sand wrote:
> Hi all – I’m wondering if this is expected behavior. I’ve a web
> application war file with a minimal logback.xml file in its
> WEB-INF/classes folder, which then uses a JNDI env variable to pull in a
> config file that is external to the application. This greatly
> facilitates deployment because I can override the env variable when I
> deploy the war (e.g. in Tomcat, a context.xml file) and specify the
> external location of the file, allowing me to deploy the war unchanged
> on different platforms and environments.
>
> But… I was hoping that having “scan=true” in the logback.xml file would
> allow me to alter the runtime logback configuration without restarting
> the context, but it doesn’t seem to be working.
>
> My logback.xml file:
>
> <configuration scan="true">
>
>    <insertFromJNDI env-entry-name="java:comp/env/appHome" as="appHome" />
>
>    <include file="${appHome}/conf/logback-app.xml"/>
>
>    <contextListener
> class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
>
> </configuration>
>
> Is this a bug or a known/accepted limitation of using scan=true?
>
> Thanks!
>
> Richard Sand | Managing Director
> PO Box 91824 | Austin | Texas 78709-1824 | USA
> Office: +1 888 612 8820 ext 02 | Fax: +1 866 304 3754
> Mobile: +1 267 984 3651
>
> logo - small
>
>


-- 
Ceki
65% of statistics are made up on the spot


More information about the Logback-user mailing list