LI - SOAPServer Service - Multi Fragment Response

This Q&A forum allows users to post and respond to "How Do I Do ....." questions. Please do not use to report (suspected) errors - you must use your regional help desk for this. The information contained in this forum has not been validated by LANSA and, as such, LANSA cannot guarantee the accuracy of the information.
Post Reply
nick.diama
Posts: 19
Joined: Wed May 25, 2016 5:36 pm

LI - SOAPServer Service - Multi Fragment Response

Post by nick.diama »

SOAPServer Service uses a parent fragment in the response message. The parent fragment can contain several fragments.
The question if we can construct a response message that holds two or more "parent" fragments.
For example, the following response is contained in a parent fragment called HeartBeatRes.

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<HeartBeatResponse xmlns="dias:online:DiasOnlineMS.wsdl">
<ns1:HeartBeatRes xmlns:ns1="http://soap.service.dias_server.com">
<ns1:msgHdr>
<ns1:sndgInst>DIAS</ns1:sndgInst>
<ns1:rcvgInst>90755</ns1:rcvgInst>
<ns1:srvcId>DTM</ns1:srvcId>
<ns1:env>T</ns1:env>
<ns1:creDtTm>2016-12-14T13:09:38</ns1:creDtTm>
</ns1:msgHdr>
<ns1:ack>
<ns1:rslt>OK</ns1:rslt>
<ns1:errCd>0</ns1:errCd>
<ns1:errMsg>No Errors</ns1:errMsg>
</ns1:ack>
</ns1:HeartBeatRes>
</HeartBeatResponse>
</soapenv:Body>
</soapenv:Envelope>

Is it possible to modify the response by omitting the parent fragment?

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<HeartBeatResponse xmlns="dias:online:DiasOnlineMS.wsdl">
<ns1:msgHdr>
<ns1:sndgInst>DIAS</ns1:sndgInst>
<ns1:rcvgInst>90755</ns1:rcvgInst>
<ns1:srvcId>DTM</ns1:srvcId>
<ns1:env>T</ns1:env>
<ns1:creDtTm>2016-12-14T13:09:38</ns1:creDtTm>
</ns1:msgHdr>
<ns1:ack>
<ns1:rslt>OK</ns1:rslt>
<ns1:errCd>0</ns1:errCd>
<ns1:errMsg>No Errors</ns1:errMsg>
</ns1:ack>
</HeartBeatResponse>
</soapenv:Body>
</soapenv:Envelope>

Moreover, can we somehow declare the inbound parameter of the SOAPServer Service as both inbound and outbound, as this is done in SOAPAgent Service?

SOAPAgent example,
soapagent.png
soapagent.png (21.5 KiB) Viewed 5128 times
SOAPServer example
soapserver.png
soapserver.png (28.2 KiB) Viewed 5128 times


Is it possible to instruct the MessageHeader in the Inbound Parameter to be both Inbound & Outbound “ = “

Thanks in advance for your answers.
alick
Posts: 16
Joined: Fri Sep 02, 2016 2:43 pm

Re: LI - SOAPServer Service - Multi Fragment Response

Post by alick »

The SOAP server service does not support In/Out parameters.
You will need to create the SOAP XML using the XML binding wizard and one of the XML HTTP services.
Post Reply