Tuesday, October 30, 2007

SOA Part 2 - WSDL

WSDL are XML documents that describe service interfaces. The WSDL specify the supported operations (port types), defines the Web Service access mechanism (messages) and the location at which the service is available (port defined by network address with binding).

To define a WSDL interface, these are the steps to be followed:
• Identify and define all the data structures that are involved in message exchange.
• Define messages that build on this data structure.
• Define operations or interactions.

There are four basic operations: one-way, request-response, solicit-response, and notification. In our current implementation, request-response synchronous interactions are implemented. We are looking at WS-Addressing to provide support for asynchronous interactions.

You normally never have to generate WSDL files from scratch. There are many toolkits available. the toolkit we used is GLUE from the Mind Electric which has been acquired by WebMethod. Glue is a Java based modular platform for building and invoking distributed web services. Glue can handle almost any data structure as long as it is properly defined by WSDL.

There are some characteristics to our Web Services:
• Using XML Schema types within WSDL, including the use of Map and complex types.
• The Web services we build are not published to the world at large, we are not concerned with advertising the services.
• For us, providing client stubs is less a problem since the client side environment is Java which uses GLUE as well.

To consume a WSDL file, the client stub/proxy generator generates Java classes and serialization routines. For developers, you don't even need to be aware of you are dealing with a XML document. You are working at Java object and attributes level.

We are moving towards Oracle/Peoplesoft environment. It would be interesting to compare the simple WSDL generated by GLUE to the WSDL published by Peoplesoft Component Interface.

WSDL file doesn’t describe the whole interface for a service. In another word, WSDL defines only core properties for interoperability. Additional attributes for security, SLA are provided by other standards.

It is worth mentioning that while the WSDL 1.1 model lacks flexibility, some of these will be addressed by WSDL 2.0.

No comments: