Wed, Jun
4 New Articles

Web Services and SOAP

  • Smaller Small Medium Big Bigger
  • Default Helvetica Segoe Georgia Times

After a spectacular birth and early development, the Internet is blossoming into a medium for users to interact with businesses and services in new, exciting, and complex ways. By necessity, dynamic Web content will increasingly be driven by more than one provider, whether that provider is a remote corporate office or a major Web portal. These providers will need tools to allow smooth interoperation between hosts and platforms. The focus of Microsoft’s latest all-encompassing technology initiative, Microsoft .NET (pronounced dot net), are Web services—applications built to a universal platform for information exchange. Announced last June, Microsoft .NET is a major evolution of the DNA (Distributed interNet Applications) architecture, which promoted multitiered, component-based programming. The Microsoft .NET Web services architecture seeks to extend the distribution of components and applications across the Internet via the Simple Object Access Protocol (SOAP). In the Microsoft .NET vision, future dynamic Web content will be driven by multiple Web services hosted by various providers throughout the intranet and Internet.

A loose definition of a Web service is simply server-based functionality available over the World Wide Web via standard URL addressing. A search engine is a common Web service. To the user, a search engine appears to be a single, simple interface: enter a query and click Search to retrieve the results. However, think about all the functionality going on behind the scenes. The query is performed against large-scale indexing databases, employing various Web techniques to trawl for pages. The users’ mouse clicks are often recorded and analyzed to provide profiling and performance feedback. The targeted advertising displayed on the results page is also somehow generated. Customized results are often tailored for registered users. To provide quick results, search engine sites must distribute these functions among several services running on multiple servers unseen by the user. Major portal sites must currently build custom solutions such as these to enhance their users’ visits. The Web services paradigm intends to simplify this level of scalability and integration for all content providers. You are probably not considering architecting the next great search engine site. You may want to consider leveraging the Web infrastructure for your next distributed application, however, unless you don't anticipate Web application requirements or the need for long-term scalability. SOAP is the messaging system providing the high level of integration for Web services. On the Windows platform, SOAP

is a vehicle for deploying Component Object Model (COM) objects on the Web and for integrating with non-Microsoft systems.

Casting a Wide .NET

The Microsoft .NET developer initiative seeks to simplify Web programming on many fronts. On the Windows platform, a Common Language Runtime (CLR) with significant features such as garbage collection is provided for all Microsoft .NET-compliant languages to share. Creating components housing business logic will be simplified by true language interoperability and major object-oriented enhancements. Most Microsoft .NET languages will also operate in the next-generation Active Server Pages (ASP) environment. Microsoft released a beta version of Visual Studio.NET, which is the development environment for creating Windows-based Web services on Microsoft.NET. The goal is to make the programming and use of Web services as simple as writing and calling a subroutine.

On the network, Microsoft .NET specifies SOAP. The SOAP protocol is a World Wide Web Consortium (W3C) standard in progress, allowing all internet-capable platforms, including Java-based platforms, to provide and consume SOAP-based Web services. IBM is actively participating in the SOAP standard effort as well. In the past, Microsoft had offered its proprietary Distributed Component Object Model (DCOM) as the primary distributed programming protocol for components, effectively shutting out non- Windows server platforms. The shift to the open SOAP standard is perhaps the most exciting aspect of Microsoft .NET.

Introducing SOAP

SOAP employs existing Internet standards to help broaden its appeal. In particular, HTTP and XML are the major building blocks of SOAP. XML, the lingua franca of Web services, is used to write SOAP messages. SOAP messages can be sent over a variety of client/server-based network protocols, including the Web standard HTTP, to provide the same accessibility Web servers and browsers enjoy.

SOAP messages carry typed data that can be universally interpreted. XML describes both the data and its structural representation in a SOAP message. Remote Procedure Call (RPC) systems such as Web services can thus pass parameters and return results in a platform-agnostic manner. The current draft protocol consists of three major parts. First, the envelope defines how a message is to be described and the steps for processing it. Second, the encoding rules describe how application-specific data types are exchanged. Third, SOAP provides conventions for implementing RPC calls and responses.

