SOAP Gateway

soap-gateway  —  help
 |  services  |  tests

soap-gateway

William Byrne / [email protected]

An experimental OpenACS SOAP package that may prove itself useful.

Developed using the following system configuration:

Abstract

The soap-gateway is a compilation of server side tcl procedures and pages that provide Remote Procedure Call (RPC) capabilities to OpenACS servers for clients using SOAP/HTTP. The implementation is relatively small and maintains minimal conformity to current SOAP specifications. This document describes the basic implementation.

Table of Contents

  1. Overview
  2. Installation
  3. Samples
  4. References
  5. License

Overview (toc)

The Simple Object Access Protocol (SOAP) v1.1 was submitted to W3C on April 18, 2000. Its compatriot Web Services Description Language (WSDL) was submitted on March 14, 2001. Together they attempt to unify diverse systems using a form of XML RPC. Most major software vendors are involved to some extent. Its future looks bright.

SOAP fits nicely into the Client/Server topology. Given a client that needs some functionality available on a server, SOAP can be used to specify an operation and its arguments to be submitted by the client to the server. At it's root, the data representing the operation is fairly basic. If the connection between the client and server were a TCP wire, a data trace would show about a page of XML. The XML is not complex and is often decipherable at a glance. The XML data is specified as a SOAP Envelope. An evolving SOAP specification defines the Envelope and its progeny. The XML data transmitted between the client and server is not arbitrary and should conform to a referenced WSDL instance published by the server. It's the WSDL that defines the published services and the invocation formats required for execution. The vast majority of SOAP documentation demonstrates SOAP over HTTP. Another mentioned transport is SMTP. In each case, the SOAP Envelope follows the respective header as an XML Payload.

Many web servers have been retrofitted to support a SOAP subsystem; e.g., Websphere, Apache, iPlanet, IIS, etc. There are a handful of SOAP toolkits. To name a few, MSSOAP Toolkit from Microsoft, AXIS from Apache, and DataSnap from Borland. A stand alone Tcl implementation, TclSOAP, is available at Source Forge. In the Implementation section, I'll get into the details of my retrofit for OpenACS; the soap-gateway package. Client SOAP examples using MSSOAP and AXIS can be found in the Samples section.

Installation (toc)

Here's a short list of steps required to enable SOAP/HTTP connectivity to your server. The instructions are brief and assumes the reader has administrative experience with OpenACS. More details will be available in a subsequent release.

  1. Select the SOAP Gateway from the list of packages that are available for installation. Install it.
  2. Create a sub-site under the Main site and call it 'soap'.
  3. Create a new application by selecting the SOAP Gateway.
  4. For now, call the new soap-gateway application SOAP Gateway.
  5. Refresh this page so this admin hot link points to the soap-gateway admininistration pages.
  6. Under the Maintenance section, you should see unpublished services: 'workspace' and 'interop'. Import both.
  7. In the same section, you may see a message that indicates 'Registered Users' do not have 'invoke' access on the soap-gateway package. If so, go to the permissions area for the soap-gateway instance if you wish to grant 'invoke' rights to registered users.
  8. Go to the Samples section and try the test samples. Take note of the https warning when https'ing.

Note: Verify 'public' access to your installed 'soap-gateway' using http and not https. Select the home of your 'soap-gateway' subsite to retrieve a listing of available services. Also verify the WSDL for each service can be returned without the need to authenticate into your server. This will allow clients to enumerate the published services and retrieve the functional specification for each. Eliminating the need to authenticate with the server for the purpose of retrieving service WSDLs removes binding complications for client side SOAP tools.

When importing a tcl library into the soap-gateway (i.e., any public methods under the ::sg::<my-service> namespace), the soap-gateway automatically grants public 'invoke' rights to any method named 'login'. This gives the client an opportunity to authenticate into the server before making any other calls.

Service libraries shipped with the soap-gateway are located in packages/soap-gateway/lib.

Samples (toc)

Sample SOAP client applications can be found here.

References (toc)

License (toc)

The SOAP Gateway package is subject to the Lesser General Public License.