You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Te...@HVBIS.com on 2008/05/27 11:16:49 UTC

NoClassDefFoundError: com.sun.org.apache.xerces.internal.dom.DocumentImpl

Hi guys
I am trying out some of the security features (ssaj, wss4j, etc..).
Now my test application/client works just fine on tomcat with jdk 1.5,
how ever when I deploy it on WebSphere I get the following error.

java.lang.NoClassDefFoundError:
com.sun.org.apache.xerces.internal.dom.DocumentImpl

Obviously IBM is using its own jdk 1.5 and the above class is not
included.
I have tried to do a work around by extracting the package structure
from sun jdk1.5 and created my own jar file.
I than included this jar in my application but this did not change
anything.:-(

So I was wondering if anyone out there can give me a tip on how I can
over come this.
The application otherwise without security also works fine on IBM
WebSphere.

Best Regards
Tezcan

RE: NoClassDefFoundError: com.sun.org.apache.xerces.internal.dom.DocumentImpl

Posted by Leo de Blaauw <Le...@qnh.nl>.
Hey,

Seems to me its just a version mismatch between xerces jars on your classpath
probably ? 

Regards,
Leo


-----Original Message-----
From: Tezcan.Dilshener.extern@HVBIS.com
[mailto:Tezcan.Dilshener.extern@HVBIS.com]
Sent: Tue 5/27/2008 11:16 AM
To: users@cxf.apache.org
Subject: NoClassDefFoundError:
com.sun.org.apache.xerces.internal.dom.DocumentImpl
 
Hi guys
I am trying out some of the security features (ssaj, wss4j, etc..).
Now my test application/client works just fine on tomcat with jdk 1.5,
how ever when I deploy it on WebSphere I get the following error.

java.lang.NoClassDefFoundError:
com.sun.org.apache.xerces.internal.dom.DocumentImpl

Obviously IBM is using its own jdk 1.5 and the above class is not
included.
I have tried to do a work around by extracting the package structure
from sun jdk1.5 and created my own jar file.
I than included this jar in my application but this did not change
anything.:-(

So I was wondering if anyone out there can give me a tip on how I can
over come this.
The application otherwise without security also works fine on IBM
WebSphere.

Best Regards
Tezcan


Re: NoClassDefFoundError: com.sun.org.apache.xerces.internal.dom.DocumentImpl

Posted by afreller <af...@csc.com>.
hi all,

We had the same problem here. (aix 5.3 and ibm jdk15 and cxf -> sun saaj).
And after trying endlessly I found a working solution, finally!

My solution is to put the 2 jar files into an endorsed lib directory:
jaxp-ri-1.4.jar and jsr173_api.jar !! and now everything works!

I have to test it in an application server environment (jboss-as with
jbossws-cxf). I 'll let you know if it worked.

Best regards
Alex



dkulp wrote:
> 
> 
> Couple options:
> 
> 1) find a different saaj implementation that works on the IBM jdks.   
> (good luck)
> 
> 2) Grab the sun jaxp jar from:
> http://download.java.net/maven/1/com.sun.xml.parsers/jars/
> and somehow get that added to the classloader that is also grabbing  
> the saaj-impl jar.  Since it's a jaxp thing, it MIGHT need to go into  
> endorsed.   Not really sure though.
> 
> 3) Use the maven shade plugin or asm or jarjar or something have it  
> mangle all references in saaj-impl.jar to  
> com.sun.org.apache.xerces.internal.* to just org.apache.xerces.internal.
> 
> (2) is probably the easiest.
> 
> D
> 
> 
> On May 27, 2008, at 5:16 AM, <Te...@HVBIS.com>
> <Tezcan.Dilshener.extern@HVBIS.com 
>  > wrote:
> 
>> Hi guys
>> I am trying out some of the security features (ssaj, wss4j, etc..).
>> Now my test application/client works just fine on tomcat with jdk 1.5,
>> how ever when I deploy it on WebSphere I get the following error.
>>
>> java.lang.NoClassDefFoundError:
>> com.sun.org.apache.xerces.internal.dom.DocumentImpl
>>
>> Obviously IBM is using its own jdk 1.5 and the above class is not
>> included.
>> I have tried to do a work around by extracting the package structure
>> from sun jdk1.5 and created my own jar file.
>> I than included this jar in my application but this did not change
>> anything.:-(
>>
>> So I was wondering if anyone out there can give me a tip on how I can
>> over come this.
>> The application otherwise without security also works fine on IBM
>> WebSphere.
>>
>> Best Regards
>> Tezcan
> 
> ---
> Daniel Kulp
> dkulp@apache.org
> http://www.dankulp.com/blog
> 
> 
> 
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/NoClassDefFoundError%3A-com.sun.org.apache.xerces.internal.dom.DocumentImpl-tp17486306p19027531.html
Sent from the cxf-user mailing list archive at Nabble.com.


Re: NoClassDefFoundError: com.sun.org.apache.xerces.internal.dom.DocumentImpl

Posted by Daniel Kulp <dk...@apache.org>.
Couple options:

1) find a different saaj implementation that works on the IBM jdks.   
(good luck)

2) Grab the sun jaxp jar from:
http://download.java.net/maven/1/com.sun.xml.parsers/jars/
and somehow get that added to the classloader that is also grabbing  
the saaj-impl jar.  Since it's a jaxp thing, it MIGHT need to go into  
endorsed.   Not really sure though.

3) Use the maven shade plugin or asm or jarjar or something have it  
mangle all references in saaj-impl.jar to  
com.sun.org.apache.xerces.internal.* to just org.apache.xerces.internal.

(2) is probably the easiest.

D


On May 27, 2008, at 5:16 AM, <Te...@HVBIS.com> <Tezcan.Dilshener.extern@HVBIS.com 
 > wrote:

> Hi guys
> I am trying out some of the security features (ssaj, wss4j, etc..).
> Now my test application/client works just fine on tomcat with jdk 1.5,
> how ever when I deploy it on WebSphere I get the following error.
>
> java.lang.NoClassDefFoundError:
> com.sun.org.apache.xerces.internal.dom.DocumentImpl
>
> Obviously IBM is using its own jdk 1.5 and the above class is not
> included.
> I have tried to do a work around by extracting the package structure
> from sun jdk1.5 and created my own jar file.
> I than included this jar in my application but this did not change
> anything.:-(
>
> So I was wondering if anyone out there can give me a tip on how I can
> over come this.
> The application otherwise without security also works fine on IBM
> WebSphere.
>
> Best Regards
> Tezcan

---
Daniel Kulp
dkulp@apache.org
http://www.dankulp.com/blog