Menu

#680 Wrong Content-Type text/html instead of text/xml on MockService fault

v1.0 (example)
open
nobody
None
5
2015-07-29
2015-07-29
mauromol
No

Using SoapUI 5.2.0 with Java 1.8.0_51.
I've created a MockService. My client is invoking it to send a request containing an attachment using MTOM. The SoapUI MockService returns a fault, probably because my client performs a bad request.

The problem is that this fault has the wrong content/type: text/html instead of text/xml! This prevents my client to handle the fault correctly. I had to use TCPMon to see the actual problem!!

Here is the response produced by my SoapUI MockService. As you can see, the Content-Type header is wrong!

HTTP/1.1 500 Internal Server Error
Content-Type: text/html; charset=iso-8859-1
Transfer-Encoding: chunked
Server: Jetty(6.1.26)

181
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">  
   <soapenv:Body>    
      <soapenv:Fault>      
         <faultcode>Server</faultcode>      
         <faultstring>Missing operation for soapAction [http://www.example.com/path/MyOperation] and body element [null] with SOAP Version [SOAP 1.1]</faultstring>    
      </soapenv:Fault>  
   </soapenv:Body>
</soapenv:Envelope>0

Discussion


Log in to post a comment.