BUG: java.lang.ClassCastException: org.apache.commons.logging.impl.Jdk14Log

Under some circumstances Wildfire seems to throw a java.lang.ClassCastException: org.apache.commons.logging.impl.Jdk14Log

Exception when the AdminConsolePlugin is initialized.

In my specific case it seems to be the case when a custom authentication plugin uses

org.jivesoftware.util.Log for messages and where Wildfire is started up with the out-of-the-box Jetty.

First of all I have ensured that I am running Java 5 and that JAVA_HOME was set correctly.

Then I started to plow through the code and figured out why this happens.

The AdminConsolePlugin on initialization, calls:

System.setProperty(“org.apache.commons.logging.LogFactory”, “org.mortbay.log.Factory”);

It looks like this is too late, probably a log has already been created for the org.apache.commons.logging[/i] default setting.

The only workaround that I could figure out for this problem is to pass an option to the JVM that sets this on startup:

-Dorg.apache.commons.logging.LogFactory=org.mortbay.log.Factory

Regards,

Dieter

PS: That’'s Wildfire 1.5.0 and Wildfire 1.5.1

Could this have been fixed by “[JM-622] - Admin console was failing to startup on unexpected log impl.” ?

LG