You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by Will Hoover <ja...@gmail.com> on 2013/03/07 20:14:17 UTC

Tomee slf4j

I noticed that http://openejb.apache.org/properties-listing.html does not
have an entry for openejb.log.factory?

 

What is the process for getting Tomee to use slf4j/logback? I tried adding
the following to conf/system.properties, but it doesn't seem to work as
expected. The catalina log shows that it's using
org.apache.openejb.util.Slf4jLogStream, but all of the individual
application logs are also going to the catalina log rather than the log file
defined in logback.xml

 

openejb.log.factory=org.apache.openejb.util.Slf4jLogStreamFactory

 


Re: Tomee slf4j

Posted by Romain Manni-Bucau <rm...@gmail.com>.
the spec defines (more or less in practise) war is first all other are
delegate first IIRC....but for classes not for resources (xml)


*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog: **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/3/8 Will Hoover <ja...@gmail.com>

> Okay, thanks for your help!
>
> It would seem more natural that any lib bundled in a war should inherit the
> configuration of the war first rather than the container where the war
> resides. So inheritance would follow:
>
> JAR > WAR > EAR > Web Container
>
> -----Original Message-----
> From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> Sent: Friday, March 08, 2013 9:11 AM
> To: users@tomee.apache.org
> Subject: Re: Tomee slf4j
>
> i don't think so,
>
> if you want to use the container jars you use the container config.
>
> Could be a bug of logback but all logging lib have it
>
> *Romain Manni-Bucau*
> *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> *Blog:
> **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
> *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> *Github: https://github.com/rmannibucau*
>
>
>
> 2013/3/8 Will Hoover <ja...@gmail.com>
>
> > Would this be considered a bug? Adding logback.xml to all of the jars
> > in a war's WEB-INF/libs seems like a cumbersome workaround, right?
> >
> > -----Original Message-----
> > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > Sent: Friday, March 08, 2013 8:57 AM
> > To: users@tomee.apache.org
> > Subject: Re: Tomee slf4j
> >
> > yes,
> >
> > i just tested and it works (with trunk at least)
> >
> > logback + slf4j api + logback.xml in container and if needed the app
> > (need to be delivered in the app if the conf is different)
> >
> > *Romain Manni-Bucau*
> > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > *Blog:
> > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/
> > >
> > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > *Github: https://github.com/rmannibucau*
> >
> >
> >
> > 2013/3/8 Will Hoover <ja...@gmail.com>
> >
> > > You mean add the application's logback.xml to the jars in WEB-INF/lib?
> > >
> > > -----Original Message-----
> > > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > > Sent: Friday, March 08, 2013 7:43 AM
> > > To: users@tomee.apache.org
> > > Subject: RE: Tomee slf4j
> > >
> > > Hmm, for log4j it takes its conf in the classloader if the jar. Not
> > > sure about logback but can be the same issue.
> > >
> > > The workaround is to merge both conf Le 8 mars 2013 13:35, "Will
> > > Hoover" <ja...@gmail.com> a écrit :
> > >
> > > > Yes, slf4j-api-1.7.2.jar, logback-classic-1.0.7.jar,
> > > > logback-core-1.0.7.jar, and log4j-over-slf4j-1.7.2.jar all exist
> > > > under WEB-INF/lib of the deployed war.
> > > >
> > > > -----Original Message-----
> > > > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > > > Sent: Friday, March 08, 2013 7:24 AM
> > > > To: users@tomee.apache.org
> > > > Subject: Re: Tomee slf4j
> > > >
> > > > did you provide logback+/slf4j-api in the webapp?
> > > >
> > > > *Romain Manni-Bucau*
> > > > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > > > *Blog:
> > > > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.
> > > > co
> > > > m/
> > > > >
> > > > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > > > *Github: https://github.com/rmannibucau*
> > > >
> > > >
> > > >
> > > > 2013/3/8 Will Hoover <ja...@gmail.com>
> > > >
> > > > > Thanks for the replies!
> > > > > I can get tomee to use slf4j/logback, but my issue is with
> > > > > deployed applications that have their own logback.xml. Logging
> > > > > from any class from within the deployed war works as expected (i.e.
> > > > > logs/myapp.log), but any jar within the war's WEB-INF/lib is
> > > > > logging to /logs/catalina.XXXX-XX-XX.log (I used spring
> > > > > dependencies as
> > > example).
> > > > >
> > > > > -----Original Message-----
> > > > > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > > > > Sent: Friday, March 08, 2013 5:52 AM
> > > > > To: users@tomee.apache.org
> > > > > Subject: Re: Tomee slf4j
> > > > >
> > > > > Hi,
> > > > >
> > > > > i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14
> > > > > from tomee and adding logback lib + a logback.xml. It works as
> > > > > epected knowing this property only affects what it can (openejb,
> > > > > tomee (not tomcat part),
> > > > > OWB...) frameworks.
> > > > >
> > > > > Tomcat doesn't have a facade for logging so it is hard to switch
> > > > > it without jul to slf4j workarounds.
> > > > >
> > > > > *Romain Manni-Bucau*
> > > > > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > > > > *Blog:
> > > > > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.
> > > > > co
> > > > > m/
> > > > > >
> > > > > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > > > > *Github: https://github.com/rmannibucau*
> > > > >
> > > > >
> > > > >
> > > > > 2013/3/7 Harald Wellmann <hw...@gmail.com>
> > > > >
> > > > > > This is probably not the "official" approach (if there is
> > > > > > one), but it worked for me:
> > > > > >
> > > > > > http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> > > > > > and-logback-in.html<http://hwellmann.blogspot.de/2012/11/loggi
> > > > > > ng
> > > > > > -w
> > > > > > it
> > > > > > h-
> > > > > > slf4j-and-logback-in.html>
> > > > > >
> > > > > > Best regards,
> > > > > > Harald
> > > > > >
> > > > > >
> > > > > > Am 07.03.2013 20:14, schrieb Will Hoover:
> > > > > >
> > > > > >  I noticed that
> > > > > > http://openejb.apache.org/**properties-listing.html<http://ope
> > > > > > ne jb .a pa che.org/properties-listing.html>does not
> > > > > >> have an entry for openejb.log.factory?
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >> What is the process for getting Tomee to use slf4j/logback? I
> > > > > >> tried adding the following to conf/system.properties, but it
> > > > > >> doesn't seem to work as expected. The catalina log shows that
> > > > > >> it's using org.apache.openejb.util.**Slf4jLogStream, but all
> > > > > >> of the individual application logs are also going to the
> > > > > >> catalina log rather than the log file defined in logback.xml
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStrea
> > > > > >> mF
> > > > > >> ac
> > > > > >> to
> > > > > >> ry
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>

