Starting an Application

Please see the JICOS Programming Manual for creating the java files for a JICOS application.  In what follows, I assume that:
  • you have created an application, whose fully qualified package name is called MyApplication
  • $JANET is an environment variable set to the directory into which janet-system.jar was extracted (See Downloading & installing JICOS).
Please insert a classpath, as needed by your application; this is not shown below. The Task classes for MyApplication that need to be downloaded to the Host[s] are accessed via a web server at url URL. To start MyApplication, execute:
java -Djava.rmi.server.codebase=URL
     -Djava.security.policy=$JANET/policy/policy
      MyApplication hsp-machine <other command-line parameters go here>
The 1st command-line parameter is the domain name of the machine on which the HSP's rmiregistry is listening. The command line below is an example of this:
java -cp /cs/faculty/cappello/r/p/janet/ 
 -Djava.rmi.server.codebase=http://www.cs.ucsb.edu/~cappello/classes/
 -Djava.security.policy=$JANET/policy/policy 
  janet.examples.helloworld.Application lysander
In this case, the package resides within /cs/faculty/cappello/r/p/janet/. That is, relative to the janet directory, there is an Application.class file whose package name is janet.examples.helloworld.

The class files for the HelloTask task is available for download via a web server from http://www.cs.ucsb.edu/~cappello/classes/ Don't forget the trailing "/". Also, the classes actually reside in the ~cappello/public_html/classes/janet/examples/helloworld directory.

The command-line parameters indicate that the HSP is running on a machine with domain name lysander. The application simply prints "Hello, world!" to System.out.