Figures 1 and 2 show very basic SOAP request and response message examples, respectively. The request message shows how a Web services client (which could be another Web server or a client application) might query for customer information using a customer ID. The required SOAP-ENV:Envelope XML element identifies the envelope for the message. The SOAP-ENV:Body element contains an element defined by the Web service to denote the search function FindSubscriber, which, in turn, contains the customer ID data for the query. It contains an element defined by the Web service to denote the search function FindSubscriber. The subid element contains the parameter data passed to this function.

The response message (Figure 2) shows the same envelope element structure, with results being returned in the mc:FindSubscriberResponse element. Many details are missing from these examples. In particular, the encoding rules describing the data passed as the subid parameter and returned in the subdescription structure are not explicitly carried in the envelope. They are referred to, however, in the XML schema document named by the xmlns:mc attributes of the mc:FindSubscriber and mc:FindSubscriberResponse elements. The data contained in the messages are name and value pairs expressed in terms of XML elements and values. The schema comprises the set of encoding rules. It contains descriptions of the allowable data type elements and how to interpret their values. This

schema can be hand-coded, but is more likely to be machine-generated by SOAP tools based on application-domain specifics.

Visual Studio SOAP Toolkit

At the Microsoft Professional Developer’s Conference last July, developers were treated to a sneak preview of the features targeted for the forthcoming release of Visual Studio.NET (VS.NET). VS.NET promises to make the construction of Web services no more difficult than creating a Windows form-based application. Built-in wizard tools will generate and maintain a lot of the SOAP details for you. In the meantime, however, Microsoft offers a free toolkit that allows you to quickly prototype your own Web services using currently available software.

The SOAP toolkit for Visual Studio 6.0 contains a wizard that generates SOAP- based Web services wrapper code for COM components running on the Windows Internet Information Server (IIS) Web server. This tool takes the type library information for a specific Windows component Dynamic Link Library (DLL) and generates the XML-based contract language containing the SOAP encoding specifics. The contract language, called Web Services Description Language (WSDL), describes the method signatures of the interface methods of the components exposed as Web services.

The wizard can also generate the ASP scripts that, along with the toolkit’s listener.asp script, comprise the listener function of a Web service. Basically, a VBScript function is generated for each method and property of the component DLL. The listener.asp script and some underlying toolkit components interpret the incoming SOAP requests using the WSDL for the service. This results in a call to the generated VBScript wrapper method, which calls the component’s method.

Here’s a quick review. The SOAP toolkit wizard creates an ASP-based Web service based on a COM component DLL containing your business logic. With the WSDL and ASP scripts the wizard generates, you configure IIS to permit Web address access to the scripts. Presto! You have a Web service.

Using Web Services

The SOAP toolkit provides helper functionality for accessing Web services too. Generally, to access a particular Web service, a client program must know the following:

• Where the service is located (i.e., a URL)
• How to get and interpret the description of the service
• How to use the SOAP to invoke the service

These steps are usually referred to as Web service discovery and are mostly implemented by the toolkit components known as the Remote Object Proxy Engine (ROPE). ROPE is used by a Web service user as a proxy for the component being accessed on the remote site. Once located and its description successfully parsed, a Web service modeled as a COM component may be accessed as if the Web service were a local instance, as in the following Visual Basic fragment:

Dim bRes As Boolean
Dim oProxy As New ROPE.Proxy
bRes = oProxy.LoadServicesDescription icURI, _

If bRes False Then


The URL http://webhost/myserv/soapserv.xml is the address of the description of the service, and soapserv.xml is WSDL, as generated by the wizard for wrapping a COM object. The ROPE.Proxy component’s LoadServicesDescription method is used to load the

description. Based on the contents of the description, the Proxy instance can invoke the remote MyWebserviceMethod in a natural way. The assumption made by this code is that MyWebserviceMethod exists as a Web service endpoint function. The Proxy object also provides methods for checking this and other description details at runtime.

The SOAP toolkit is just one software development kit (SDK) for implementing SOAP solutions. IBM’ s SOAP4J implementation (written in Java) is now the base for the Apache XML Project’s Apache SOAP project. These early-adopter toolkits expose some of the nuts and bolts of SOAP that the programmer will be shielded from in the eventual release of Visual Studio.NET. Even more sophisticated tools will probably follow.

Enhancing Discovery

