O'Reilly logo

Real World Web Services by Will Iverson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required


The core idea behind this book is simple: after years of hype, what are the major players really doing with web services? Standard bodies may wrangle and platform vendors may preach, but what technologies are actually in use?

Think of this book as a field guide to the wild and woolly world of nontrivial deployed web services. The heart of the book is a series of projects that demonstrate the use and integration of Google, Amazon, eBay, PayPal, FedEx, and many more web services. Some of these vendors have been extremely successful with their web service deployments; for example, eBay processes over a billion web service requests a month.

Not all web services are created equal: some rely on a variety of strange formats; others require extensive and error-prone XML; and still others require a minimal knowledge of SOAP and WSDL. This book provides compelling examples of the value of SOAP and WSDL for the client developer. In Chapter 4, for example, you can compare the custom bindings required for working with complex XML data types against the generation of SOAP binding generation from WSDL.


This book is divided into four sections: introductory material, a conceptual orientation with regard to web services, the various projects surveying real world web service deployments, and finally, a brief chapter outlining some thoughts on the future of web services. While experienced developers may be inclined to skim the introductory chapters, it may be worth covering them again just to make sure you haven’t missed the forest for the trees.

Chapter 1, Web Service Evolution

This chapter provides a high level, business-oriented introduction to web services. Technology serves human needs, and this chapter shows how web services fill an important role in the development of the Web. Many developers may be familiar with these concepts already, but it is as important to explain why you do a thing as to explain how it is done.

Chapter 2, Foundations of Web Services

While Chapter 1 covers a business-oriented approach to the history of web services, this chapter provides a technical history. Seasoned developers may find this all familiar, but for readers just joining the web services conversation, this is vital background information. In addition, this chapter can serve as a useful checklist for planning your own web service development and deployment plans.

Chapter 3, Development Platform

This chapter provides an introduction to the Java© development platform and tools used in the projects in this book. An introduction is given to Apache Tomcat, Apache XML-RPC, and Apache Axis, the web server, XML-RPC, and SOAP/WSDL toolkits respectively. Obviously, Java is not the only development platform available, and a brief discussion of alternatives concludes the chapter.

Chapter 4, Project 1: Competitive Analysis

The first project in the book, this chapter shows how data from Amazon, eBay, and Google can be used to present an integrated report to a user. Connectivity to each of these three web service providers is shown, providing an example of the developer effort required to access each system.

Chapter 5, Project 2: Auctions and Shipping

This chapter shows how FedEx and eBay can be integrated to provide auction listings with precalculated FedEx shipping estimates. XML is used throughout—from the local auction listings to FedEx and eBay web services.

Chapter 6, Project 3: Billing and Faxing

In this chapter, high-tech web services are used to integrate PayPal billing with low-tech fax technology.

Chapter 7, Project 4: Syndicated Search

This chapter illustrates a web service gateway, using a Google search result to provide a syndicated RSS feed.

Chapter 8, Project 5: News Aggregator

While other examples in this book operate in direct response to user interaction, this chapter uses the Quartz scheduler framework to monitor Amazon, eBay, Google, and RSS feeds on a regular, reliable schedule.

Chapter 9, Project 6: Audio CD Catalog

This chapters shows how CDDB and Amazon can be used together to create a catalog of your audio CDs.

Chapter 10, Project 7: Hot News Sheet

In this chapter, you’ll build an application using RSS to provide a single web page showing what’s hot both from the mainstream news and the weblog universe, side by side. The application will additionally fold in results from a Google search on these topics for yet another angle on the news.

Chapter 11, Project 8: Automatic Daily Discussions

In this chapter, you’ll build an application to combine your Blogger or LiveJournal weblog with Google’s search functionality to create automatic prompts for daily discussions.

Chapter 12, Future Web Service Directions

This chapter starts with a look at some of the more futuristic web service technologies, including REST, UDDI, Rendezvous, and BPEL/BPEL4WS. A look at the future of web service development follows, which considers ease-of-use, the need for a business model, security, and finally, the consolidation of web services.

Conventions Used in This Book

The following font conventions are used in this book:

Italic is used for:

  • Unix pathnames, filenames, and program names

  • Internet addresses, such as domain names and URLs

  • New terms where they are defined

Boldface is used for:

  • Names of GUI items (window names, buttons, menu choices, etc.)

Constant width is used for:

  • Command lines and options that should be typed verbatim

  • Names and keywords in Java programs, including method names, variable names, and class names

  • XML element names and tags, attribute names, and other XML constructs that appear as they would within an XML document


Indicates a tip, suggestion, or general note.


Indicates a warning or caution.

Using Code Examples

This book is here to help you get your job done. In general, you may use the code in this book in your programs and documentation. You do not need to contact us for permission unless you’re reproducing a significant portion of the code. For example, writing a program that uses several chunks of code from this book does not require permission. Selling or distributing a CD-ROM of examples from O’Reilly books does require permission. Answering a question by citing this book and quoting example code does not require permission. Incorporating a significant amount of example code from this book into your product’s documentation does require permission.

We appreciate, but don’t require, attribution. An attribution usually includes the title, author, publisher, and ISBN. For example: "Real World Web Services, by Will Iverson. Copyright 2004 O’Reilly Media, Inc., 0-596-00642-X.”

If you feel your use of code examples falls outside fair use or the permission given here, feel free to contact us at .

Comments and Questions

Please address comments and questions concerning this book to the publisher:

O’Reilly Media, Inc.
1005 Gravenstein Highway North
Sebastopol, CA 95472
800-998-9938 (in the U.S. or Canada)
707-829-0515 (international or local)
707-829-0104 (fax)

There is a web page for this book, which lists errata, examples, and additional information. You can access this page at:


To comment or ask technical questions about this book, send email to:

For more information about books, conferences, Resource Centers, and the O’Reilly Network, see the O’Reilly web site at:



First, I must send my gratitude to the unseen engine behind the production, marketing, and sales of this book. I know you’re there and appreciate all your efforts. Thanks to everyone who has contributed in one form or another to the technologies underlying and comprising web services. We so blithely take for granted so much of this innovation—we stand on the shoulders of giants.

This book wouldn’t be what it is without the efforts of my editor, Brett McLaughlin. His work made for a far better book. Thanks to Tim O’Reilly for all the fine tomes that grace my bookshelf and for allowing me to add a second title to O’Reilly’s excellent library. For their time, enthusiasm, and professional support, I would like to thank Brian Lawley and Daniel Steinberg. Has it really been that long?

On a personal note, thanks to friends and family for their support. And finally, thanks to Mom, Diane, and Cynthia. You are, quite simply, the best.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required