[logback-user] How to get list of configured loggers
praveen patil
iampraveenpatil at gmail.com
Fri Jun 7 07:14:33 CEST 2013
hi govardhana ,
{code}
DOMConfigurator config = new DOMConfigurator();
config.doConfigure(LogUtil.class.getResourceAsStream( //log4j.xml ),
//org.apache.log4j.Hierarchy );
{code}
this code is used to initialize log4j.xml, to initilize logback.xml
just put your logback.xml on claspath , it will be aoutomatically
configured.
Cheers
praveen
On Tue, Jun 4, 2013 at 1:03 PM, Govardhana <jgovardhana at gmail.com> wrote:
> Hi Ceki,
>
> Thanks for quick response!
>
> whether we will get the loggers info of provided logger (logback.xml) or
> some other also ?
>
> Another question:
> below snippet by using Log4j:
> DOMConfigurator config = new DOMConfigurator();
> config.doConfigure(LogUtil.class.getResourceAsStream( //log4j.xml
> ),
> //org.apache.log4j.Hierarchy );
>
> By using logback , i can use "JoranConfigurator" or any other..please
> suggest.
>
> Regards,
> Govardhana
>
>
>
> --
> View this message in context:
> http://logback.10977.n7.nabble.com/How-to-get-list-of-configured-loggers-tp12419p12421.html
> Sent from the Users mailing list archive at Nabble.com.
> _______________________________________________
> Logback-user mailing list
> Logback-user at qos.ch
> http://mailman.qos.ch/mailman/listinfo/logback-user
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.qos.ch/pipermail/logback-user/attachments/20130607/0a6a974a/attachment-0001.html>
More information about the Logback-user
mailing list