Link to home
Start Free TrialLog in
Avatar of rdy1437
rdy1437

asked on

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

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.?
Avatar of Mayank S
Mayank S
Flag of India image

>> i tested the sample service by accessing the url in browser.

What was the result of doing that?
Avatar of rdy1437
rdy1437

ASKER

I already found a solution. I need to redeploy the web service. The problem is that the server is referencing to the wrong jws.
If you make changes to it, you need to re-deploy on the server so that the server can host the new one.
I think my comment can be accepted with a C grade because it explains the reason why that has to be done to solve the problem.
ASKER CERTIFIED SOLUTION
Avatar of Computer101
Computer101
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of rdy1437

ASKER

To the administrator, kindly delete this topic please?  thanks
So my recommendation was not considered?
Avatar of rdy1437

ASKER

Hi modguy, the problem with this topic is that there are part on the stacktrace that pertains to our client and they don't want it to be published on the internet. would it be possible to kindly delete this post?

Thanks in advance


 
Don't worry there is hardly anything there in this Q which pertains to your client information - no source code, etc - just a stack trace which is not much. Half the class names there belong to Axis
Avatar of rdy1437

ASKER

NO, it has, the package name and my client demanded this topic to be deleted.

If there's no way that this topic be deleted, would it be possible then to just edit the topic?
It can be deleted - it can be edited too.
Ask a question here: https://www.experts-exchange.com/Community_Support/Community_Advisor/ and ask to edit your question and delete the client's name if this is a problem.
The accepted solution has no explination...can someone provide detailed suggestions for how to resolve an issue with these types of exceptions...

AxisFault
 faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
 faultSubcode:
 faultString: org.xml.sax.SAXException: Invalid element in PSG.ariba.server.fpdsng.business.award.VendorSocioEconomicIndicatorsType - isAlaskanNativeOwnedCorporationOrFirm
 faultActor:
 faultNode:
 faultDetail:
      {http://xml.apache.org/axis/}stackTrace: org.xml.sax.SAXException: Invalid element in PSG.ariba.server.fpdsng.business.award.VendorSocioEconomicIndicatorsType - isAlaskanNativeOwnedCorporationOrFirm
      at org.apache.axis.encoding.ser.BeanDeserializer.onStartChild(BeanDeserializer.java:260)
      at org.apache.axis.encoding.DeserializationContextImpl.startElement(DeserializationContextImpl.java:963)
      at org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:198)
      at org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:722)
      at org.apache.axis.message.RPCElement.deserialize(RPCElement.java:233)
      at org.apache.axis.message.RPCElement.getParams(RPCElement.java:347)
      at org.apache.axis.client.Call.invoke(Call.java:2272)
      at org.apache.axis.client.Call.invoke(Call.java:2171)
Ask your own questions in your own thread.