Axis2
  1. Axis2
  2. AXIS2-529

rg.apache.axis2.AxisFault: org.apache.axis2.AxisFault: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog error

    Details

    • Type: Wish Wish
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Cannot Reproduce
    • Affects Version/s: 0.94
    • Fix Version/s: None
    • Component/s: om
    • Labels:
      None
    • Environment:
      os : window2000xp
      jdk : jdk1.4.2
      was : jeus4.2 (made in korea)

      Description

      i'm using axis2(0.94 or 0.95) . i am having the follow problem when i call my test web service
      may by xml parsing error!.. please help me!!!! ...

      org.apache.axis2.AxisFault: org.apache.axis2.AxisFault: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col

      {unknown-source}]: [1,0]; nested exception is:
      org.apache.ws.commons.om.OMException: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col {unknown-source}

      ]: [1,0]
      at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:296)
      at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:167)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:234)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:269)
      at jeus.servlet.engine.ServletWrapper.executeServlet(ServletWrapper.java:157)
      at jeus.servlet.engine.ServletWrapper.execute(ServletWrapper.java:138)
      at jeus.servlet.engine.HttpRequestProcessor.run(HttpRequestProcessor.java:114)
      Caused by: org.apache.ws.commons.om.OMException: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col

      {unknown-source}]: [1,0]
      at org.apache.ws.commons.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:279)
      at org.apache.ws.commons.soap.impl.builder.StAXSOAPModelBuilder.getSOAPEnvelope(StAXSOAPModelBuilder.java:137)
      at org.apache.ws.commons.soap.impl.builder.StAXSOAPModelBuilder.identifySOAPVersion(StAXSOAPModelBuilder.java:113)
      at org.apache.ws.commons.soap.impl.builder.StAXSOAPModelBuilder.<init>(StAXSOAPModelBuilder.java:90)
      at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:221)
      ... 6 more
      Caused by: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col {unknown-source}

      ]: [1,0]
      at com.ctc.wstx.sr.StreamScanner.throwUnexpectedEOF(StreamScanner.java:559)
      at com.ctc.wstx.sr.BasicStreamReader.handleEOF(BasicStreamReader.java:2094)
      at com.ctc.wstx.sr.BasicStreamReader.nextFromProlog(BasicStreamReader.java:2000)
      at com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamReader.java:1010)
      at org.apache.ws.commons.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:196)
      ... 10 more
      ; nested exception is:
      java.lang.Exception: org.apache.axis2.AxisFault: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col

      {unknown-source}]: [1,0]; nested exception is:
      org.apache.ws.commons.om.OMException: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col {unknown-source}

      ]: [1,0]
      at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:296)
      at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:167)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:234)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:269)
      at jeus.servlet.engine.ServletWrapper.executeServlet(ServletWrapper.java:157)
      at jeus.servlet.engine.ServletWrapper.execute(ServletWrapper.java:138)
      at jeus.servlet.engine.HttpRequestProcessor.run(HttpRequestProcessor.java:114)
      Caused by: org.apache.ws.commons.om.OMException: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col

      {unknown-source}]: [1,0]
      at org.apache.ws.commons.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:279)
      at org.apache.ws.commons.soap.impl.builder.StAXSOAPModelBuilder.getSOAPEnvelope(StAXSOAPModelBuilder.java:137)
      at org.apache.ws.commons.soap.impl.builder.StAXSOAPModelBuilder.identifySOAPVersion(StAXSOAPModelBuilder.java:113)
      at org.apache.ws.commons.soap.impl.builder.StAXSOAPModelBuilder.<init>(StAXSOAPModelBuilder.java:90)
      at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:221)
      ... 6 more
      Caused by: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col {unknown-source}

      ]: [1,0]
      at com.ctc.wstx.sr.StreamScanner.throwUnexpectedEOF(StreamScanner.java:559)
      at com.ctc.wstx.sr.BasicStreamReader.handleEOF(BasicStreamReader.java:2094)
      at com.ctc.wstx.sr.BasicStreamReader.nextFromProlog(BasicStreamReader.java:2000)
      at com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamReader.java:1010)
      at org.apache.ws.commons.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:196)
      ... 10 more

      at org.apache.axis2.description.OutInAxisOperationClient.execute(OutInAxisOperation.java:276)
      at org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:445)
      at org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:400)
      at client.test.mtom.MTOMServiceClient.process(MTOMServiceClient.java:70)
      at client.test.mtom.MTOMServiceClient.main(MTOMServiceClient.java:40)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90)
      Caused by: java.lang.Exception: org.apache.axis2.AxisFault: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col

      {unknown-source}]: [1,0]; nested exception is:
      org.apache.ws.commons.om.OMException: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col {unknown-source}

      ]: [1,0]
      at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:296)
      at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:167)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:234)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:269)
      at jeus.servlet.engine.ServletWrapper.executeServlet(ServletWrapper.java:157)
      at jeus.servlet.engine.ServletWrapper.execute(ServletWrapper.java:138)
      at jeus.servlet.engine.HttpRequestProcessor.run(HttpRequestProcessor.java:114)
      Caused by: org.apache.ws.commons.om.OMException: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col

      {unknown-source}]: [1,0]
      at org.apache.ws.commons.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:279)
      at org.apache.ws.commons.soap.impl.builder.StAXSOAPModelBuilder.getSOAPEnvelope(StAXSOAPModelBuilder.java:137)
      at org.apache.ws.commons.soap.impl.builder.StAXSOAPModelBuilder.identifySOAPVersion(StAXSOAPModelBuilder.java:113)
      at org.apache.ws.commons.soap.impl.builder.StAXSOAPModelBuilder.<init>(StAXSOAPModelBuilder.java:90)
      at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:221)
      ... 6 more
      Caused by: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
      at [row,col {unknown-source}

      ]: [1,0]
      at com.ctc.wstx.sr.StreamScanner.throwUnexpectedEOF(StreamScanner.java:559)
      at com.ctc.wstx.sr.BasicStreamReader.handleEOF(BasicStreamReader.java:2094)
      at com.ctc.wstx.sr.BasicStreamReader.nextFromProlog(BasicStreamReader.java:2000)
      at com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamReader.java:1010)
      at org.apache.ws.commons.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:196)
      ... 10 more

      at org.apache.ws.commons.soap.impl.llom.SOAPFaultImpl.getException(SOAPFaultImpl.java:137)
      at org.apache.axis2.description.OutInAxisOperationClient.execute(OutInAxisOperation.java:272)
      ... 9 more

      Process finished with exit code 0

        Activity

        Hide
        Davanum Srinivas added a comment -

        not enough information to recreate the problem Please include wsdl tcpmon traces etc.

        Show
        Davanum Srinivas added a comment - not enough information to recreate the problem Please include wsdl tcpmon traces etc.
        Hide
        Asankha C. Perera added a comment -

        This seems to occur with escaped XML content within a SOAP response (e.g. attached below), where the escaped section is not properly extracted as XML content, but treated as a String..

        i.e. The "<StockQuotes>.......</StockQuotes>" section could be seen as a String within the debugger for the following message, and hence a subsequent XSLT transformation on this message results in the woodstox error "WstxEOFException: Unexpected EOF in prolog" - Which is due to the fact that the XSLT failed because of the above reason creating an empty result document.

        <?xml version="1.0" encoding="utf-8"?>
        <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
        <soap:Body>
        <GetQuoteResponse xmlns="http://www.webserviceX.NET/">
        <GetQuoteResult><StockQuotes><Stock><Symbol>IBM</Symbol><Last>82.35</Last><Date>5/12/2006</Date><Time>4:00pm</Time><Change>-0.07</Change><Open>82.47</Open><High>83.69</High><Low>82.30</Low><Volume>5685700</Volume><MktCap>127.7B</MktCap><PreviousClose>82.46</PreviousClose><PercentageChange>-0.08%</PercentageChange><AnnRange>72.52 - 89.94</AnnRange><Earns>5.121</Earns><P-E>16.10</P-E><Name>INTL BUSINESS MAC</Name></Stock></StockQuotes></GetQuoteResult>
        </GetQuoteResponse>
        </soap:Body>
        </soap:Envelope>

        Show
        Asankha C. Perera added a comment - This seems to occur with escaped XML content within a SOAP response (e.g. attached below), where the escaped section is not properly extracted as XML content, but treated as a String.. i.e. The "<StockQuotes>.......</StockQuotes>" section could be seen as a String within the debugger for the following message, and hence a subsequent XSLT transformation on this message results in the woodstox error "WstxEOFException: Unexpected EOF in prolog" - Which is due to the fact that the XSLT failed because of the above reason creating an empty result document. <?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <soap:Body> <GetQuoteResponse xmlns="http://www.webserviceX.NET/"> <GetQuoteResult><StockQuotes><Stock><Symbol>IBM</Symbol><Last>82.35</Last><Date>5/12/2006</Date><Time>4:00pm</Time><Change>-0.07</Change><Open>82.47</Open><High>83.69</High><Low>82.30</Low><Volume>5685700</Volume><MktCap>127.7B</MktCap><PreviousClose>82.46</PreviousClose><PercentageChange>-0.08%</PercentageChange><AnnRange>72.52 - 89.94</AnnRange><Earns>5.121</Earns><P-E>16.10</P-E><Name>INTL BUSINESS MAC</Name></Stock></StockQuotes></GetQuoteResult> </GetQuoteResponse> </soap:Body> </soap:Envelope>
        Hide
        john W added a comment -

        I'm experiencing this issue as well. What was done to resolve it?

        Show
        john W added a comment - I'm experiencing this issue as well. What was done to resolve it?

          People

          • Assignee:
            Unassigned
            Reporter:
            lee myungsun
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development