Portlet Factory, Version 6.1.2

 

Processing SOAP headers

 

+

Search Tips   |   Advanced Search

 

To process incoming SOAP headers in your service method (which do yourself – there is no WebSphere Portlet Factory-wide default SOAP header processing provided), you may retrieve the SOAP Header information (if any was present in the incoming SOAP envelope), by retrieving them in IXml or JDOM Element format from the current HttpServletRequest via request attribute.

For example:

HttpServletRequest request = webAppAccess.getHttpServletRequest();

IXml soapHeaders = (IXml)request.getAttribute("bowstreet.soap.header");

org.jdom.Element soapHeaders = (Element) request.getAttribute("bowstreet.soap.jdom.header");

To send SOAP Headers in the response envelope from your service method, you may do so by setting a request attribute that will be picked up and inserted into the SOAP Response envelope.

request.setAttribute("bowstreet.soap.responseHeaders", ixmlSOAPHeaders);

or

request.setAttribute("bowstreet.soap.jdom.responseHeaders", jdomSOAPHeaders);

The Web Service Enable builder also provides a set of inputs you can use to populate an control the content of SOAP headers.

Parent topic: Web Service Enable builder


Library | Support |