troubleshooting Question

Axis error " org.xml.sax.SAXException: Invalid element in Invalid element in"

Avatar of rdy1437
rdy1437 asked on
Java EE
14 Comments1 Solution5114 ViewsLast Modified:
Hi,

I'm getting error when my code get the soap response. The error is
...
AxisFault
 faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
 faultSubcode:
 faultString: org.xml.sax.SAXException: Invalid element in xml.wsdl.TargetType - Type
 faultActor:
 faultNode:
 faultDetail:
      {http://xml.apache.org/axis/}stackTrace:org.xml.sax.SAXException: Invalid element in xml.wsdl.TargetType - Type
      at org.apache.axis.encoding.ser.BeanDeserializer.onStartChild(BeanDeserializer.java:258)
      at org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
      at org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
      at org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
      at org.apache.axis.encoding.DeserializerImpl.startElement(DeserializerImpl.java:369)
      at org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1048)
      at org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
      at org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
      at org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
      at org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
      at org.apache.axis.client.Call.invoke(Call.java:2448)
      at org.apache.axis.client.Call.invoke(Call.java:2347)
      at org.apache.axis.client.Call.invoke(Call.java:1804)
      at XStubSoapStub.listInterceptions(XStubSoapStub.java:361)
      at QueryCommand.execute(QueryCommand.java:102)
      at BaseTarget.execute(BaseTarget.java:30)
      at XTarget.execute(XTarget.java:34)
      at XMsgHandler.run(XMsgHandler.java:50)
      at java.lang.Thread.run(Thread.java:595)

      {http://xml.apache.org/axis/}hostname:st-louis
......

Here is my procedure:
-  I have a WSDL and I used WSDL2java (,options -a -u) of Axis1.4 to generate java classes. Then I did a sample service impl (dummy) out from generated interface code. While changes done in any generated classes.
- I deployed my sample service impl using Axis instant deploy, that's by, removing the packge declrtn, renaming the file into .jws and put it inside [tomcat]\webapps\testWS\
- i tested the sample service by accessing the url in browser.
- I create a sample client and access my sample service
- And the error dislayed.
-I already checked it in the web but no direct answers.  

Add. Questions:
> Is my way of deployment affected the soap response? if no, why my soap request seem no multiRef while in response has lots of it.?
> Or there is somthing wrong in the generated code or in my procedure.?
ASKER CERTIFIED SOLUTION
Computer101

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 14 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 14 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros