Forum Discussion

VirtualVAT's avatar
Occasional Contributor
11 years ago

strange SoapUI mock service response "error 500"

I've got a strange problem - some time ago (may be month) SoapUI began to respond with error 500 instead of proper answer.
Here is the request example:

<env:Envelope xmlns:env="" xmlns:xsd="">
<defaultNS1:NewOperation xmlns:bpws="" xmlns:defaultNS="" xmlns:defaultNS1="" xmlns:ns8="">

Note that instead of "env" "envelope" prefix can be used as well but anyway the following answer is given by the SoapUI stab:

<soapenv:Envelope xmlns:soapenv="">
<faultstring>java.lang.RuntimeException: net.sf.saxon.trans.XPathException: XPath syntax error at char 17 in {/soapenv:Envelope/soapenv:Body}:
Prefix soapenv has not been declared</faultstring>

This very strange problem because earlier this request worked and now all SoapUI version responding this problem (4.5.2, 4.5.0, 4.0.0 versions tested) - it appears like e.g. some dynamically accessed schema has been updated and SoapUI started to repond like this since that time.
Attaching the SoapUI project to reproduce this and the WSDL which is used to generate the request and stub.
To reproduce start the ExtAsynchResponseSOAP MockService and execute the WS using either the ExtAsynchResponseSOAP\NewOperation\test1 or the test2 requests. Note that even the defaualt request generated by SoapUI automatically gives the same problem.

6 Replies

  • nmrao's avatar
    Champion Level 3
    From the screen shots, it seems that there is an issue with the namespaces in your request. Please check.
    You may do : on the request xml, type Alt+V which will tell you the validation error.
  • VirtualVAT's avatar
    Occasional Contributor
    Yeah, thanks, I know what exaclty it means - but there are no validation errors. As I mentioned I used to execute such requests previously many many times successfully.
    Moreover - the default request (of course valid one) gives this problem too!
    I've updated my snapshot added validation result message box there.
    The request is posted in the first code section - you may check it - it is valid proper request.
  • nmrao's avatar
    Champion Level 3
    Another thing you can check on the service interface whether your service supports soap 1.1 or soap 1.2 binding. Based on the service support, it needs to be selected the right soap binding and note that namespace will change between the two, just incase for your information.
  • VirtualVAT's avatar
    Occasional Contributor
    My test is SoapUI -> SoapUI call. If I'm not mistaken it supports both; moreover, I believe, by default is generated supported by itself one
    In the same time on my development environmet I started to see this problem just without rhyme or reason even with the software versions that were well tested in the past with same requests. SoapUI started to respond like that some time ago without rhyme or reason. I thought it's due to recent upgrade to 4.5.2 but no - I checked previous versions and the same picture I see with 4.5.0 and 4.0.0.
  • VirtualVAT's avatar
    Occasional Contributor
    I tried some another WSDL and it works. So the problem is reproducible with the given WSDL at least.
    It was generated by the Eclipse and conforms to the WS-I.