Bug 34139

Summary: org.apache.catalina.realm.RealmBase.main() requires JMX and log4j
Product: Tomcat 5 Reporter: David Tiller <dtiller>
Component: CatalinaAssignee: Tomcat Developers Mailing List <dev>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P4    
Version: 5.5.7   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   

Description David Tiller 2005-03-22 22:24:53 UTC
The Tomcat 5.5 documentation states that catalina.jar is the only jar required
on the classpath to run org.apache.catalina.realm.RealmBase.main. (See
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/realm-howto.html#Digested%20Passwords)

UNDER 5.0.28:
If run with only catalina.jar, you get:

Exception in thread "main" java.lang.NoClassDefFoundError:
javax/management/MBeanRegistration

Adding the $TOMCAT_HOME/bin/jmx.jar to the classpath fixes this exception, but
then you get:

Exception in thread "main" java.lang.NoClassDefFoundError:
org/apache/commons/logging/LogFactory

Adding $TOMCAT_HOME/bin/commons-logging-api.jar permits the program to run properly.

UNDER 5.5.7:
No jar distributed with Tomcat 5.5.7 contains
javax/management/MBeanRegistration. If you add 5.0.28's jmx.jar and 5.5.7's
commons-logging-api.jar, it works.

Please correct the documentation (which is incorrect for Tomcat 5.5) and perhaps
include JMX.jar with the latest distribution.
Comment 1 Yoav Shapira 2005-03-24 15:43:24 UTC
OK, docs corrected.  There are license issues with including just any JMX jar,
but we do include an implementation with the distro.