Chapter 11. Web Services

   

Web Services are functions or procedures that are accessible to other computer programs over a network, using a standard transport protocol and encoding. Typically, the transport protocol used is HTTP, the encoding is XML-RPC or SOAP, and the messages communicated between programs are exchanged as XML documents.

Web Services are all about interoperability. By encapsulating programming language-specific function or procedure call syntax into a standardized XML document syntax, Web Services allow any program deployed on any operating system to utilize a candidate function or procedure exposed as a Web Service.

Exposing program functions or procedures to be called remotely isn't a new idea. Database stored procedures and EJBs are two longstanding examples of remote procedure calls. What's new with Web Services is the level of interoperability built into them.

To call a database stored procedure, you must use a proprietary or standardized API such as JDBC. However, such APIs allow your program to call only functions or procedures that exist in a target database. These APIs also require a proprietary network protocol. Corporate firewalls typically don't allow proprietary protocols to pass through them, so their use can limit the level of interoperability.

To call an EJB, you can either use the EJB API or CORBA, but this solution allows only an Enterprise Java program, or a program written with a programming language that uses a CORBA API, to use the target EJB. Once again, a network protocol, RMI, is used that may not be supported by a corporate firewall.

In contrast, Web Services allow any programming language on any operating system in which a Web Services client implementation exists to call a target Web Service. In addition, the use of HTTP as a transport protocol, which is generally supported by all firewalls, allows easy access to Web Services.

Of course, this highly interoperable, lowest -common-denominator approach comes with a price: slower performance. Web Services as remote procedure calls are significantly slower than database stored procedures or EJBs. This is understandable because extra steps are involved:

  • Encoding a remote procedure call into the XML document on the client-side

  • Parsing the XML document to call the desired function on the server-side

  • Encoding the result into an XML document on the server-side

  • Parsing the XML document to retrieve the desired result on the client-side

Regardless, Web Services are an ideal solution when it comes to integrating heterogeneous computer applications.

This chapter begins by taking a brief look at the architecture used by Web Services. Next, it covers the commonly used protocols and standards used for Web Services, highlighting Oracle Application Server's support for each. It finishes up by examining Oracle Application Server's implementation of Web Services, including programming and management tools.

   


Oracle Application Server 10g Essentials
Oracle Application Server 10g Essentials
ISBN: 0596006217
EAN: 2147483647
Year: 2004
Pages: 120

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