jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ian Boston <...@tfd.co.uk>
Subject Re: Exception in thread "main" java.lang.NoClassDefFoundError: javax/jcr/Repository
Date Tue, 21 Jul 2009 12:04:24 GMT

On 21 Jul 2009, at 12:03, simer anand wrote:

> On 7/21/09, Ian Boston <ieb@tfd.co.uk> wrote:
>>
>> What classloader environment are you running in ? OSGi ?
>>
>> NoClassDefFoundError means that the Class was found but the byte  
>> array
>> associated with the class could not be loaded (hence no definition).
>> If the class is not in your classpath, then you will normally get a
>> ClassNotFoundException.
>>
>> The only time I have seen a NoClassDefFoundError is
>> a) when the jar is corrupt or
>> b) in OSGi where there is no bundle import (in the manifest)  on the
>> package in question.
>>
>> OSGi classloaders apply rules to finding and loading classes, you  
>> may be in
>> an environment with similar rules.
>>
>> HTH
>> Ian
>>
>>
>> On 21 Jul 2009, at 08:17, simer anand wrote:
>>
>> ya
>>> but i do have have jcr-1.0.jar in my classpath
>>> and javax/jcr/respository.class is within it
>>
>>
>
> how to know what class loader i'm using


What are you running ?
a java application  (eg java -jar myjar.jar)
a webapp inside tomcat or some other container
something else, like eclipse.


Mime
View raw message