Forum Discussion

jeffwood's avatar
jeffwood
Contributor
17 years ago

Unexpected end of file after null

This error occurs when the "Enable Mock HTTP Log" in the HTTP Settings preference page in enabled. 

  com.eviware.soapui.impl.wsdl.mock.DispatchException: org.apache.xmlbeans.XmlException: error: Unexpected end of file after null
      at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:396)
      at com.eviware.soapui.monitor.JettyMockEngine$ServerHandler.handle(JettyMockEngine.java:699)
      at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
      at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
      at org.mortbay.jetty.Server.handle(Server.java:324)
      at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:535)
      at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:880)
      at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:747)
      at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
      at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
      at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409)
      at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:520)
  Caused by: org.apache.xmlbeans.XmlException: error: Unexpected end of file after null
      at org.apache.xmlbeans.impl.store.Locale$SaxLoader.load(Locale.java:3486)
      at org.apache.xmlbeans.impl.store.Locale.parse(Locale.java:712)
      at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:696)
      at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:683)
      at org.apache.xmlbeans.impl.schema.SchemaTypeLoaderBase.parse(SchemaTypeLoaderBase.java:208)
      at org.apache.xmlbeans.XmlObject$Factory.parse(XmlObject.java:580)
      at com.eviware.soapui.impl.wsdl.mock.WsdlMockRequest.getRequestXmlObject(WsdlMockRequest.java:260)
      at com.eviware.soapui.impl.wsdl.mock.WsdlMockRequest.initPostRequest(WsdlMockRequest.java:146)
      at com.eviware.soapui.impl.wsdl.mock.WsdlMockRequest.(WsdlMockRequest.java:101)
      at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:376)
      ... 11 more
  Caused by: org.xml.sax.SAXParseException: Unexpected end of file after null
      at org.apache.xmlbeans.impl.piccolo.xml.Piccolo.reportFatalError(Piccolo.java:1038)
      at org.apache.xmlbeans.impl.piccolo.xml.Piccolo.parse(Piccolo.java:723)
      at org.apache.xmlbeans.impl.store.Locale$SaxLoader.load(Locale.java:3454)
      ... 20 more
Fri Nov 20 09:08:45 EST 2009:ERROR:An error occured [org.apache.xmlbeans.XmlException: error: Unexpected end of file after null], see error log for details
Fri Nov 20 09:08:46 EST 2009:ERROR:An error occured [WRITER], see error log for details

8 Replies

  • Its a little strange.  It works on the first transaction after SOAP UI is started then fails on subsequent  transactions. 

    I have seen the "end of file" error before when multiple "Mock Response Steps" were open on the same port and the flag was disabled.  The first response would succeed and the second would fail with the error.  I assumed at the time that each response step started a temporary mock service on the port but all responses were queued on the first service that started.  Thus, when the first response completed and shut it service down, the second service had no response prepared for the second incoming request.  But I didn't have the time to check the source code so I switched to using the "Mock Service".

    However, the "Mock Service" also fails when the flag has been set so my assumption has to change.  I imagine that the code that is writing the transaction to the log is closing or cleaning up something that it shouldn't be. 
  • dmoss2's avatar
    dmoss2
    New Contributor
    Any success with this issue, I am having the same issue. Using TCPMON I terminate the session and then my request always works. 
  • No not yet.  When i get the time I am going to try logging the responses in a groovy script.  Not sure that helps you though.
  • Hi guys,

    we need to fix this for you... just to recap; are you getting this even when the MockService logging is disabled in the global http preferences?

    regards!

    /Ole
    eviware.com
  • For the Mock Service, no I do not see this when the flag is disabled.  But two mock response steps using the same port and service name (waiting on two different requests) will cause this error if they have the same start step even if the logging is disabled.
  • dmoss2's avatar
    dmoss2
    New Contributor
    I turn the global http mock service log option off and it will perform as expected.
  • Hi Support,

    did you fix this problem?
    I have the same problem with SOAP-Monitor. soupUI-Version 3.0.1 and 3.0.2.

    Soap-Monitor runs on my computer under WindowsXP-OS. One Server calls Web-Service from LinuxSuse11.1 and sends Requests to Soap-Monitor per SSL. Soap-Monitor forwards all messages to one another Web-Service on the same LinuxSuse11.1-Machine.
    It works only with some our Web-Services, not with all, but it work.
    As soon as I connect to company network from outside per VPN, my computer changes IP-Address and I change the routing in host-file on SuseLinux it is not working any more and
    Soap-Monitor brings errors:

    11:37:59,843 ERROR [SoapUI] An error occured [error: Unexpected end of file afte
    r null], see error log for details

    And hier are detailes from Log:

    2010-01-21 11:37:59,843 ERROR [errorlog] org.apache.xmlbeans.XmlException: error: Unexpected end of file after null
    org.apache.xmlbeans.XmlException: error: Unexpected end of file after null
    at org.apache.xmlbeans.impl.store.Locale$SaxLoader.load(Locale.java:3486)
    at org.apache.xmlbeans.impl.store.Locale.parse(Locale.java:712)
    at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:696)
    at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:683)
    at org.apache.xmlbeans.impl.schema.SchemaTypeLoaderBase.parse(SchemaTypeLoaderBase.java:208)
    at org.apache.xmlbeans.XmlObject$Factory.parse(XmlObject.java:580)
    at com.eviware.soapui.impl.wsdl.monitor.JProxyServletWsdlMonitorMessageExchange.findOperation(JProxyServletWsdlMonitorMessageExchange.java:288)
    at com.eviware.soapui.impl.wsdl.monitor.JProxyServletWsdlMonitorMessageExchange.parseRequestData(JProxyServletWsdlMonitorMessageExchange.java:238)
    at com.eviware.soapui.impl.wsdl.monitor.JProxyServletWsdlMonitorMessageExchange.prepare(JProxyServletWsdlMonitorMessageExchange.java:139)
    at com.eviware.soapui.impl.wsdl.monitor.SoapMonitor$StackProcessor.processMessage(SoapMonitor.java:1047)
    at com.eviware.soapui.impl.wsdl.monitor.SoapMonitor$StackProcessor.run(SoapMonitor.java:1030)
    at java.lang.Thread.run(Thread.java:619)
    Caused by: org.xml.sax.SAXParseException: Unexpected end of file after null
    at org.apache.xmlbeans.impl.piccolo.xml.Piccolo.reportFatalError(Piccolo.java:1038)
    at org.apache.xmlbeans.impl.piccolo.xml.Piccolo.parse(Piccolo.java:723)
    at org.apache.xmlbeans.impl.store.Locale$SaxLoader.load(Locale.java:3454)
    ... 11 more

    Mike