Hi guys,
we're facing an issue with Web Service calls in Composer...
First I have to say that we're not facing the same problem when we perform the request via SOAP UI. Everything is fine there.
When it comes to Composer, however, we keep getting a blank response.
We're calling the web service via VXML Form Block, configured as follow:
<block>
<if cond="(AppState.COMPOSER_WSSTUBBING == '1') || (AppState.COMPOSER_WSSTUBBING == 1)" >
<!-- Web Service is stubbed !! -->
<var name="WebUrl" expr="''"/>
<assign name="AppState.esito" expr="''"/>
<log> Stubbing: assigned "AppState.esito"="" /> </log>
<goto next="#Log_Response" />
</if>
<!-- Stubbing is Off - normal processing continues -->
<script>
var requestObj = new Object();
requestObj['WebUrl'] = 'https://xxx;
requestObj['MethodName']='xxx';
requestObj['Protocol'] = 'SOAP';
requestObj['AuthenAccess']= 'HTTPBasicAuthentication';
requestObj['UserName'] = 'xxx';
requestObj['Password'] = 'xxx';
requestObj['enableProxy']=false;
requestObj['proxyHost']='';
requestObj['proxyPort']=80;
requestObj['proxyUserName']='';
requestObj['proxyPassword']='';
requestObj['SOAPActionURI'] ='urn:sap-com:document:sap:rfc:functions:xxx:xxx';
requestObj['targetNameSpaceUri']='urn:sap-com:document:sap:rfc:functions';
requestObj['KeyStorePass']='';
requestObj['KeyStoreFilePath'] ='';
requestObj['PrivateKeyPass'] ='';
requestObj['PrivateKeyAlias'] ='';
requestObj['CertStoreName'] ='';
requestObj['CertAlias'] ='';
requestObj['SigAlgorithm'] ='DSA';
requestObj['NameSpaceMap'] ='{"wsdl"="http://schemas.xmlsoap.org/wsdl/", "soap11"="http://schemas.xmlsoap.org/wsdl/soap/", "soap12"="http://schemas.xmlsoap.org/wsdl/soap12/", "http"="http://schemas.xmlsoap.org/wsdl/http/", "mime"="http://schemas.xmlsoap.org/wsdl/mime/", "wsp"="http://www.w3.org/ns/ws-policy", "wsp200409"="http://schemas.xmlsoap.org/ws/2004/09/policy", "wsp200607"="http://www.w3.org/2006/07/ws-policy", "ns0"="http://xxx.it/", "xsd"="http://www.w3.org/2001/XMLSchema"}';
requestObj['EnableNSPrefix'] = false;
requestObj['PrefixForChildTags'] = false;
requestObj['CustomPrefix'] = '';
requestObj['AppStateString'] = JSON.stringify(AppState);
requestObj['VariableScope'] = 'AppState.';
requestObj['CustomSOAPEnvFileName']='//src//soap//test.xml';
var parameters = [];
requestObj['Timeout'] = '60';
requestObj['Parameters'] = parameters;
</script>
<data name="WS_RicercaRitiriResponse" enctype="application/json" gvp:contentexpr="requestObj" method="post" src="../include/getWebServiceData.jsp" />
<assign name="AppState.esito" expr="WS_RicercaRitiriResponse"/>
<if cond="typeof WS_RicercaRitiriResponse.errorMsg == 'undefined'">
<goto next="#Log_Response" />
<else/>
<throw event="error.com.genesyslab.composer.webservice.badFetch" messageexpr="WS_RicercaRitiriResponse.errorMsg" />
</if>
</block>
<catch event="error.badfetch">
<goto next="#Timeout" />
</catch>
<catch event="error.com.genesyslab.composer.webservice.badFetch">
<goto next="#Timeout" />
</catch>
The same configuration has been used for another Web Service call that is pretty much the "twin" of the one that is currently not working.
When we call the application, no error is thrown but we get a blank response:
2019-11-04 15:56:07.993 DBUG 007701DC-1000C377 5980 0C000000 VXMLSession.cxx:1348 HandleFetchEvent(): Process state: 2, response code: 200, error: , uri: http://10.207.173.205:8080/Test/include/getWebServiceData.jsp
2019-11-04T15:56:07.993 Trc 20001 INFO 007701DC-1000C377 5980 02B68719 Compile Done|0ms|http://10.207.173.205:8080/Test/include/getWebServiceData.jsp
2019-11-04T15:56:07.993 Trc 20001 INFO 007701DC-1000C377 5980 02B6871A Fetching Done|875ms|data|http://10.207.173.205:8080/Test/include/getWebServiceData.jsp
2019-11-04T15:56:07.993 Int 50043 007701DC-1000C377 5980 fetch_end Done (direct):http://10.207.173.205:8080/Test/include/getWebServiceData.jsp
2019-11-04 15:56:07.993 DBUG 007701DC-1000C377 5980 0C000000 VxmlRuntimeRoot.cxx:213 Execute() Started, event type: 1
2019-11-04 15:56:07.993 DBUG 007701DC-1000C377 5980 0C000000 VxmlRuntimeDoc.cxx:162 Execute() Started, event type: 1
2019-11-04 15:56:07.993 DBUG 007701DC-1000C377 5980 0C000000 BlockRuntime.cxx:195 Execute() Started
2019-11-04 15:56:07.993 DBUG 007701DC-1000C377 5980 0C000000 DataRuntime.cxx:442 Execute() Started, event type: 1
2019-11-04 15:56:07.993 DBUG 007701DC-1000C377 5980 0C000000 Runtime.cxx:425 EvaluateExpression(): Expression [var WS_RicercaRitiriResponse =
{}
;]
What can the problem be here?
VXML Form Block is used here instead of Web Service Block because it fails in parsing the Service URL, saying that there's come file missing.
Same thing happened when we tried to parse the Service URL of the "twin" Web Service but we get no problem when it comes to receiving the response via VXML Form Block.
The only thing that appear to be different is that when we created the SOAP Project on SOAP UI, the WS asked for its .xsd file (that had to be in the same folder of the .wsdl) while the "twin" didn't asked for it.
Thanks everyone in advance