• 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
  • Paul Clapham
  • Jeanne Boyarsky
  • Liutauras Vilda
Sheriffs:
  • Rob Spoor
  • Bear Bibeault
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:
  • Frits Walraven
  • Himai Minh

org.xml.sax.SAXParseException

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
Am new to web services and was able to make a simple web service that returned a string back work. Am implementing the web service in Java, running tomcat,using Axis. Then I wanted to return an object instead of a simple data type. I was able to create the wsdl files and the supporting classes. I created the jar and successfully deployed them too. When I invoke the service through a client program following is the message I get:
org.xml.sax.SAXParseException: The root element is required in a well-formed document.
Any thoughts on how to fix it?
Sridhar.
 
Sridhar Sreenivasan
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If anyone is actuallu looking into it,please stop as I've figured it myself and it is working now.Thanks for those who were trying to figure it out.
Sridhar.
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sridhar,
Do you remember how you fixed this, because Im facing same problem.
Thanks in advance,
Kali
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

org.xml.sax.SAXParseException: The root element is required in a well-formed document.



This means that the start of the character stream fed to the parser was not formatted as an XML document - there are many possible causes. For example the server may be sending an error message in plain text.

I suggest using TCPMON or similar tool to look at the actual message content - that should give you a clue.

Bill
 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey Sridhar! Could you please help me to solve the similar type of issue. Actually I am facing the same issue.
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic