It's tempting for those with a background in distributed objects to look at the upcoming Web services standards as just another set of distributed object technologies--and probably to have some misgivings about reinventing the wheel. Conversely, it may be tempting for them to think that now that Web services are here, distributed objects are no longer important.
After all, Web services have:
- A transport protocol: SOAP (Simple Object Access Protocol)
- Something like an interface definition language: WSDL (Web Services Definition Language)
- A location service: UDDI (Universal Description, Discovery and Integration)
In this article, however, I want to explore how Web services complement rather than compete with traditional distributed object platforms such as CORBA and J2EE. The premise of this piece is that, when used correctly, Web services and distributed objects have different paradigms--"document-oriented" and "object-oriented"--and that a combination of both paradigms is required to achieve end-to-end business integration.
The object-oriented platforms CORBA and J2EE have been tremendously successful for building and integrating applications within the enterprise. The document-oriented XML technologies associated with Web services are rapidly gaining popularity for business-to-business integration between enterprises. Total business integration needs to address both these areas.
Object-Oriented vs. Document-Oriented
For a distributed object veteran, a Web service looks like yet another distributed object system. Based on this analogy, it is tempting to simply expose existing CORBA or Java objects as Web services by mapping them to WSDL. However, XML has a different heritage. It is document-oriented, not object-oriented. Web services should be considered a medium for implementing document exchange systems and not simply a new flavor of distributed object systems.
How Document Exchange Is Different
In a document-oriented system, document design is key. Interfaces are just a way to pass documents. Contrast object-oriented design: Interfaces are key; data structures are just convenient packages of data for the operations on the interfaces.
Document exchange systems have:
- Larger, richer data structures--so much richer that we call them "documents"
- Looser coupling between agents
- More asynchronous communication
1