[Netarchivesuite-devel] Troubleshooting - Need to see Jetty logging

Mikis Seth Sørensen mss at statsbiblioteket.dk
Thu Mar 3 14:46:12 CET 2011


Hi Nicolas

Here at SB we started trying out a (relatively) new great logging framework, SLF4J<http://www.slf4j.org/>, which commons with the ability to hook into existing logging frameworks at runtime and use the logging done through these frameworks. The hookup is done simple by adding the appropriate slf4j bridge to the classpath, eg. the log4j-over-slf4j<http://www.slf4j.org/legacy.html#log4j-over-slf4j> bridge in this case. Slf4j doesn't need a configuration file to work, so it should work out of the box. You should also tell slf4j which logging framework it should use for the logout put, eg. slf4j-jcl-1.6.1.jar for using the normal NAS commons logging framework

Here is a some more details on Jetty and slf4j: http://docs.codehaus.org/display/JETTY/Debugging. As you can see Jetty already uses slf4j (as a lot of OS frameworks these days), and the actual behavior depends on which jars are in the classpath in the concrete installation.

Good luck
Mikis

From: Nicolas Giraud <nikokode at gmail.com<mailto:nikokode at gmail.com>>
Reply-To: "netarchivesuite-devel at lists.gforge.statsbiblioteket.dk<mailto:netarchivesuite-devel at lists.gforge.statsbiblioteket.dk>" <netarchivesuite-devel at lists.gforge.statsbiblioteket.dk<mailto:netarchivesuite-devel at lists.gforge.statsbiblioteket.dk>>
Date: Thu, 3 Mar 2011 14:24:26 +0100
To: "netarchivesuite-devel at lists.gforge.statsbiblioteket.dk<mailto:netarchivesuite-devel at lists.gforge.statsbiblioteket.dk>" <netarchivesuite-devel at lists.gforge.statsbiblioteket.dk<mailto:netarchivesuite-devel at lists.gforge.statsbiblioteket.dk>>
Subject: [Netarchivesuite-devel] Troubleshooting - Need to see Jetty logging

Hi,

I have trouble running NAS on a specific machine. The web server suddenly started to issue 503 and 404 errors, while other webapps (on a Tomcat server) run just fine. I have started investigating the issue and found out that the problem is obviously with Jetty. However Jetty needs a proper log4J configuration. Currently any log message coming out of Jetty is simply muted, and goes nowhere since no appender is declared. This doesn't help me much ;p

We should configure a separate log for the embedded Jetty server, as it uses lo4j and not commons-logging. Having very little experience with Jetty, I don't have a clear idea about how to do this, so I would appreciate your input.

Best regards,

--
Nicolas Giraud
---------------------------------------------------------------------------------------------
Développeur Archives du Web - Bibliothèque Nationale de France
Web Archiving Developper - National Library of France
---------------------------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://ml.sbforge.org/pipermail/netarchivesuite-devel/attachments/20110303/e27df739/attachment-0002.html>


More information about the Netarchivesuite-devel mailing list