RE: Tomee slf4j

Posted by Will Hoover <ja...@gmail.com>.
Okay, thanks for your help!

It would seem more natural that any lib bundled in a war should inherit the
configuration of the war first rather than the container where the war
resides. So inheritance would follow:

JAR > WAR > EAR > Web Container

-----Original Message-----
From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com] 
Sent: Friday, March 08, 2013 9:11 AM
To: users@tomee.apache.org
Subject: Re: Tomee slf4j

i don't think so,

if you want to use the container jars you use the container config.

Could be a bug of logback but all logging lib have it

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog:
**http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/3/8 Will Hoover <ja...@gmail.com>

> Would this be considered a bug? Adding logback.xml to all of the jars 
> in a war's WEB-INF/libs seems like a cumbersome workaround, right?
>
> -----Original Message-----
> From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> Sent: Friday, March 08, 2013 8:57 AM
> To: users@tomee.apache.org
> Subject: Re: Tomee slf4j
>
> yes,
>
> i just tested and it works (with trunk at least)
>
> logback + slf4j api + logback.xml in container and if needed the app 
> (need to be delivered in the app if the conf is different)
>
> *Romain Manni-Bucau*
> *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> *Blog:
> **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/
> >
> *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> *Github: https://github.com/rmannibucau*
>
>
>
> 2013/3/8 Will Hoover <ja...@gmail.com>
>
> > You mean add the application's logback.xml to the jars in WEB-INF/lib?
> >
> > -----Original Message-----
> > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > Sent: Friday, March 08, 2013 7:43 AM
> > To: users@tomee.apache.org
> > Subject: RE: Tomee slf4j
> >
> > Hmm, for log4j it takes its conf in the classloader if the jar. Not 
> > sure about logback but can be the same issue.
> >
> > The workaround is to merge both conf Le 8 mars 2013 13:35, "Will 
> > Hoover" <ja...@gmail.com> a écrit :
> >
> > > Yes, slf4j-api-1.7.2.jar, logback-classic-1.0.7.jar, 
> > > logback-core-1.0.7.jar, and log4j-over-slf4j-1.7.2.jar all exist 
> > > under WEB-INF/lib of the deployed war.
> > >
> > > -----Original Message-----
> > > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > > Sent: Friday, March 08, 2013 7:24 AM
> > > To: users@tomee.apache.org
> > > Subject: Re: Tomee slf4j
> > >
> > > did you provide logback+/slf4j-api in the webapp?
> > >
> > > *Romain Manni-Bucau*
> > > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > > *Blog:
> > > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.
> > > co
> > > m/
> > > >
> > > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > > *Github: https://github.com/rmannibucau*
> > >
> > >
> > >
> > > 2013/3/8 Will Hoover <ja...@gmail.com>
> > >
> > > > Thanks for the replies!
> > > > I can get tomee to use slf4j/logback, but my issue is with 
> > > > deployed applications that have their own logback.xml. Logging 
> > > > from any class from within the deployed war works as expected (i.e.
> > > > logs/myapp.log), but any jar within the war's WEB-INF/lib is 
> > > > logging to /logs/catalina.XXXX-XX-XX.log (I used spring 
> > > > dependencies as
> > example).
> > > >
> > > > -----Original Message-----
> > > > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > > > Sent: Friday, March 08, 2013 5:52 AM
> > > > To: users@tomee.apache.org
> > > > Subject: Re: Tomee slf4j
> > > >
> > > > Hi,
> > > >
> > > > i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14 
> > > > from tomee and adding logback lib + a logback.xml. It works as 
> > > > epected knowing this property only affects what it can (openejb, 
> > > > tomee (not tomcat part),
> > > > OWB...) frameworks.
> > > >
> > > > Tomcat doesn't have a facade for logging so it is hard to switch 
> > > > it without jul to slf4j workarounds.
> > > >
> > > > *Romain Manni-Bucau*
> > > > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > > > *Blog:
> > > > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.
> > > > co
> > > > m/
> > > > >
> > > > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > > > *Github: https://github.com/rmannibucau*
> > > >
> > > >
> > > >
> > > > 2013/3/7 Harald Wellmann <hw...@gmail.com>
> > > >
> > > > > This is probably not the "official" approach (if there is 
> > > > > one), but it worked for me:
> > > > >
> > > > > http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> > > > > and-logback-in.html<http://hwellmann.blogspot.de/2012/11/loggi
> > > > > ng
> > > > > -w
> > > > > it
> > > > > h-
> > > > > slf4j-and-logback-in.html>
> > > > >
> > > > > Best regards,
> > > > > Harald
> > > > >
> > > > >
> > > > > Am 07.03.2013 20:14, schrieb Will Hoover:
> > > > >
> > > > >  I noticed that
> > > > > http://openejb.apache.org/**properties-listing.html<http://ope
> > > > > ne jb .a pa che.org/properties-listing.html>does not
> > > > >> have an entry for openejb.log.factory?
> > > > >>
> > > > >>
> > > > >>
> > > > >> What is the process for getting Tomee to use slf4j/logback? I 
> > > > >> tried adding the following to conf/system.properties, but it 
> > > > >> doesn't seem to work as expected. The catalina log shows that 
> > > > >> it's using org.apache.openejb.util.**Slf4jLogStream, but all 
> > > > >> of the individual application logs are also going to the 
> > > > >> catalina log rather than the log file defined in logback.xml
> > > > >>
> > > > >>
> > > > >>
> > > > >> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStrea
> > > > >> mF
> > > > >> ac
> > > > >> to
> > > > >> ry
> > > > >>
> > > > >>
> > > > >>
> > > > >>
> > > > >>
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>


