jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jukka Zitting <ju...@zitting.name>
Subject Re: [PATCH] log4j to commons-logging conversion
Date Wed, 16 Feb 2005 11:23:16 GMT
Hi,

Nice job Manoj!

Stefan's comments:
> thank you very much for the patch! the changes look
> trivial enough but what i am a bit worried about is 
> the sheer scope of the changes as almost every 
> single file has been touched.

I checked through the changes and applied the patch to my source tree.
It also works without problems in my private RMI/XML test setup. (But
I'm not a heavy user of the logging features.)

I also tried removing the log4j dependency after this patch, but it
resulted in quite a few unit test failures. It seems that at least the
cqfs-jackrabbit package depends on log4j, so Manoj's patch doesn't yet
fully remove the log4j dependency from Jackrabbit.

Anyhow, I'd vote for applying the patch as I see no design or
implementation problems with it.

> one question that i have for example is about 
> configuration. how is commons-logging being
> configured?

See http://jakarta.apache.org/commons/logging/guide.html#Configuration

If no other configuration is given, commons-logging will first check if
the log4j classes are available and use standard log4j configuration.
Otherwise, if running on JVM 1.4+, then the standard JDK logging
mechanism is used. Finally a SimpleLog fallback is used if no other
logging mechanism is configured or available.

> also, i assume that log4j would not be a compile-time 
> dependency anymore, but still a run-time dependency.
> is that correct?

Yes, if you want to use log4j for the actual logging. You just include
log4j in the classpath and provide proper configuration. (Note however
the point about cqfs-jackrabbit.)

It's up to the user (or packager) to select the logging facility to use.

Best regards,

Jukka Zitting



Mime
View raw message