[logback-user] Shutting down async appenders, when using logback through slf4j

Mads Bondo Dydensborg mbd at dbc.dk
Thu Jun 13 17:17:08 CEST 2013


Thank you!

But .. that anchor does not appear to be present in the text? 

Also, can this be done from the config file? Because the app only knows slf4j ... :-/

Mvh

Mads

Torsdag 13 juni 2013 16:42:19 skrev Ceki Gülcü:
> You need to shutdown logback when redeploying your app. See
> 
>    http://logback.qos.ch/manual/configuration.html#stopContext
> 
> Let us know if this helps,
> 
> On 6/13/2013 1:21 PM, Mads Bondo Dydensborg wrote:
> > Hi all
> >
> > I have a feeling that this is a FAQ, but my google-foo failed me.
> >
> > We provide an application that uses slf4j. The users configure it, in
> > logback.xml, to use, among other things, an async appender.
> >
> > Tomcat complains about this, when redeploying or shutting down:
> >
> > SEVERE: The web application [/openformat] appears to have started a
> > thread named [AsyncAppender-Worker-Thread-2] but has failed to stop it.
> > This is very likely to create a memory leak.
> >
> > I found this issue/request:
> > http://bugzilla.slf4j.org/show_bug.cgi?id=201 (Need ability to shutdown
> > loggers and flush appenders), but it does not seem that this request has
> > been honored.
> >
> > So, what is the recommended way to solve this? We would like to not
> > hardcode the app to use logback (as it could potentially be used with
> > log4j), but there seems to be no way to stop an async appender that the
> > users have configured in?
> >
> > Thanks in advance.
> >
> > Mads
> >
> > --
> >
> > Med venlig hilsen/Regards
> >
> > Chefarkitekt/Chief Architect cand.scient.dat, Ph.d., Mads Bondo Dydensborg
> >
> > Dansk BiblioteksCenter A/S, Tempovej 7-11, 2750 Ballerup, Tlf. +45 29 84
> > 00 42
> >
> >
> >
> > _______________________________________________
> > Logback-user mailing list
> > Logback-user at qos.ch
> > http://mailman.qos.ch/mailman/listinfo/logback-user
> >
> _______________________________________________
> Logback-user mailing list
> Logback-user at qos.ch
> http://mailman.qos.ch/mailman/listinfo/logback-user
> 
> 
> 
-- 
Med venlig hilsen/Regards

Chefarkitekt/Chief Architect cand.scient.dat, Ph.d., Mads Bondo Dydensborg
Dansk BiblioteksCenter A/S, Tempovej 7-11, 2750 Ballerup, Tlf. +45 29 84 00 42




More information about the Logback-user mailing list