Summary

Chapter 3

SOAP

At the core of Web services is Simple Object Access Protocol (SOAP), which provides a standard way of packaging messages. SOAP has received a lot of attention because it facilitates RPC-style communication between a client and a remote server. But plenty of protocols have been created to facilitate communication between two applications—including Sun's RPC, Microsoft's DCE, JAVA's RMI, and CORBA's ORPC. So why is SOAP getting so much attention?

One of the primary reasons is that SOAP has incredible industry support. SOAP is the first protocol of its kind to be accepted by practically every major software company in the world. Companies that rarely cooperate with each other are rallying around this protocol. Some of the major companies that are supporting SOAP include Microsoft, IBM, Sun Microsystems, SAP, and Ariba.

Here are some of the advantages of SOAP:

  • It is not tightly coupled to one language. Developers involved with new projects can choose to develop in today's latest and greatest programming language. But developers who are responsible for maintaining legacy applications might not have a choice about the programming language they use. SOAP does not specify an API, so the implementation of the API is left up to the programming language (such as Java) and the platform (such as Microsoft .NET).

  • It is not tightly coupled to a particular transport protocol. The SOAP specification does describe how SOAP messages should be bound to HTTP. But a SOAP message is nothing more than an XML document, so it can be transported over any protocol that is capable of transmitting text.

  • It is not tied to any one distributed object infrastructure. Most distributed object systems can be extended (and some of them are) to support SOAP. It is important to realize that even with SOAP, middleware such as COM+ still plays an important role in the enterprise. Component middleware is still responsible for some of the more advanced object management features such as object lifetime management, transactions, object pooling, and resource pooling. SOAP enables a degree of interoperability between different systems that are running component middleware from competing vendors.

  • It leverages existing industry standards. The primary contributors to the SOAP specification intentionally avoided reinventing anything. They opted to extend existing standards to meet their needs. For example, SOAP leverages XML for encoding messages. Instead of using its own type system, SOAP leverages the type definitions already defined within the XML Schema specification. And as I have mentioned, SOAP does not define a means of transporting the message; SOAP messages can be bound to existing transport protocols such as HTTP and SMTP.

  • It enables interoperability across multiple environments. SOAP was built on top of existing industry standards, so applications running on platforms that support these standards can effectively communicate via SOAP messages with applications running on other platforms. For example, a desktop application running on a PC can effectively communicate with a back-end application running on a mainframe that is capable of sending and receiving XML over HTTP.

This chapter covers the following key aspects of the SOAP specification:

  • The SOAP envelope. This is used to encode header information about the message and the body of the message itself.

  • SOAP Encoding. This is a standard way of serializing data into the body of a SOAP message.

  • RPC-style messages. I discuss the protocol you can use to facilitate procedure-oriented communication via request/response message patterns.

  • The HTTP POST protocol binding. This is the standard method of binding SOAP messages to HTTP.

Before I go any further, I want to discuss the status of SOAP. This chapter was written against version 1.1 of the SOAP specification (http://www.w3.org/TR/SOAP). The World Wide Web Consortium (W3C) is continuing to develop SOAP. On July 9, 2001, a working draft of SOAP 1.2 was published (http://www.w3.org/TR/2001/WD-soap12-20010709) by the XML Protocol Working Group.

As an acknowledgment of the phenomenal industry support that SOAP enjoys, the XML Protocol Working Group is committed to maintaining a smooth migration path from SOAP 1.1 to SOAP 1.2. Many of the proposed modifications are fit-and-finish and do not radically alter the use of SOAP. Much of what you have learned about SOAP 1.1 will directly translate to SOAP 1.2.

In addition, the majority of the Microsoft products that incorporate SOAP will likely not adopt SOAP 1.2 until it becomes an official W3C recommendation. Therefore, I recommend that you focus on learning the SOAP 1.1 protocol with an eye on the deltas in version 1.2.



Building XML Web Services for the Microsoft  .NET Platform
Building XML Web Services for the Microsoft .NET Platform
ISBN: 0735614067
EAN: 2147483647
Year: 2002
Pages: 94
Authors: Scott Short

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net