Re: Tomee slf4j

Posted by Romain Manni-Bucau <rm...@gmail.com>.
i don't think so,

if you want to use the container jars you use the container config.

Could be a bug of logback but all logging lib have it

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog: **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/3/8 Will Hoover <ja...@gmail.com>

> Would this be considered a bug? Adding logback.xml to all of the jars in a
> war's WEB-INF/libs seems like a cumbersome workaround, right?
>
> -----Original Message-----
> From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> Sent: Friday, March 08, 2013 8:57 AM
> To: users@tomee.apache.org
> Subject: Re: Tomee slf4j
>
> yes,
>
> i just tested and it works (with trunk at least)
>
> logback + slf4j api + logback.xml in container and if needed the app (need
> to be delivered in the app if the conf is different)
>
> *Romain Manni-Bucau*
> *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> *Blog:
> **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
> *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> *Github: https://github.com/rmannibucau*
>
>
>
> 2013/3/8 Will Hoover <ja...@gmail.com>
>
> > You mean add the application's logback.xml to the jars in WEB-INF/lib?
> >
> > -----Original Message-----
> > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > Sent: Friday, March 08, 2013 7:43 AM
> > To: users@tomee.apache.org
> > Subject: RE: Tomee slf4j
> >
> > Hmm, for log4j it takes its conf in the classloader if the jar. Not
> > sure about logback but can be the same issue.
> >
> > The workaround is to merge both conf
> > Le 8 mars 2013 13:35, "Will Hoover" <ja...@gmail.com> a écrit :
> >
> > > Yes, slf4j-api-1.7.2.jar, logback-classic-1.0.7.jar,
> > > logback-core-1.0.7.jar, and log4j-over-slf4j-1.7.2.jar all exist
> > > under WEB-INF/lib of the deployed war.
> > >
> > > -----Original Message-----
> > > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > > Sent: Friday, March 08, 2013 7:24 AM
> > > To: users@tomee.apache.org
> > > Subject: Re: Tomee slf4j
> > >
> > > did you provide logback+/slf4j-api in the webapp?
> > >
> > > *Romain Manni-Bucau*
> > > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > > *Blog:
> > > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.co
> > > m/
> > > >
> > > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > > *Github: https://github.com/rmannibucau*
> > >
> > >
> > >
> > > 2013/3/8 Will Hoover <ja...@gmail.com>
> > >
> > > > Thanks for the replies!
> > > > I can get tomee to use slf4j/logback, but my issue is with
> > > > deployed applications that have their own logback.xml. Logging
> > > > from any class from within the deployed war works as expected (i.e.
> > > > logs/myapp.log), but any jar within the war's WEB-INF/lib is
> > > > logging to /logs/catalina.XXXX-XX-XX.log (I used spring
> > > > dependencies as
> > example).
> > > >
> > > > -----Original Message-----
> > > > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > > > Sent: Friday, March 08, 2013 5:52 AM
> > > > To: users@tomee.apache.org
> > > > Subject: Re: Tomee slf4j
> > > >
> > > > Hi,
> > > >
> > > > i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14
> > > > from tomee and adding logback lib + a logback.xml. It works as
> > > > epected knowing this property only affects what it can (openejb,
> > > > tomee (not tomcat part),
> > > > OWB...) frameworks.
> > > >
> > > > Tomcat doesn't have a facade for logging so it is hard to switch
> > > > it without jul to slf4j workarounds.
> > > >
> > > > *Romain Manni-Bucau*
> > > > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > > > *Blog:
> > > > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.
> > > > co
> > > > m/
> > > > >
> > > > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > > > *Github: https://github.com/rmannibucau*
> > > >
> > > >
> > > >
> > > > 2013/3/7 Harald Wellmann <hw...@gmail.com>
> > > >
> > > > > This is probably not the "official" approach (if there is one),
> > > > > but it worked for me:
> > > > >
> > > > > http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> > > > > and-logback-in.html<http://hwellmann.blogspot.de/2012/11/logging
> > > > > -w
> > > > > it
> > > > > h-
> > > > > slf4j-and-logback-in.html>
> > > > >
> > > > > Best regards,
> > > > > Harald
> > > > >
> > > > >
> > > > > Am 07.03.2013 20:14, schrieb Will Hoover:
> > > > >
> > > > >  I noticed that
> > > > > http://openejb.apache.org/**properties-listing.html<http://opene
> > > > > jb .a pa che.org/properties-listing.html>does not
> > > > >> have an entry for openejb.log.factory?
> > > > >>
> > > > >>
> > > > >>
> > > > >> What is the process for getting Tomee to use slf4j/logback? I
> > > > >> tried adding the following to conf/system.properties, but it
> > > > >> doesn't seem to work as expected. The catalina log shows that
> > > > >> it's using org.apache.openejb.util.**Slf4jLogStream, but all of
> > > > >> the individual application logs are also going to the catalina
> > > > >> log rather than the log file defined in logback.xml
> > > > >>
> > > > >>
> > > > >>
> > > > >> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStreamF
> > > > >> ac
> > > > >> to
> > > > >> ry
> > > > >>
> > > > >>
> > > > >>
> > > > >>
> > > > >>
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>

RE: Tomee slf4j

Posted by Will Hoover <ja...@gmail.com>.
Would this be considered a bug? Adding logback.xml to all of the jars in a
war's WEB-INF/libs seems like a cumbersome workaround, right?

-----Original Message-----
From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com] 
Sent: Friday, March 08, 2013 8:57 AM
To: users@tomee.apache.org
Subject: Re: Tomee slf4j

yes,

i just tested and it works (with trunk at least)

logback + slf4j api + logback.xml in container and if needed the app (need
to be delivered in the app if the conf is different)

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog:
**http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/3/8 Will Hoover <ja...@gmail.com>

> You mean add the application's logback.xml to the jars in WEB-INF/lib?
>
> -----Original Message-----
> From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> Sent: Friday, March 08, 2013 7:43 AM
> To: users@tomee.apache.org
> Subject: RE: Tomee slf4j
>
> Hmm, for log4j it takes its conf in the classloader if the jar. Not 
> sure about logback but can be the same issue.
>
> The workaround is to merge both conf
> Le 8 mars 2013 13:35, "Will Hoover" <ja...@gmail.com> a écrit :
>
> > Yes, slf4j-api-1.7.2.jar, logback-classic-1.0.7.jar, 
> > logback-core-1.0.7.jar, and log4j-over-slf4j-1.7.2.jar all exist 
> > under WEB-INF/lib of the deployed war.
> >
> > -----Original Message-----
> > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > Sent: Friday, March 08, 2013 7:24 AM
> > To: users@tomee.apache.org
> > Subject: Re: Tomee slf4j
> >
> > did you provide logback+/slf4j-api in the webapp?
> >
> > *Romain Manni-Bucau*
> > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > *Blog:
> > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.co
> > m/
> > >
> > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > *Github: https://github.com/rmannibucau*
> >
> >
> >
> > 2013/3/8 Will Hoover <ja...@gmail.com>
> >
> > > Thanks for the replies!
> > > I can get tomee to use slf4j/logback, but my issue is with 
> > > deployed applications that have their own logback.xml. Logging 
> > > from any class from within the deployed war works as expected (i.e.
> > > logs/myapp.log), but any jar within the war's WEB-INF/lib is 
> > > logging to /logs/catalina.XXXX-XX-XX.log (I used spring 
> > > dependencies as
> example).
> > >
> > > -----Original Message-----
> > > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > > Sent: Friday, March 08, 2013 5:52 AM
> > > To: users@tomee.apache.org
> > > Subject: Re: Tomee slf4j
> > >
> > > Hi,
> > >
> > > i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14 
> > > from tomee and adding logback lib + a logback.xml. It works as 
> > > epected knowing this property only affects what it can (openejb, 
> > > tomee (not tomcat part),
> > > OWB...) frameworks.
> > >
> > > Tomcat doesn't have a facade for logging so it is hard to switch 
> > > it without jul to slf4j workarounds.
> > >
> > > *Romain Manni-Bucau*
> > > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > > *Blog:
> > > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.
> > > co
> > > m/
> > > >
> > > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > > *Github: https://github.com/rmannibucau*
> > >
> > >
> > >
> > > 2013/3/7 Harald Wellmann <hw...@gmail.com>
> > >
> > > > This is probably not the "official" approach (if there is one), 
> > > > but it worked for me:
> > > >
> > > > http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> > > > and-logback-in.html<http://hwellmann.blogspot.de/2012/11/logging
> > > > -w
> > > > it
> > > > h-
> > > > slf4j-and-logback-in.html>
> > > >
> > > > Best regards,
> > > > Harald
> > > >
> > > >
> > > > Am 07.03.2013 20:14, schrieb Will Hoover:
> > > >
> > > >  I noticed that
> > > > http://openejb.apache.org/**properties-listing.html<http://opene
> > > > jb .a pa che.org/properties-listing.html>does not
> > > >> have an entry for openejb.log.factory?
> > > >>
> > > >>
> > > >>
> > > >> What is the process for getting Tomee to use slf4j/logback? I 
> > > >> tried adding the following to conf/system.properties, but it 
> > > >> doesn't seem to work as expected. The catalina log shows that 
> > > >> it's using org.apache.openejb.util.**Slf4jLogStream, but all of 
> > > >> the individual application logs are also going to the catalina 
> > > >> log rather than the log file defined in logback.xml
> > > >>
> > > >>
> > > >>
> > > >> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStreamF
> > > >> ac
> > > >> to
> > > >> ry
> > > >>
> > > >>
> > > >>
> > > >>
> > > >>
> > > >
> > >
> > >
> >
> >
>
>


