Web Service Examples
Now let's explore a couple of examples to put all of this in perspective. Consider an online news service that delivers news highlights and full news articles for information portals such as MSN.com, MyNetscape.com, and Yahoo!. This service has a database full of news headlines, article summaries, and full-blown articles available by subscription to other businesses (news and information portals, giant intranet home pages, wireless content providers, etc.).
Currently, establishing a dialogue between two disparate systems in an exchange is rather involved. Either the news service must create multiple interfaces to access its data (a COM object, a servlet, a pure text or XML port, etc.), or the news service selects one type of interface and potential clients must adapt to that. Either way, B2B collaboration is slowed and potential business is lost due to time spent developing and/or integrating with the partner's system.
Web services offer a dramatic solution to the current limitations of software and Web development, both from a technical standpoint, as well as a financial standpoint. By leveraging standard industry protocols and wire formats for B2B collaboration and information exchange, applications can be developed more quickly and more businesses can be sold the same product or service, unmodified. Now, any XML-capable information system could potentially access the news database. This service could be sold to hundreds of clients, without any need for customization or adaptation.
A second example is a credit card validation service. Credit card validation is a necessity for an e-commerce site or e-commerce storefront; there does not exist a standard industry mechanism for passing credit card information for validation. If a client is unhappy with the usage fee or quality of service being received, the process of changing to another provider is costly and time-consuming at best. If card validation companies exposed their validation services as Web services, a client could much more easily move to another provider because there would be a standardized protocol and wire format for invoking the validation service. The industry might even produce an XML schema document describing a standardized interface for these services to use. This promotes competition and allows a business to quickly and easily change to a provider that it believes will provide better service.
Why would the credit card validation companies choose to open themselves to competition? If the market demands a standardized mechanism in the form of Web services, someone will meet that need. When they do, others will follow. The fact is, this model could be emulated by any electronic service (loan approval, background checks, document services, shipping/delivery, etc.).
Now, let's begin to actually program two sample Web services.