TIBCO Software Inc. 2009 Confidential Author: Carlo Milono
Total Page:16
File Type:pdf, Size:1020Kb
TIBCO Software Inc. – © 2009 Confidential Author: Carlo Milono
Simulating WS-Addressing Structures for BusinessWorks 5.7.X
Axis2 Echo Example
Introduction TIBCO ActiveMatrix BusinessWorks does not natively support WS-Addressing as of version 5.7.x. The underlying XML engines are flexible, however, and you can create WS-Addressing compatible WSDLs and map in-to and out-of the WS-Addressing elements and attributes. Creating a new listener will not be automatic and any of the underlying functions will have to be architected into a solution. This document only covers the WS-Addressing schema structure within BusinessWorks. This document covers the specific case of testing BusinessWorks against the Axis2 (v1.4.1) WsaMappingTest, which is basically an ‘echo’ model. This approach can be used to build out other Web Services functions as well, such as SAML or Web Services Security. One issue is that you cannot easily manipulate the attributes of the
Axis2 1.4 Client Request (via SoapUI) POST /axis2/services/WsaMappingTest.WsaMappingTestHttpSoap11Endpoint/ HTTP/1.1 Content-Type: text/xml;charset=UTF-8 SOAPAction: "urn:echo" User-Agent: Jakarta Commons-HttpClient/3.1 Host: 127.0.0.1:9091 Content-Length: 748
Axis2 1.4 Service Response
HTTP/1.1 200 OK Date: Thu, 19 Nov 2009 22:35:13 GMT Server: Simple-Server/1.1 Transfer-Encoding: chunked Content-Type: text/xml; charset=UTF-8 1b0
BW 5.7.2 Client Request (just copy the WSDL exposed by Svc)
NOTE: no
Axis2 Service Response No headers in, so no headers out
HTTP/1.1 200 OK Date: Thu, 19 Nov 2009 22:37:48 GMT Server: Simple-Server/1.1 Transfer-Encoding: chunked Content-Type: text/xml; charset=utf-8 Connection: close 103
Coersion in BW – adding Headers Import ws-addr-wsdl.xsd and/or ws-addr.xsd, along with the right SOAP schema (v1.1 shown )depending on your needs.
Create Messages for the WSDL to include:
wsa:MessageID
wsa:To
wSA:ReplyTo
wsa:Action
wsa:From
wsa:RelatesTo TIBCO Software Inc. – © 2009 Confidential Author: Carlo Milono
Add the namespaces and
Add
Populate the elements and attributes as needed:
Note: special reserved URI anonymous means that ReplyTo is effectively ignored.
http://www.w3.org/2005/08/addressing/anonymous
Here is the Output from a successful test: TIBCO Software Inc. – © 2009 Confidential Author: Carlo Milono
Modified BW Client SOAP Message after coercion POST /axis2/services/WsaMappingTest.WsaMappingTestHttpSoap11Endpoint/ HTTP/1.1 Connection: close SoapAction: "urn:echo" content-type: text/xml; charset="utf-8" User-Agent: Jakarta Commons-HttpClient/3.0.1 Host: 127.0.0.1:9091 Content-Length: 1766
Response from Axis2 HTTP/1.1 200 OK Date: Fri, 20 Nov 2009 00:58:47 GMT Server: Simple-Server/1.1 Transfer-Encoding: chunked Content-Type: text/xml; charset=utf-8 Connection: close
1c1