Re: Tomee slf4j

Posted by Romain Manni-Bucau <rm...@gmail.com>.
yes,

i just tested and it works (with trunk at least)

logback + slf4j api + logback.xml in container and if needed the app (need
to be delivered in the app if the conf is different)

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog: **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/3/8 Will Hoover <ja...@gmail.com>

> You mean add the application's logback.xml to the jars in WEB-INF/lib?
>
> -----Original Message-----
> From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> Sent: Friday, March 08, 2013 7:43 AM
> To: users@tomee.apache.org
> Subject: RE: Tomee slf4j
>
> Hmm, for log4j it takes its conf in the classloader if the jar. Not sure
> about logback but can be the same issue.
>
> The workaround is to merge both conf
> Le 8 mars 2013 13:35, "Will Hoover" <ja...@gmail.com> a écrit :
>
> > Yes, slf4j-api-1.7.2.jar, logback-classic-1.0.7.jar,
> > logback-core-1.0.7.jar, and log4j-over-slf4j-1.7.2.jar all exist under
> > WEB-INF/lib of the deployed war.
> >
> > -----Original Message-----
> > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > Sent: Friday, March 08, 2013 7:24 AM
> > To: users@tomee.apache.org
> > Subject: Re: Tomee slf4j
> >
> > did you provide logback+/slf4j-api in the webapp?
> >
> > *Romain Manni-Bucau*
> > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > *Blog:
> > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/
> > >
> > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > *Github: https://github.com/rmannibucau*
> >
> >
> >
> > 2013/3/8 Will Hoover <ja...@gmail.com>
> >
> > > Thanks for the replies!
> > > I can get tomee to use slf4j/logback, but my issue is with deployed
> > > applications that have their own logback.xml. Logging from any class
> > > from within the deployed war works as expected (i.e.
> > > logs/myapp.log), but any jar within the war's WEB-INF/lib is logging
> > > to /logs/catalina.XXXX-XX-XX.log (I used spring dependencies as
> example).
> > >
> > > -----Original Message-----
> > > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > > Sent: Friday, March 08, 2013 5:52 AM
> > > To: users@tomee.apache.org
> > > Subject: Re: Tomee slf4j
> > >
> > > Hi,
> > >
> > > i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14 from
> > > tomee and adding logback lib + a logback.xml. It works as epected
> > > knowing this property only affects what it can (openejb, tomee (not
> > > tomcat part),
> > > OWB...) frameworks.
> > >
> > > Tomcat doesn't have a facade for logging so it is hard to switch it
> > > without jul to slf4j workarounds.
> > >
> > > *Romain Manni-Bucau*
> > > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > > *Blog:
> > > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.co
> > > m/
> > > >
> > > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > > *Github: https://github.com/rmannibucau*
> > >
> > >
> > >
> > > 2013/3/7 Harald Wellmann <hw...@gmail.com>
> > >
> > > > This is probably not the "official" approach (if there is one),
> > > > but it worked for me:
> > > >
> > > > http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> > > > and-logback-in.html<http://hwellmann.blogspot.de/2012/11/logging-w
> > > > it
> > > > h-
> > > > slf4j-and-logback-in.html>
> > > >
> > > > Best regards,
> > > > Harald
> > > >
> > > >
> > > > Am 07.03.2013 20:14, schrieb Will Hoover:
> > > >
> > > >  I noticed that
> > > > http://openejb.apache.org/**properties-listing.html<http://openejb
> > > > .a pa che.org/properties-listing.html>does not
> > > >> have an entry for openejb.log.factory?
> > > >>
> > > >>
> > > >>
> > > >> What is the process for getting Tomee to use slf4j/logback? I
> > > >> tried adding the following to conf/system.properties, but it
> > > >> doesn't seem to work as expected. The catalina log shows that
> > > >> it's using org.apache.openejb.util.**Slf4jLogStream, but all of
> > > >> the individual application logs are also going to the catalina
> > > >> log rather than the log file defined in logback.xml
> > > >>
> > > >>
> > > >>
> > > >> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStreamFac
> > > >> to
> > > >> ry
> > > >>
> > > >>
> > > >>
> > > >>
> > > >>
> > > >
> > >
> > >
> >
> >
>
>

RE: Tomee slf4j

Posted by Will Hoover <ja...@gmail.com>.
You mean add the application's logback.xml to the jars in WEB-INF/lib?

-----Original Message-----
From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com] 
Sent: Friday, March 08, 2013 7:43 AM
To: users@tomee.apache.org
Subject: RE: Tomee slf4j

Hmm, for log4j it takes its conf in the classloader if the jar. Not sure
about logback but can be the same issue.

The workaround is to merge both conf
Le 8 mars 2013 13:35, "Will Hoover" <ja...@gmail.com> a écrit :

