Skip to Content.
Sympa Menu

mace-opensaml-users - Re: Change of logging framework

Subject: OpenSAML user discussion

List archive

Re: Change of logging framework


Chronological Thread 
  • From: "Chris Custine" <>
  • To:
  • Subject: Re: Change of logging framework
  • Date: Mon, 5 Nov 2007 13:59:11 -0700
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:sender:to:subject:in-reply-to:mime-version:content-type:references:x-google-sender-auth; b=CxxMFh7vnoS8nNkQvLIRrsWP764T0y/RGfIlTphbaQ160dKGjV8NN1rv88EnDtlMO6OoUPmoL8jYJp/TY9jTjmii+bQLf7VSBGyKwL3oA33a/m7qZ7Ox9ovHlAPBpLu2kJLHUonWNu7TC8CVdcNinRuxTh7saHXEkFj7PLqzyAg=

I think you will be very happy moving to SLF4J, and if any 3rd party libraries use commons-logging you can defeat the classloading problems by using jcl-over-slf4j.  I wrote one of the blog entries mentioned in Bruce Snyder's blog below and I explain this hack in more detail.  This will be a really good move.

Chris

On 11/5/07, Chad La Joie <> wrote:
About a week ago I moved the Shibboleth IdP code base to use SLF4J as
its logging interface.  I did this for one main reason; different
environments have really begun to diverge in their logging layer.  Some
(e.g . some versions of Tomcat) are using old versions Log4J, some are
using newer version that break when used with the older version (yay for
API changes in patch releases), some are using the java.util.logging
(JULI) system.  This is making it increasingly difficult to figure out
what to target and leading to a number of class/classpath errors.  In
addition I got some syntax sugar, which was nice, but not the reason I
made the change.

After evaluating SLF4J I found that it suited the needs of the IdP.  It
is similar to Jakarta Commons Logging but without some of the
classloading issues.  It can bind to Log4J, JULI, and other logging
systems.  If no one has any objections I'd like to move the OpenSAML
stack (XMLTooling, OpenWS, and OpenSAML 2) to SLF4J.

For more information on SLF4J you can check out its website:
http://www.slf4j.org/

For some discussion on the problems with Jakarta Logging Commons you can
check out this blog entry and related links.
http://bsnyderblog.blogspot.com/2007/08/my-soapbox-for-slf4j.html

I will *not* be recommending a particular binding for SLF4J (i.e . Log4J,
JULI, LogBack, whatever), people should use what is best/supported in
their environment.  I can say for the IdP I happen to use LogBack
because it has a few features that I prefer that Log4J doesn't have.  I
personally refuse to use JULI mostly for the reasons cited in the above
blog post.

So, if you have comments, please let me know by the end of the week.

Thanks.

--
SWITCH
Serving Swiss Universities
--------------------------
Chad La Joie, Software Engineer, Security
Werdstrasse 2, P.O. Box, 8021 Zurich, Switzerland
phone +41 44 268 15 75, fax +41 44 268 15 68
, http://www.switch.ch




Archive powered by MHonArc 2.6.16.

Top of Page