David Legg wrote:
I'm sorry, I forgot to respond earlier. Find my comments inline.
This is great!... but my quest to use slf4j as my logging solution is
still not fulfilled. The question now is why when I run 'mvn
package' or 'mvn jetty:run' when in the myblock directory does maven
insist on placing the commons-logging and log4j jar files into
WEB-INF/lib even though I've expressly excluded them?
What WEB-INF/lib directory are you referring to? Is it
./target/rcl/webapp/WEB-INF/lib or is it the WEB-INF/lib directory of
the web application Maven module?
If it is the first, the answer is that the wrapper web application (a
minimal web application that wraps a block) uses the reloading
classloader (commons-jci.jar) which has a dependency on commons-logging.
It is the first.
I don't understand... if the wrapper web application depends on
commons-logging and makes arrangements to load the commons-logging jar
into the classpath it should clash when I attempt to load the
jcl-over-slf4j jar file
not necessarily, though I'm not sure what exactly is happening. My
guess: When the reloading classloader is used, most of the libraries are
loaded by a separate classloader (-> the reloading classloader) than the
context classloader. The context classloader only loads the libraries
that are necessary to use the reloading classloader itself.
which is supposed to replace the classes in
commons-logging so that messages get forwarded to the slf4j logging
framework... but they don't!
If I change the dependencies section of myblock/pom.xml to the
following, then when I run mvn jetty:run I get bucketloads of debug
messages on my console... which I think means SLF4J is working... or
maybe I'm deceiving myself!
--
Reinhard Pötz Managing Director, {Indoqa} GmbH
http://www.indoqa.com/en/people/reinhard.poetz/
Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member [EMAIL PROTECTED]
________________________________________________________________________
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]