== InteGrade middleware RESTful Web Service -- ASCT-WS ==

This document explains how to install and run the InteGrade RESTful Web Service, 
the ASCT-WS. 


  === Requirements ===

* Apache Ant
  It may be downloaded at http://ant.apache.org/

* the InteGrade middleware
  It may be downloaded at http://www.integrade.org.br
read its documentation in order to install it properly.

* JUNIT 
  It may be downloaded at http://sourceforge.net/projects/junit/

* Apache CXF
  It may be downloaded at http://cxf.apache.org/


  === Configuration ===

* Export into the CXF_HOME variable the path of the CXF folder, for instance

export CXF_HOME=/usr/local/apache-cxf-2.5.2/

* Export into the JUNIT_HOME variable the path of the JUNIT folder, for instance

export JUNIT_HOME=/usr/local/junit4.10/

* Export into the JACORB_HOME variable the path of the JacORB install, an InteGrade's dependency.
It may be exported through the following command at the InteGrade's install directory:

source ./startservices.sh env

  If the Web Service is not located at the same machine that InteGrade middleware is, then it is 
necessary to download the JacORB at http://www.jacorb.org/, to install it and to export into 
the JACORB_HOME the directory where it was installed.


  === Compiling and running the Web Service ===

* Enter the ASCT-WS directory (usually trunk/integrade/tools/asct-ws)

* Compile the code using the command "ant". "ant -projecthelp" shows the all the available options.

NOTE: some options, such as the host's domain and port where the Web Service will run, may be
configured editing the "build.xml" file. Domain and port, for instance, must be modified
at the sysproperty with key "asct_ws.url".


* To run the server, use "ant runserver". 


  === Using the Web Service ===

* If the domain is "myserver.com" and the port is "9090", so the following URI should list all
the applications stored in the Application Repository:

http://myserver.com:9090/applications

* The complete ASCT-WS's API documentation is available at the InteGrade web page,
at http://www.integrade.org.br.

--------------------------------------------------------------------------------