Skip Headers
Oracle TopLink Developer's Guide
10g Release 3 (10.1.3)
B13593-01
  Go To Documentation Library
Home
Go To Product List
Solution Area
Go To Table Of Contents
Contents
Go To Index
Index

Previous
Previous
Next
Next
 

Understanding the Web Services Architecture

A Web services architecture is similar to the three-tier (see "Understanding the Three-Tier Architecture") or session bean (see "Understanding the EJB Session Bean Facade Architecture") architecture, however, in a Web services architecture, you encapsulate business logic (the service) in a Web service instead of (or in addition to) using session beans. In a Web services architecture, clients communicate with your application using SOAP messages (XML over HTTP).

Figure 2-8 Web Services Architecture

Description of Figure 2-8 follows
Description of "Figure 2-8 Web Services Architecture"

As in any architecture, you can use TopLink to persist objects to relational or EIS data sources. However, in a Web services architecture, you can also use TopLink to map your object model to an XML schema for use with the Web service or as the Web service XML serializer.

Example Implementations

An example of a Web services architecture implementation is the use of a Web service to expose parts of an existing application to a remote client (typically another application) by way of SOAP messages. In this application, you can use TopLink XML to unmarshall XML messages to Java objects to facilitate requests and marshall Java object responses back into XML for transmission to the client.

Advantages and Disadvantages

Using TopLink in Web services architecture has many advantages, including, but not limited to, the following:

  • you can map XML messages to an existing Java object model.

  • you can achieve a high level of complexity of mapping support

  • compliance with the JAXB standards

  • providing a scalable, high-performing solution

One debatable disadvantage is this solution's complexity over a simple RMI session bean service.

Technical Challenges

As with any technology, there are technical challenges associated with the use of TopLink in Web services architecture. These technical challenges are mostly related to special-case scenarios, such as when you need to implement a custom serializer because you have both the Java objects and the schema.

For more information, see the following: