The MonALISA Web Service


The MonALISA Web Service provides an interface for publishing the monitoring data and farm configuration using a WSDL/SOAP technology. This way any client can connect and receive selected data. It is available in the MonALISA Service and in the Web Repository (the Web Repository contains data gathered from several ML services). The Web Service was developed using Apache AXIS.
For a detailed description of the Web Service visit the MonALISA Web Service page.

Deploying MonALISA as a Web Service

By default the Web Service will not be deployed when you start the MonALISA Monitoring Service. If you wish to start the Web Service you need to set the following parameters in your file:
You must then restart the MonALISA Service:
            cd $MonaLisa_HOME/Service/CMD
            ML_SER restart

Firewall Requirement

If you plan to access the Web Service from outside your firewall you must open TCP port 6004 (or whatever port you have set above) for incoming requests.
Once the Web Service is running try to access the following URL from a web browser: http://your_hostname:6004/axis/services/MLWebService

Web Service Clients

The MonALISA developers provide Web Service Clients for accessing the monitored data either from a MonALISA service or from a Web Repositoty. Three different types of clients were developed: One based on Apache AXIS, one on Apache WSIF and one on Perl SOAP:Lite modules.
All three clients are in a single tar file which can be downloaded from here. To deploy the clients download the latest tar file (currently monalisaWSClients-1.0.1.tar.gz) on the host from which you plan to access the MonALISA Web Service and untar it. Go to the created monalisaWSClients directory and run the script It will prompt you for the Web Service URL which will be stored in a file ./conf/env.MONALISA_WS. This URL will be used as the default Web Service URL by all clients. Running the script will also create ./conf/env.JAVA_HOME.
In my case I have set:
[stratos@salonica monalisaWSClients]$ ./ 
Please enter the MonALISA Web Services URL :

Configuration completed successfully.
You must then decide which clients to use. You have three choices: The Java-Axis clients, the WSIF clients or the Perl SOAP::LITE clients.

Using the JAVA-AXIS Clients

To use the Java-Axis Clients go to WS-Clients/Java-Axis directory. There you should find a couple of subdirectories, each for a different operation (getValues, getConfiguration). Go to one of them and run the generate_classes script:
                 cd getValues
The script generate_classes invokes the WSDL2Java utility to access the WSDL file of the Web Service and create the Java packages that are needed (under ./lia/ws/ and ./ws/lia/).
Then run compile_classes to compile the Java classes, including the provided class:
You are now ready to run run_client (with the appropriate options) to invoke the MonALISA Web Service. The availaible options for the run_client script are listed in the Readme file, but basically the format has as follows:
              ./run_client FarmUnit ClusterUnit Host Parameter FromTime ToTime
the FromTime and ToTime above are in milliseconds.


                cd monalisaWSClients/WS-Clients/Java-Axis/getValues
                ./run_client "bnl-itd" "Master" "localhost" "Load5" -600000 0 

Use my version of the Java-Axis Client

Here I provide a Java class ( which can be used instead of the class provided by monalisaWSClients.tar.gz. To download it click here:

Using the Perl SOAP::Lite Clients

To use the Perl clients go to WS_Clients/Perl. The first thing you need to do is install two Perl Modules SOAP::LITE and TIME::HIRES. Two scripts install_soap_lite and install_time_hiref are provided that will install these two modules. The scripts must be run by root.
You should then go to one of the subdirectories (getValues or getConfiguration) and execute the perl script


                   ./ "bnl-itd" "Master" "localhost" "Load5" -600000 0
The arguments are the same with those used in the Java-Axis Clients.

Using the Java-Axis Clients on Windows

On a Windows machine, instead of running the script generate_classes, you can invoke the WSDL2Java utility manually (provided that you have Java and AXIS installed):
java -cp C:\axis-1_1\lib\axis.jar;C:\axis-1_1\lib\axis-ant.jar;
org.apache.axis.wsdl.WSDL2Java -v -o MonaLisa

Parsing XML file:
Generating MonaLisa\lia\ws\
Generating MonaLisa\lia\ws\
Generating MonaLisa\lia\ws\
Generating MonaLisa\lia\ws\
Generating MonaLisa\lia\ws\
Generating MonaLisa\ws\lia\
Generating MonaLisa\ws\lia\
Generating MonaLisa\ws\lia\
Generating MonaLisa\ws\lia\
The above creates the necessary Java packages under the directory MonaLisa (the -o option). Copy either or in the MonaLisa directory, compile it using javac and you are ready.

Current Issues with the MonALISA Web Service

I currently have the following two issues with the MonALISA Web Service (I am using the version v1.0.1 of the MonALISA Service and version 1.0.1 of the Web Service Clients):

Stratos Efstathiadis - page was last modified