Java 2EE and XML Development

Скачать в pdf «Java 2EE and XML Development»

2.1.4 Messaging technologies


Numerous technologies for transmitting XML-structured data between applications and enterprises are currently under development. This is due to the tremendous potential of XML to bridge the gap between proprietary data formats and messaging protocols. Using XML, companies can develop standard interfaces to their systems and services to which present and future business partners can connect with little development effort. In this section, we provide a brief description of the most promising of these technologies.

SOAP


By far the most promising advances in this area are technologies surrounding the Simple Object Access Protocol (SOAP).


DEFINITION SOAP is a messaging specification describing data encoding and packaging rules for XML-based communication.


The SOAP specification describes how XML messages can be created, packaged, and transmitted between systems. It includes a binding (mapping) for the HTTP protocol, meaning that SOAP messages can be transmitted over existing Web systems. Much of SOAP is based upon XML-RPC, a specification describing how remote procedure calls can be executed using XML.


SOAP can be implemented in a synchronous (client/server) or asynchronous fashion. The synchronous method (RPC-style) involves a client explicitly requesting some XML data from a SOAP server by sending a SOAP request message. The server returns the requested data to the client in a SOAP response message. This is depicted in figure 2.5.




Figure 2.5 RPC-style SOAP messaging


Asynchronous messaging is also fully supported by the SOAP specification. This can be useful in situations where updates to information can be sent and received as they happen. The update event must not require an immediate response, but an asynchronous response might be sent at some point in the future. This response might acknowledge the receipt of the original message and report the status of processing on the receiver side. Asynchronous SOAP is depicted in figure 2.6.

Скачать в pdf «Java 2EE and XML Development»