ASP.NET and Web Services, Part 1 - SOA Web Services
(Page 5 of 9 )
The following items constitute the building blocks for constructing service-oriented architecture web services:
- Encoding XML-ized data transmitted between client and server requires encoding. Typically, the decoding is UTF-8. In J2EE it is ISO-8859-1.
- Description Web services represent an end point. Once the point is located, the service provider describes metadata about the service and requirements needed by the client in order to leverage its services.
- DISCO This is a proprietary Microsoft method for discovery. In order to use DISCO, a URL is required before the document can be located. Use the Disco.exe command-line utility to generate theWSDL contract. Syntax for this is as follows:
Disco
[options] URL
In contrast, UDDI does not require the URL to locate a web service or registry. A registry normally provides a tool for searching by name, location, URL, keyword, and other search criteria. It is possible to search for the keyword wsdl. These URLs will always point toward WSDL contracts available for web services.
- Messaging format Both client and business partner must agree on a mutual protocol before they can encode, format, and transmit messages to each other via HTTP and SOAP.
Fortunately, Microsoft and Sun Microsystems are assisting developers by releasing software solutions that enable a company to face numerous Internet business challenges.
SOA Best Practices
Service providers not only set forth a description of services but also impose constraints dependent on context. The following list presents some of the primary characteristics for efficient utilization of these services:
- Interface design SOA services implement defined interfaces. This is important because multiple web services can implement a commonly shared interface. Conversely, a single service can implement numerous interfaces.
- Asynchronous calls Generally speaking, best practices suggest message passing via asynchronous remote calls. This is important because asynchronous calls allow developers to continue working with other development tasks while awaiting a return result from the server. Synchronous calls are less desirable because all other tasks are blocked until the request fulfillment is completed.
- Coarse-grained services Object-oriented technologies such as Java expose their services through individual methods. Using an individual method, however, is too fine an operation for processing large quantities of data. It is better to assemble individual methods into a cohesive coarse-grained service and process large amounts of data.
- Remote Procedure Calls Web services enable clients to invoke procedures, methods, and functions on remote objects employing an XML-based protocol. RPCs expose both input and output parameters.
Remember: This is part one of chapter 7 .NET & J2EE Interoperability, by Dwight Peltzer (McGraw-Hill/Osborne, ISBN 0-07-223054-1, 2004). If you like what you see, feel free to click on the following link to get your own copy! Buy this book now.
|
Next: Primary Web Services Technologies >>
More ASP.NET Articles
More By McGraw-Hill/Osborne