> Yes, slf4j-api-1.7.2.jar, logback-classic-1.0.7.jar, 
> logback-core-1.0.7.jar, and log4j-over-slf4j-1.7.2.jar all exist under 
> WEB-INF/lib of the deployed war.
>
> -----Original Message-----
> From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> Sent: Friday, March 08, 2013 7:24 AM
> To: users@tomee.apache.org
> Subject: Re: Tomee slf4j
>
> did you provide logback+/slf4j-api in the webapp?
>
> *Romain Manni-Bucau*
> *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> *Blog:
> **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/
> >
> *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> *Github: https://github.com/rmannibucau*
>
>
>
> 2013/3/8 Will Hoover <ja...@gmail.com>
>
> > Thanks for the replies!
> > I can get tomee to use slf4j/logback, but my issue is with deployed 
> > applications that have their own logback.xml. Logging from any class 
> > from within the deployed war works as expected (i.e. 
> > logs/myapp.log), but any jar within the war's WEB-INF/lib is logging 
> > to /logs/catalina.XXXX-XX-XX.log (I used spring dependencies as
example).
> >
> > -----Original Message-----
> > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > Sent: Friday, March 08, 2013 5:52 AM
> > To: users@tomee.apache.org
> > Subject: Re: Tomee slf4j
> >
> > Hi,
> >
> > i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14 from 
> > tomee and adding logback lib + a logback.xml. It works as epected 
> > knowing this property only affects what it can (openejb, tomee (not 
> > tomcat part),
> > OWB...) frameworks.
> >
> > Tomcat doesn't have a facade for logging so it is hard to switch it 
> > without jul to slf4j workarounds.
> >
> > *Romain Manni-Bucau*
> > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > *Blog:
> > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.co
> > m/
> > >
> > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > *Github: https://github.com/rmannibucau*
> >
> >
> >
> > 2013/3/7 Harald Wellmann <hw...@gmail.com>
> >
> > > This is probably not the "official" approach (if there is one), 
> > > but it worked for me:
> > >
> > > http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> > > and-logback-in.html<http://hwellmann.blogspot.de/2012/11/logging-w
> > > it
> > > h-
> > > slf4j-and-logback-in.html>
> > >
> > > Best regards,
> > > Harald
> > >
> > >
> > > Am 07.03.2013 20:14, schrieb Will Hoover:
> > >
> > >  I noticed that
> > > http://openejb.apache.org/**properties-listing.html<http://openejb
> > > .a pa che.org/properties-listing.html>does not
> > >> have an entry for openejb.log.factory?
> > >>
> > >>
> > >>
> > >> What is the process for getting Tomee to use slf4j/logback? I 
> > >> tried adding the following to conf/system.properties, but it 
> > >> doesn't seem to work as expected. The catalina log shows that 
> > >> it's using org.apache.openejb.util.**Slf4jLogStream, but all of 
> > >> the individual application logs are also going to the catalina 
> > >> log rather than the log file defined in logback.xml
> > >>
> > >>
> > >>
> > >> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStreamFac
> > >> to
> > >> ry
> > >>
> > >>
> > >>
> > >>
> > >>
> > >
> >
> >
>
>


RE: Tomee slf4j

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hmm, for log4j it takes its conf in the classloader if the jar. Not sure
about logback but can be the same issue.

The workaround is to merge both conf
Le 8 mars 2013 13:35, "Will Hoover" <ja...@gmail.com> a écrit :

> Yes, slf4j-api-1.7.2.jar, logback-classic-1.0.7.jar,
> logback-core-1.0.7.jar,
> and log4j-over-slf4j-1.7.2.jar all exist under WEB-INF/lib of the deployed
> war.
>
> -----Original Message-----
> From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> Sent: Friday, March 08, 2013 7:24 AM
> To: users@tomee.apache.org
> Subject: Re: Tomee slf4j
>
> did you provide logback+/slf4j-api in the webapp?
>
> *Romain Manni-Bucau*
> *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> *Blog:
> **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
> *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> *Github: https://github.com/rmannibucau*
>
>
>
> 2013/3/8 Will Hoover <ja...@gmail.com>
>
> > Thanks for the replies!
> > I can get tomee to use slf4j/logback, but my issue is with deployed
> > applications that have their own logback.xml. Logging from any class
> > from within the deployed war works as expected (i.e. logs/myapp.log),
> > but any jar within the war's WEB-INF/lib is logging to
> > /logs/catalina.XXXX-XX-XX.log (I used spring dependencies as example).
> >
> > -----Original Message-----
> > From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> > Sent: Friday, March 08, 2013 5:52 AM
> > To: users@tomee.apache.org
> > Subject: Re: Tomee slf4j
> >
> > Hi,
> >
> > i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14 from
> > tomee and adding logback lib + a logback.xml. It works as epected
> > knowing this property only affects what it can (openejb, tomee (not
> > tomcat part),
> > OWB...) frameworks.
> >
> > Tomcat doesn't have a facade for logging so it is hard to switch it
> > without jul to slf4j workarounds.
> >
> > *Romain Manni-Bucau*
> > *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> > *Blog:
> > **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/
> > >
> > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> > *Github: https://github.com/rmannibucau*
> >
> >
> >
> > 2013/3/7 Harald Wellmann <hw...@gmail.com>
> >
> > > This is probably not the "official" approach (if there is one), but
> > > it worked for me:
> > >
> > > http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> > > and-logback-in.html<http://hwellmann.blogspot.de/2012/11/logging-wit
> > > h-
> > > slf4j-and-logback-in.html>
> > >
> > > Best regards,
> > > Harald
> > >
> > >
> > > Am 07.03.2013 20:14, schrieb Will Hoover:
> > >
> > >  I noticed that
> > > http://openejb.apache.org/**properties-listing.html<http://openejb.a
> > > pa che.org/properties-listing.html>does not
> > >> have an entry for openejb.log.factory?
> > >>
> > >>
> > >>
> > >> What is the process for getting Tomee to use slf4j/logback? I tried
> > >> adding the following to conf/system.properties, but it doesn't seem
> > >> to work as expected. The catalina log shows that it's using
> > >> org.apache.openejb.util.**Slf4jLogStream, but all of the individual
> > >> application logs are also going to the catalina log rather than the
> > >> log file defined in logback.xml
> > >>
> > >>
> > >>
> > >> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStreamFacto
> > >> ry
> > >>
> > >>
> > >>
> > >>
> > >>
> > >
> >
> >
>
>

RE: Tomee slf4j

Posted by Will Hoover <ja...@gmail.com>.
Yes, slf4j-api-1.7.2.jar, logback-classic-1.0.7.jar, logback-core-1.0.7.jar,
and log4j-over-slf4j-1.7.2.jar all exist under WEB-INF/lib of the deployed
war.

-----Original Message-----
From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com] 
Sent: Friday, March 08, 2013 7:24 AM
To: users@tomee.apache.org
Subject: Re: Tomee slf4j

did you provide logback+/slf4j-api in the webapp?

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog:
**http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/3/8 Will Hoover <ja...@gmail.com>

> Thanks for the replies!
> I can get tomee to use slf4j/logback, but my issue is with deployed 
> applications that have their own logback.xml. Logging from any class 
> from within the deployed war works as expected (i.e. logs/myapp.log), 
> but any jar within the war's WEB-INF/lib is logging to 
> /logs/catalina.XXXX-XX-XX.log (I used spring dependencies as example).
>
> -----Original Message-----
> From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> Sent: Friday, March 08, 2013 5:52 AM
> To: users@tomee.apache.org
> Subject: Re: Tomee slf4j
>
> Hi,
>
> i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14 from 
> tomee and adding logback lib + a logback.xml. It works as epected 
> knowing this property only affects what it can (openejb, tomee (not 
> tomcat part),
> OWB...) frameworks.
>
> Tomcat doesn't have a facade for logging so it is hard to switch it 
> without jul to slf4j workarounds.
>
> *Romain Manni-Bucau*
> *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> *Blog:
> **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/
> >
> *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> *Github: https://github.com/rmannibucau*
>
>
>
> 2013/3/7 Harald Wellmann <hw...@gmail.com>
>
> > This is probably not the "official" approach (if there is one), but 
> > it worked for me:
> >
> > http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> > and-logback-in.html<http://hwellmann.blogspot.de/2012/11/logging-wit
> > h-
> > slf4j-and-logback-in.html>
> >
> > Best regards,
> > Harald
> >
> >
> > Am 07.03.2013 20:14, schrieb Will Hoover:
> >
> >  I noticed that
> > http://openejb.apache.org/**properties-listing.html<http://openejb.a
> > pa che.org/properties-listing.html>does not
> >> have an entry for openejb.log.factory?
> >>
> >>
> >>
> >> What is the process for getting Tomee to use slf4j/logback? I tried 
> >> adding the following to conf/system.properties, but it doesn't seem 
> >> to work as expected. The catalina log shows that it's using 
> >> org.apache.openejb.util.**Slf4jLogStream, but all of the individual 
> >> application logs are also going to the catalina log rather than the 
> >> log file defined in logback.xml
> >>
> >>
> >>
> >> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStreamFacto
> >> ry
> >>
> >>
> >>
> >>
> >>
> >
>
>


Re: Tomee slf4j

Posted by Romain Manni-Bucau <rm...@gmail.com>.
did you provide logback+/slf4j-api in the webapp?

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog: **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/3/8 Will Hoover <ja...@gmail.com>

> Thanks for the replies!
> I can get tomee to use slf4j/logback, but my issue is with deployed
> applications that have their own logback.xml. Logging from any class from
> within the deployed war works as expected (i.e. logs/myapp.log), but any
> jar
> within the war's WEB-INF/lib is logging to /logs/catalina.XXXX-XX-XX.log (I
> used spring dependencies as example).
>
> -----Original Message-----
> From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com]
> Sent: Friday, March 08, 2013 5:52 AM
> To: users@tomee.apache.org
> Subject: Re: Tomee slf4j
>
> Hi,
>
> i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14 from tomee
> and adding logback lib + a logback.xml. It works as epected knowing this
> property only affects what it can (openejb, tomee (not tomcat part),
> OWB...) frameworks.
>
> Tomcat doesn't have a facade for logging so it is hard to switch it without
> jul to slf4j workarounds.
>
> *Romain Manni-Bucau*
> *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> *Blog:
> **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
> *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> *Github: https://github.com/rmannibucau*
>
>
>
> 2013/3/7 Harald Wellmann <hw...@gmail.com>
>
> > This is probably not the "official" approach (if there is one), but it
> > worked for me:
> >
> > http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> > and-logback-in.html<http://hwellmann.blogspot.de/2012/11/logging-with-
> > slf4j-and-logback-in.html>
> >
> > Best regards,
> > Harald
> >
> >
> > Am 07.03.2013 20:14, schrieb Will Hoover:
> >
> >  I noticed that
> > http://openejb.apache.org/**properties-listing.html<http://openejb.apa
> > che.org/properties-listing.html>does not
> >> have an entry for openejb.log.factory?
> >>
> >>
> >>
> >> What is the process for getting Tomee to use slf4j/logback? I tried
> >> adding the following to conf/system.properties, but it doesn't seem
> >> to work as expected. The catalina log shows that it's using
> >> org.apache.openejb.util.**Slf4jLogStream, but all of the individual
> >> application logs are also going to the catalina log rather than the
> >> log file defined in logback.xml
> >>
> >>
> >>
> >> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStreamFactory
> >>
> >>
> >>
> >>
> >>
> >
>
>

RE: Tomee slf4j

Posted by Will Hoover <ja...@gmail.com>.
Thanks for the replies!
I can get tomee to use slf4j/logback, but my issue is with deployed
applications that have their own logback.xml. Logging from any class from
within the deployed war works as expected (i.e. logs/myapp.log), but any jar
within the war's WEB-INF/lib is logging to /logs/catalina.XXXX-XX-XX.log (I
used spring dependencies as example).

-----Original Message-----
From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com] 
Sent: Friday, March 08, 2013 5:52 AM
To: users@tomee.apache.org
Subject: Re: Tomee slf4j

Hi,

i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14 from tomee
and adding logback lib + a logback.xml. It works as epected knowing this
property only affects what it can (openejb, tomee (not tomcat part),
OWB...) frameworks.

Tomcat doesn't have a facade for logging so it is hard to switch it without
jul to slf4j workarounds.

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog:
**http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/3/7 Harald Wellmann <hw...@gmail.com>

> This is probably not the "official" approach (if there is one), but it 
> worked for me:
>
> http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> and-logback-in.html<http://hwellmann.blogspot.de/2012/11/logging-with-
> slf4j-and-logback-in.html>
>
> Best regards,
> Harald
>
>
> Am 07.03.2013 20:14, schrieb Will Hoover:
>
>  I noticed that 
> http://openejb.apache.org/**properties-listing.html<http://openejb.apa
> che.org/properties-listing.html>does not
>> have an entry for openejb.log.factory?
>>
>>
>>
>> What is the process for getting Tomee to use slf4j/logback? I tried 
>> adding the following to conf/system.properties, but it doesn't seem 
>> to work as expected. The catalina log shows that it's using 
>> org.apache.openejb.util.**Slf4jLogStream, but all of the individual 
>> application logs are also going to the catalina log rather than the 
>> log file defined in logback.xml
>>
>>
>>
>> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStreamFactory
>>
>>
>>
>>
>>
>


Re: Tomee slf4j

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi,

i just tested -Dopenejb.log.factory=slf4j removing slf4j-jdk14 from tomee
and adding logback lib + a logback.xml. It works as epected knowing this
property only affects what it can (openejb, tomee (not tomcat part),
OWB...) frameworks.

Tomcat doesn't have a facade for logging so it is hard to switch it without
jul to slf4j workarounds.

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog: **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/3/7 Harald Wellmann <hw...@gmail.com>

> This is probably not the "official" approach (if there is one), but it
> worked for me:
>
> http://hwellmann.blogspot.de/**2012/11/logging-with-slf4j-**
> and-logback-in.html<http://hwellmann.blogspot.de/2012/11/logging-with-slf4j-and-logback-in.html>
>
> Best regards,
> Harald
>
>
> Am 07.03.2013 20:14, schrieb Will Hoover:
>
>  I noticed that http://openejb.apache.org/**properties-listing.html<http://openejb.apache.org/properties-listing.html>does not
>> have an entry for openejb.log.factory?
>>
>>
>>
>> What is the process for getting Tomee to use slf4j/logback? I tried adding
>> the following to conf/system.properties, but it doesn't seem to work as
>> expected. The catalina log shows that it's using
>> org.apache.openejb.util.**Slf4jLogStream, but all of the individual
>> application logs are also going to the catalina log rather than the log
>> file
>> defined in logback.xml
>>
>>
>>
>> openejb.log.factory=org.**apache.openejb.util.**Slf4jLogStreamFactory
>>
>>
>>
>>
>>
>

Re: Tomee slf4j

Posted by Harald Wellmann <hw...@gmail.com>.
This is probably not the "official" approach (if there is one), but it 
worked for me:

http://hwellmann.blogspot.de/2012/11/logging-with-slf4j-and-logback-in.html

Best regards,
Harald


Am 07.03.2013 20:14, schrieb Will Hoover:
> I noticed that http://openejb.apache.org/properties-listing.html does not
> have an entry for openejb.log.factory?
>
>
>
> What is the process for getting Tomee to use slf4j/logback? I tried adding
> the following to conf/system.properties, but it doesn't seem to work as
> expected. The catalina log shows that it's using
> org.apache.openejb.util.Slf4jLogStream, but all of the individual
> application logs are also going to the catalina log rather than the log file
> defined in logback.xml
>
>
>
> openejb.log.factory=org.apache.openejb.util.Slf4jLogStreamFactory
>
>
>
>