Home > Articles > Web Development > Perl

Simple Object Access Protocol (SOAP) and Web Services

  • Print
  • + Share This
Chris Radcliff shows you how to develop Web services using the Simple Object Access Protocol (SOAP) and Perl. A high-level view of the Web services model is discussed, including examples of existing and upcoming Web services. Tips are provided on how to expose existing applications as Web services and how to organize Web service objects and methods for ease of use.
This article is excerpted from Perl for the Web, by Chris Radcliff.

SOAP provides a good alternative to the cluttered, unstructured data returned by most Web sites. Aspects of the protocol specification that are unlikely to change from one interface to the next are rigidly defined, but the protocol still enables a wide range of data constructs to be passed in a SOAP envelope. With the SOAP protocol and existing Web architecture, it's possible to create interfaces to Web information systems that require little custom programming. Because these interfaces also can be described using the same framework and no outside negotiation, they are the closest yet to being truly automated.

These automated interfaces to networked systems are called Web services. The Web services model combines the easy implementations of Web servers with the structured XML data of the SOAP protocol. The idea is to provide a Web service interface for every aspect of a business or organization and then publish complete descriptions of the interface to directories of similar Web services. Clients wishing to use a Web service then can browse the directory, find Web services that match their needs, and implement the services automatically. Thus, custom interface programming and specific partnership agreements give way to a Web-wide infrastructure the same way that custom networks gave way to the Internet.

Existing Web Services

Many Web services already are available, and sites that collect them into coherent directories have started to appear. XMethods (http://www.xmethods.com) and XMLToday (http://www.xmltoday.com) are sites geared toward SOAP enthusiasts, so many of the Web services listed are of an experimental nature. These sites host the service description for each Web service, but they also offer details on how to use the Web service in a client application. Some services even include sample programs implementing the service description as a client—many written in Perl using SOAP::Lite. Adding these services to an existing program is likely to get even easier as description standards become more widely used.

In the future, many Internet-savvy businesses are likely to implement SOAP interfaces to their service offerings. Early candidates include shipping companies, such as FedEx and UPS, who probably will provide their shipping services through SOAP as well as their existing custom interfaces. Document consolidation services also are likely to be early adopters of the Web services model. Examples include job-posting boards, such as Monster.com and Dice.com, that process thousands of job postings, resume listings, and match requests daily. A set of Web services for common functions—posting a resume or getting details about an available position—would be of use both to users of the site and other sites with similar data. An additional standard could be developed even on top of SOAP to specifically suit the types of Web services these sites would offer.

  • + Share This
  • 🔖 Save To Your Account

Related Resources

There are currently no related titles. Please check back later.