shellxmlrpc.jar

Description
This bundle provides a simple XML-RPC remote interface to the Oscar's shell service.
It contains also the classes of a cmd line client (and an associated ANT task).
This bundle is an alternative to the Telnet shell ! For more details on how to use this bundle, refer to the /doc/readme.html file embedded in the bundle jarfile

Contributors
Didier Donsez (Didier.Donsez@ieee.org)

License
LGPL

Services
None

Properties
None

Requirements
Service org.ungoverned.oscar.service.shell.ShellService
Service com.softsell.open.osgi.xmlrpc.XmlRpcService

Package org.ungoverned.gravity.servicebinder ;specification-version=1.0
Package org.ungoverned.oscar.service.shell
Package com.softsell.open.osgi.xmlrpc
Package org.apache.xmlrpc


Download

Build

  1. configure the build properties in build.xml
  2. add apache-xmlrpc.jar and openosgi-xmlrpc.jar jarfiles in ./lib (this is normally done by the locallibs target in build.xml)
  3. build with ant

Usage

First install and start shellxmlrpc.jar and its dependencies on the OSGi gateway with the following OSCAR shell command lines:

start http://oscar-osgi.sf.net/br/servlet.jar
start http://oscar-osgi.sf.net/br/http.jar
start http://oscar-osgi.sf.net/br/osgi-util.jar
start http://oscar-osgi.sf.net/br/openosgi-xmlrpc.jar
start http://oscar-osgi.sf.net/br/servicebinder.jar
start http://www-adele.imag.fr/~donsez/dev/osgi/shellxmlrpc/shellxmlrpc.jar

So now, you can invoke OSCAR shell commands from a remote workstation. Two ways are available.

The first way to invoke is to run this Java program :
java -classpath %LOCAL_CLASSPATH% fr.imag.adele.bundle.shellxmlrpc.client.ShellXmlRpc http://localhost:80/xmlrpc shell cmdline
java -classpath $LOCAL_CLASSPATH fr.imag.adele.bundle.shellxmlrpc.client.ShellXmlRpc http://localhost:80/xmlrpc shell cmdline
where cmdline is a OSCAR shell command line between quotes
and the environment variable LOCAL_CLASSPATH must contains the xmlrpc jarfile and the bundle jarfile
You can test this way with this script
test.bat (or test.sh)


The second way to invoke is to run the <shellxmlrpc> ANT task in a build file
You can test this way with this build file
ant -f build.for.test.xml

TODO (contributions are welcome)