WstxParsingException: "Expected a text token, got START_ELEMENT"

Posted by lasombra on Stack Overflow See other posts from Stack Overflow or by lasombra
Published on 2010-04-15T08:19:49Z Indexed on 2010/04/15 8:23 UTC
Read the original article Hit count: 1237

Filed under:
|
|

I have a stub generated by WSDL2Java. I send a request and the answer that comes back (used tcptrace) looks fine. However, an AxisFault is thrown:

org.apache.axis2.AxisFault: com.ctc.wstx.exc.WstxParsingException: Expected a text token, got START_ELEMENT.
 at [row,col {unknown-source}]: [4,1313]
        at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430)
        at org.tempuri.MyStub.fromOM(MyStub.java:1726)
        at org.tempuri.MyStub.acceptResults(MyStub.java:612)

The corresponding code in MyStub.java looks like:

607: org.apache.axis2.context.MessageContext _returnMessageContext = _operationClient
608:         .getMessageContext(org.apache.axis2.wsdl.WSDLConstants.MESSAGE_LABEL_IN_VALUE);
609: org.apache.axiom.soap.SOAPEnvelope _returnEnv = _returnMessageContext
610:        .getEnvelope();
611: 
612: java.lang.Object object = fromOM(_returnEnv.getBody()
613:                                  .getFirstElement(),
614:                                  org.tempuri.AcceptQcResultsResponse.class,
615:                                  getEnvelopeNamespaces(_returnEnv));

How do I find out which token is meant by the error? I have [row,col {unknown-source}]: [4,1313] but I don't know how to use that information.

© Stack Overflow or respective owner

Related posts about web-services

Related posts about axis2