As the tools rollout, more and more SOAP-based Web services will be coming online. According to the Microsoft plan, eventually Web service providers will emerge that will want to widely distribute their software using this model. A working example of the Web services model is already online at the Microsoft Office eServices Web page at officeupdate.microsoft.com/services/default.asp. Any large-scale distribution effort will likely require a centralized registry for posting and finding Web services over the Internet. The Universal Description, Discovery, and Integration (UDDI) specification has been proposed and supported by Microsoft and IBM as a standard for such a registry.

At its most basic, UDDI is an initiative to provide businesses with a way to publish their methods of conducting business over the Internet. Thus far, the focus of the technical effort has been on XML, SOAP, and the established Web standards. The goal is to make the discovery of Web services a ubiquitous Internet service, much like the Domain Name System (DNS) for mapping host names to IP addresses. The UDDI group has pledged to make any resulting registry open to all businesses and is currently accepting registrants on its site at www.uddi.org.

Not Done Yet

SOAP-based Web services are a very exciting new way for distributing business objects over the Internet. There are problems to work out, however. As of this writing, the standard for XML Schema, a critical part of the SOAP standard, has not been finalized. Other standards, including the SOAP Contract Language and the precise discovery algorithm are yet to be drafted. How these will evolve as Microsoft rolls out its Microsoft
.NET technology releases will determine their acceptance.


