Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Web Services -based integration approach  RSS feed

 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi folks,
I've been trying to figure out how to approach an integration framework based on Web Services (SOAP+WSDL+UDDI) and I'd appreciate your comments on what I've come up with.
The context is basically a corporation with a few centralized systems and a lot of heterogeneous local systems. The local systems need to communicate with the central systems and vice versa. Basically the starting point is that the local systems can speak XML but the message formats are different in almost all locations.
Now, to my idea.
I thought about creating a Broker which would accept very abstract requests along the lines of:
<ServiceRequest service="CentralizedServiceNumber123">
<Request format="SomeLocalRequestFormat">
<thiscanbeanything>
...
</thiscanbeanything>
</Request>
<Response format="SomeLocalResponseFormat"/>
</ServiceRequest>
...where <thiscanbeanything is the message/syntax used by the local system and complies to the XML schema "SomeLocalRequestFormat". The <Response> element in turn defines the XML schema in which the response message is expected to be returned. The point here is that the client does not need to worry about message transformations -- "Here, take this and give me back the result as MySpecificSchema"...
The Broker receiving these heterogeneous messages would do the following:
1) Lookup a TransformationService from UDDI based on "source schema" and "target schema" and perform the translation (giving the <thiscanbeanything> element as input and receiving the "canonical" version of the message, understood by the centralized system.
2) Call the centralized service ("CentralizedServiceNumber123") by handing out the transformed version of the original message.
3) Receive response from centralized service and transform back into "local" format.
4) Return the response to the local system, the original requestor.
Does this seem solid so far?
My doubts include the following:
A) How do I pass "any kind of" XML structure as a parameter to the Broker?
B) What does the WSDL include for that part?
C) What's the signature for the Java class's method (String or Element)?
D) Can I still generate the WSDL automatically even though the input and output parameters are so abstract?
E) How can I call the target service's specific without knowing what the input parameter really contains (the transformed message)?
F) Can I do (E) using WSIF to download the WSDL just-in-time (avoiding static compilation)?

All help is highly appreciated.
regs, Lasse
 
Kyle Brown
author
Ranch Hand
Posts: 3892
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How about using XSLT to convert between the "external" format and the "common" format. You could implement a single set of web services for the common servers that output well-known XML (e.g. SOAP). Then write XSLT converters for the other input and output formats. You can implement the XSLT converter in a Servlet Filter on the Axis Servlet if you choose -- it can decide which filter to choose based on something like an input parameter or cookie value (something not used in normal HTTP SOAP messaging).
Amazon already does something similar to this in their Web Services.
Kyle
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I thought about that, and XSLT would probably be the underlying implementation technique for transforming messages between centralized and local formats.
I did pounder on the decision of where to place the translation logic and figured that it would be easier to manage all the message transformations in one place (instead of having to add code and/or configuration to each centralized system upon a new local system being introduced into the corporate network).
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!