Win a copy of Java Persistence with Spring Data and Hibernate this week in the Spring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Tim Cooke
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • Junilu Lacar
  • Rob Spoor
  • Jeanne Boyarsky
Saloon Keepers:
  • Stephan van Hulst
  • Carey Brown
  • Tim Holloway
  • Piet Souris
Bartenders:

Anyone ever seen this before?

 
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
All,
Has anyone ever seen the following kid of error before?
java.lang.NoSuchMethodError:
javax.xml.soap.SOAPMessage.getSOAPBody()Ljavax/xml/soap/SOAPBody;
I get it after I perform the following code snippet:

.
.
.
// Edit to provide your own username and password
String username = args[0];
String password = args[1];
char[] c = password.toCharArray();
PasswordAuthentication passwdAuth =
new PasswordAuthentication( username, c );
Set creds = new HashSet();
creds.add( passwdAuth );
connection.setCredentials( creds );
.
.
.
 
Ranch Hand
Posts: 906
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Do you have a jaxp compliant parser in the classpath of the server where your web service is deployed ?
 
John Meloro
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have downloaded both Xalan and Xerces which *.jar file(s) should I include in my classpath?
 
JeanLouis Marechaux
Ranch Hand
Posts: 906
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by John Meloro:
I have downloaded both Xalan and Xerces which *.jar file(s) should I include in my classpath?


Xerces should be enough
 
John Meloro
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Here is a list of the files:
resolver.jar
xercesImpl.jar // Already in the classpath
xercesSamples.jar
xml-apis.jar
xmlParserAPIs.jar
Which one or ones do I include?
 
John Meloro
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've added all of them with no effect...
 
JeanLouis Marechaux
Ranch Hand
Posts: 906
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
what about xerces.jar ???
 
John Meloro
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I never got it?
 
John Meloro
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Xerces-J-bin.2.6.2.zip does not contain one...
 
JeanLouis Marechaux
Ranch Hand
Posts: 906
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok, sorry, I thought it was.
I just asked you to check the classpath because it seems the kind of error you are facing can be due to a missing method (XML parser) the OSAP engine is looking for.
Nervertheless, can't certify it is really the cause of your problem.
Has your web service ever worked before ? or do you have others services up and running deployed on the same server ?
Which SOAP implementation (server) are you using ?
What do you have in your server classpath ?

BTW, your error message is weird :
java.lang.NoSuchMethodError:
javax.xml.soap.SOAPMessage.getSOAPBody()Ljavax/xml/soap/SOAPBody;

This is Axis, right ?
According to the javadoc, there is no getSOAPBody() method on the SOAPMessage object
[ April 05, 2004: Message edited by: Jean-Louis Marechaux ]
 
John Meloro
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The web service runs okay. I am in the process of writing a class to publish information about how to invoke the web service to a UDDI Registry.
The environment is Windows Xp, TomCat 4.1.30 and Axis.
The class to "publish" the pertinent information is compiled and run from an Ant Script. List below is the classpath information:
<pathelement location="C:\jwsdp-1.3\jaxr\lib\jaxr-api.jar"/>
<pathelement location="C:\code\Java\Web Services Registration\Fibonacci\build\classes"/>
<pathelement location="C:\jwsdp-1.3\jaxr\lib\jaxr-impl.jar"/>
<pathelement location="C:\jwsdp-1.3\jaxb\lib\jaxb-api.jar"/>
<pathelement location="C:\jwsdp-1.3\jaxb\lib\jaxb-impl.jar"/>
<pathelement location="C:\jwsdp-1.3\jaxb\lib\jaxb-libs.jar"/>
<pathelement location="C:\jwsdp-1.3\jwsdp-shared\lib\relaxngDatatype.jar"/>
<pathelement location="C:\jwsdp-1.3\jwsdp-shared\lib\namespace.jar"/>
<pathelement location="C:\jwsdp-1.3\jwsdp-shared\lib\activation.jar"/>
<pathelement location="C:\jwsdp-1.3\jwsdp-shared\lib\mail.jar"/>
<pathelement location="C:\jwsdp-1.3\jwsdp-shared\lib\.jar"/>
<pathelement location="C:\code\Axis\axis-1_1\lib\axis.jar"/>
<pathelement location="C:\code\Axis\axis-1_1\lib\commons-logging.jar"/>
<pathelement location="C:\code\Axis\axis-1_1\lib\commons-discovery.jar"/>
<pathelement location="C:\code\Axis\axis-1_1\lib\saaj.jar"/>
<pathelement location="C:\jwsdp-1.3\saaj\lib\saaj-api.jar"/>
<pathelement location="C:\jwsdp-1.3\saaj\lib\saaj-impl.jar.jar"/>
<pathelement location="C:\jwsdp-1.3\jaxp\lib\endorsed\jaxp-api.jar"/>
<pathelement location="C:\jwsdp-1.3\jaxp\lib\endorsed\sax.jar"/>
<pathelement location="C:\jwsdp-1.3\jaxp\lib\endorsed\dom.jar"/>
<pathelement location="C:\jwsdp-1.3\jaxp\lib\endorsed\xercesImpl.jar"/>
<pathelement location="C:\jwsdp-1.3\jaxp\lib\endorsed\xalan.jar"/>
<pathelement location="C:\code\XML\Xerces 2.6.2\xerces-2_6_2\resolver.jar"/>
<pathelement location="C:\code\XML\Xerces 2.6.2\xerces-2_6_2\xml-apis.jar"/>
<pathelement location="C:\code\XML\Xerces 2.6.2\xerces-2_6_2\xmlParserAPIs.jar"/>
<pathelement location="C:\code\XML\Xerces 2.6.2\xercex-2_6_2\xercesImpl.jar"/>
Most everything comes from jwsdp-1.3.
 
Get meta with me! What pursues us is our own obsessions! But not this tiny ad:
The Low Tech Laboratory Movie Kickstarter is LIVE NOW!
https://www.kickstarter.com/projects/paulwheaton/low-tech
reply
    Bookmark Topic Watch Topic
  • New Topic