• "A Young Person's Guide to the Simple Object Access Protocol: SOAP Increases Interoperability Across Platforms and Languages, " Don Box, MSDN Magazine Online, March 2000 (http://msdn.microsoft.com/msdnmag/issues/0300/soap/ soap.asp)

• Apache SOAP Project: http://xml.apache.org/soap/index.html

• “Cleaning Up the Web with SOAP,” Don Denoncourt, MC, September 2000

• "Develop a Web Service: Up and Running with the SOAP Toolkit for Visual Studio," Rob Caron, MSDN Magazine Online, August 2000 (http://msdn.microsoft. com/msdnmag/issues/0800/webservice/webservice.asp)

• “Doing E-Business with XML Schemas and SOAP,” Eduardo Ross, MC, July 2000

• Microsoft .NET Developer Center: http://msdn.microsoft.com/net/default.asp

• Microsoft SOAP Technology page: http://msdn.microsoft.com/soap/default.asp

• "Simple Object Access Protocol (SOAP) 1.1," W3C (www.w3c.org/TR/SOAP/)

• SOAP Toolkit for Visual Studio 6: http://msdn.microsoft.com/xml/general/ toolkit_intro.asp

• UDDI group home page: www.uddi.org




Figure 1: The request for a Midrange Computing subscriber’s information includes the subscriber ID.


This email address is being protected from spambots. You need JavaScript enabled to view it.

Figure 2: A response to the request of Figure 1 contains some customer detail data.



Support MC Press Online

$0.00 Raised:

Book Reviews

Resource Center

  • SB Profound WC 5536 Have you been wondering about Node.js? Our free Node.js Webinar Series takes you from total beginner to creating a fully-functional IBM i Node.js business application. You can find Part 1 here. In Part 2 of our free Node.js Webinar Series, Brian May teaches you the different tooling options available for writing code, debugging, and using Git for version control. Brian will briefly discuss the different tools available, and demonstrate his preferred setup for Node development on IBM i or any platform. Attend this webinar to learn:

  • SB Profound WP 5539More than ever, there is a demand for IT to deliver innovation. Your IBM i has been an essential part of your business operations for years. However, your organization may struggle to maintain the current system and implement new projects. The thousands of customers we've worked with and surveyed state that expectations regarding the digital footprint and vision of the company are not aligned with the current IT environment.

  • SB HelpSystems ROBOT Generic IBM announced the E1080 servers using the latest Power10 processor in September 2021. The most powerful processor from IBM to date, Power10 is designed to handle the demands of doing business in today’s high-tech atmosphere, including running cloud applications, supporting big data, and managing AI workloads. But what does Power10 mean for your data center? In this recorded webinar, IBMers Dan Sundt and Dylan Boday join IBM Power Champion Tom Huntington for a discussion on why Power10 technology is the right strategic investment if you run IBM i, AIX, or Linux. In this action-packed hour, Tom will share trends from the IBM i and AIX user communities while Dan and Dylan dive into the tech specs for key hardware, including:

  • Magic MarkTRY the one package that solves all your document design and printing challenges on all your platforms. Produce bar code labels, electronic forms, ad hoc reports, and RFID tags – without programming! MarkMagic is the only document design and print solution that combines report writing, WYSIWYG label and forms design, and conditional printing in one integrated product. Make sure your data survives when catastrophe hits. Request your trial now!  Request Now.

  • SB HelpSystems ROBOT GenericForms of ransomware has been around for over 30 years, and with more and more organizations suffering attacks each year, it continues to endure. What has made ransomware such a durable threat and what is the best way to combat it? In order to prevent ransomware, organizations must first understand how it works.

  • SB HelpSystems ROBOT GenericIT security is a top priority for businesses around the world, but most IBM i pros don’t know where to begin—and most cybersecurity experts don’t know IBM i. In this session, Robin Tatam explores the business impact of lax IBM i security, the top vulnerabilities putting IBM i at risk, and the steps you can take to protect your organization. If you’re looking to avoid unexpected downtime or corrupted data, you don’t want to miss this session.

  • SB HelpSystems ROBOT GenericCan you trust all of your users all of the time? A typical end user receives 16 malicious emails each month, but only 17 percent of these phishing campaigns are reported to IT. Once an attack is underway, most organizations won’t discover the breach until six months later. A staggering amount of damage can occur in that time. Despite these risks, 93 percent of organizations are leaving their IBM i systems vulnerable to cybercrime. In this on-demand webinar, IBM i security experts Robin Tatam and Sandi Moore will reveal:

  • FORTRA Disaster protection is vital to every business. Yet, it often consists of patched together procedures that are prone to error. From automatic backups to data encryption to media management, Robot automates the routine (yet often complex) tasks of iSeries backup and recovery, saving you time and money and making the process safer and more reliable. Automate your backups with the Robot Backup and Recovery Solution. Key features include:

  • FORTRAManaging messages on your IBM i can be more than a full-time job if you have to do it manually. Messages need a response and resources must be monitored—often over multiple systems and across platforms. How can you be sure you won’t miss important system events? Automate your message center with the Robot Message Management Solution. Key features include:

  • FORTRAThe thought of printing, distributing, and storing iSeries reports manually may reduce you to tears. Paper and labor costs associated with report generation can spiral out of control. Mountains of paper threaten to swamp your files. Robot automates report bursting, distribution, bundling, and archiving, and offers secure, selective online report viewing. Manage your reports with the Robot Report Management Solution. Key features include:

  • FORTRAFor over 30 years, Robot has been a leader in systems management for IBM i. With batch job creation and scheduling at its core, the Robot Job Scheduling Solution reduces the opportunity for human error and helps you maintain service levels, automating even the biggest, most complex runbooks. Manage your job schedule with the Robot Job Scheduling Solution. Key features include:

  • LANSA Business users want new applications now. Market and regulatory pressures require faster application updates and delivery into production. Your IBM i developers may be approaching retirement, and you see no sure way to fill their positions with experienced developers. In addition, you may be caught between maintaining your existing applications and the uncertainty of moving to something new.

  • LANSAWhen it comes to creating your business applications, there are hundreds of coding platforms and programming languages to choose from. These options range from very complex traditional programming languages to Low-Code platforms where sometimes no traditional coding experience is needed. Download our whitepaper, The Power of Writing Code in a Low-Code Solution, and:

  • LANSASupply Chain is becoming increasingly complex and unpredictable. From raw materials for manufacturing to food supply chains, the journey from source to production to delivery to consumers is marred with inefficiencies, manual processes, shortages, recalls, counterfeits, and scandals. In this webinar, we discuss how:

  • The MC Resource Centers bring you the widest selection of white papers, trial software, and on-demand webcasts for you to choose from. >> Review the list of White Papers, Trial Software or On-Demand Webcast at the MC Press Resource Center. >> Add the items to yru Cart and complet he checkout process and submit

  • Profound Logic Have you been wondering about Node.js? Our free Node.js Webinar Series takes you from total beginner to creating a fully-functional IBM i Node.js business application.

  • SB Profound WC 5536Join us for this hour-long webcast that will explore:

  • Fortra IT managers hoping to find new IBM i talent are discovering that the pool of experienced RPG programmers and operators or administrators with intimate knowledge of the operating system and the applications that run on it is small. This begs the question: How will you manage the platform that supports such a big part of your business? This guide offers strategies and software suggestions to help you plan IT staffing and resources and smooth the transition after your AS/400 talent retires. Read on to learn: