Hello,
Please make sure your namespace is http://www.w3.org/2003/05/soap-envelope since we support SOAP 1.2
Thanks
New request:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<connectivityTest xmlns="urn:cdc:iisb:2011" xmlns:ns2="http://www.w3.org/2003/05/soap-envelope">
<echoBack>Hello IIS!</echoBack>
</connectivityTest>
</soap:Body>
</soap:Envelope>
New Response:
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta name="generator" content="HTML Tidy for HTML5 for Mac OS X version 5.4.0" />
<title>Apache Tomcat/7.0.64 - Error report</title>
<style>
<![CDATA[
<!--H1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}HR {color : #525D76;}-->
]]>
</style>
</head>
<body>
<h1>HTTP Status 500 - Request processing failed; nested exception is
org.springframework.ws.soap.SoapMessageCreationException: Could not create message from
InputStream: Unable to internalize message; nested exception is
com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Unable to internalize message</h1>
<hr size="1" noshade="noshade" />
<p><b>type</b> Exception report</p>
<p><b>message</b> <u>Request processing failed; nested exception is
org.springframework.ws.soap.SoapMessageCreationException: Could not create message from
InputStream: Unable to internalize message; nested exception is
com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Unable to internalize message</u></p>
<p><b>description</b> <u>The server encountered an internal error that prevented it from
fulfilling this request.</u></p>
<p><b>exception</b></p>
<pre>
org.springframework.web.util.NestedServletException: Request processing failed; nested exception is org.springframework.ws.soap.SoapMessageCreationException: Could not create message from InputStream: Unable to internalize message; nested exception is com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Unable to internalize message</pre>
</body>
</html>
John,
I don't have any example code. Have you try using a soap client such as Boomerang which is a chrome plugin ?
JR
curl --header "Content-Type: application/soap+xml;charset=UTF-8" --header "SOAPAction:urn:cdc:iisb:2011:connectivityTest" --data @request1.xml https://hl7v2-iz-r1.5-testing.nist.gov:8098/iztool/ws/iisService > response1.txt
<!-- input file request1.xml -->
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<connectivityTest xmlns="urn:cdc:iisb:2011" xmlns:ns2="http://www.w3.org/2003/05/soap-envelope">
<echoBack>Hello IIS!</echoBack>
</connectivityTest>
</soap:Body>
</soap:Envelope>
Response error:
org.springframework.ws.soap.SoapMessageCreationException: Could not create message from InputStream: InputStream does not represent a valid SOAP 1.2 Message; nested exception is javax.xml.soap.SOAPException: InputStream does not represent a valid SOAP 1.2 Message
curl --header "Content-Type: application/soap+xml;charset=UTF-8" --header "SOAPAction:urn:cdc:iisb:2011:connectivityTest" --data @request2.xml https://hl7v2-iz-r1.5-testing.nist.gov:8098/iztool/ws/iisService > response2.txt
<!-- input file request2.xml -->
<?xml version="1.0" encoding="utf-8"?>
<Envelope xmlns="http://www.w3.org/2003/05/soap-envelope">
<Body>
<connectivityTest xmlns="urn:cdc:iisb:2011" xmlns:ns2="http://www.w3.org/2003/05/soap-envelope">
<echoBack>Hello IIS V2!</echoBack>
</connectivityTest>
</Body>
</Envelope>
<?xml version="1.0" encoding="utf-8"?>
<env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope">
<env:Header/>
<env:Body>
<ns2:connectivityTestResponse xmlns:ns2="urn:cdc:iisb:2011">
<ns2:return>Hello IIS V2!</ns2:return>
</ns2:connectivityTestResponse>
</env:Body>
</env:Envelope>
I am not sure why the message without the namespace works and the other with the namespace does not work. If anyone can explain why, it would be greatly appreciated.
John,
It seems the error is in the soap namespace. Instead of https it should be http.
The "Soap Envelope" tab can help identify the issues in the soap message.
See screenshots.
Hope it helps.
I am now working on creating VXQ^V01 messages to continue testing.
Thanks again!
JR