Skip to main content


developerWorks  >  SOA and Web services | Grid computing  >

Using Ajax with WSRF::Lite

Manipulate WSRF::Lite WS-Resources using Ajax

developerWorks

Level: Intermediate

Mark McKeown (Mark.McKeown@manchester.ac.uk), Freelance Writer, U.K. Grid Support Center
Bruno Harbulot (Bruno.Harbulot@manchester.ac.uk), Grid Architect, MichaelDKelly.com

08 May 2007

Register now or sign in using your IBM ID and password.

Learn how the state of a WS-Resource deployed in WSRF::Lite, a Perl implementation of the Web Service Resource Framework (WSRF), can be displayed and modified by a Web browser using Asynchronous JavaScript + XML (Ajax). In this tutorial, an example WS-Resource illustrates how you can combine XSLT and JavaScript code with WSRF in WSRF::Lite to create Web browser-based clients.

In this tutorial

In this tutorial, you take the example counter WS-Resource from "Build WS-Resources with WSRF::Lite" and learn how it can be queried and updated using a Web browser. The tutorial begins with a short review of WSRF, WSRF::Lite, and the counter WS-Resource. Then you learn how to use HTTP to access WS-Resources in WSRF::Lite. Next, the tutorial introduces you to XSLT and shows how you can use it to transform the XML ResourcePropertyDocument of the counter WS-Resource into HTML for display in a browser. Finally, you use JavaScript code to automatically update the browser page, as well as modify the value of the counter WS-Resource.

Share this tutorial

digg Digg this story
del.icio.us Post to del.icio.us
Slashdot Slashdot it!


Prerequisites

You should be familiar with Perl, WSRF, and WSRF::Lite. If you are unfamiliar with WSRF::Lite or WSRF, we recommend completing the first tutorial in the series, "Build WS-Resources with WSRF::Lite." However, it is not necessary to complete the second tutorial, "Build secure WS-Resources with WSRF::Lite and WS-Security," as the focus in this tutorial is not on security. The tutorial introduces and discusses XSLT, CSS, and JavaScript coding.


System requirements

To run the examples in this tutorial, you need a computer running Linux® and WSRF::Lite V0.8.2 or later. The Perl module XML::CanonicalizeXML must also be installed. WSRF::Lite can function without this, but it is required to support access using Ajax, which is the focus of this tutorial. You also need Mozilla Firefox or Windows® Internet Explorer® to query and update the example counter WS-Resource used here. A command-line HTTP client, such as curl or wget is also required.



Formats

html, pdf


Share this....

digg Digg this story del.icio.us del.icio.us Slashdot Slashdot it!


Back to top


Document options

Document options requiring JavaScript are not displayed