Saturday, August 7, 2010

java.lang.NoSuchMethodError: javax.xml.soap.SOAPFault.setFaultCode(Ljavax/xml/namespace/QName;)V

java.lang.NoSuchMethodError: javax.xml.soap.SOAPFault.setFaultCode(Ljavax/xml/namespace/QName;)V

We faced this issue on jdeveloper10g version[not in Jdeveloper11g]

1. jdeveloper10 already had saaj-api.jar under C:\JDeveloper\webservices\lib directory
    This doesn't contain setFaultCode(javax/xml/namespace/QName qname) argument.
    It just had setFaultCode(String s) method

2. From my application I supplied javax.xml.soap_1.3.1.0.jar which contains the method with QName argument.But as jvm already loaded saaj-api.jar ahead of the application supplied one, it is complaining 'java.lang.NoSuchMethodError' exception.

3. jdeve11g doesn't have this saaj-api.jar in wbservices\lib folder.So it worked.
To resolve the issue for time being, I deleted the saaj-api.jar from the webservices\lib directory to resolve the issue.We have to find the acceptable way....

Hope you'll like it.

1 comment:

Anonymous said...

on the target.Excellent