commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tejas Bavishi" <>
Subject RE: Really stuck on NoClassDefFoundErrororg/apache/commons/logging/LogFactory
Date Thu, 22 Jun 2006 11:33:12 GMT

Just trying to help you with the problem :

The test case is run within Eclipse. The web service is run on JBoss.

The stack trace shows that the junit runs HttpClient class that looks for
LogFactory class. As per the stacktrace, the commons logging jar should be
included in the Eclipse build path. This should be done in the Eclipse -->
Project --> Properties --> Java Build Path

Does this work ?

Thanks & regards

-----Original Message-----
From: Simon Kitching []
Sent: Thursday, June 22, 2006 4:44 PM
To: Jakarta Commons Users List
Subject: Re: Really stuck on

Hi Robert,

On Wed, 2006-06-21 at 19:40 -0300, robert lazarski wrote:
> Hi all,
> I've been googling all day and I'm stuck. I'm trying to run a junit
> test case in eclipse 3.1 calling an axis2 web service running in
> jboss, that depends on HttpClient. I get this stack trace:
> java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory
> 	at org.apache.commons.httpclient.HttpClient.<clinit>(
> 	at junit.framework.TestSuite.runTest(
> 	at
> 	at
> 	at
> 	at
> I'm running 1.04, but tried to upgrade to 1.1 with no luck. I tried
> butting the commons.logging jar under jdk1.5.0_03/jre/lib/ext - no
> luck. I tried this, still no luck:
>     protected void setUp() throws Exception {
>     }
> I'm out of ideas. Any help very much appreciated. I just need this
> junit test case to run in eclipse.

This kind of problem is what the recent logging-1.1 release was aimed at
dealing with.

JBoss does some odd things with commons-logging. Junit and eclipse also
do some odd stuff with classpaths. As a result, things can indeed get
quite confusing. I suspect that the 1.1 release will solve the problem
if you can just find the right place to deploy it.

If you set system property
then logging 1.1 will generate output to stdout. If you don't get any
output, then you have probably not found the right place to deploy the

Sorry I can't be more specific than that, but it's a complicated
scenario you've got.



To unsubscribe, e-mail:
For additional commands, e-mail:
World-Wide Partnerships. World-Class Solutions.

This e-mail message may contain proprietary, confidential or legally
privileged information for the sole use of the person or entity to
whom this message was originally addressed. Any review, e-transmission
dissemination or other use of or taking of any action in reliance upon
this information by persons or entities other than the intended
recipient is prohibited. If you have received this e-mail in error
kindly delete  this e-mail from your records. If it appears that this
mail has been forwarded to you without proper authority, please notify
us immediately at and delete this mail. 

View raw message