DARX v1.0 is available for download by clicking on the following link.
Please note that DARX is distributed under the GNU Lesser General Public License v3.
The distribution package is a tarred and gzipped archive; in order to access its contents you must use appropriate tools.
On a MacOS or a Windows machine, you can use the Stuffit Expander freeware.
On a Unix machine, you may want to use the following command: $ tar xvfz darx_distrib.tgz
The package contains the following files and directories :
|
API |
Directory containing the HTML documentation for the DARX API. It provides a thorough overview of the Java classes DARX is composed of, and as such offers a good insight on the source code. |
|
LICENSE |
File containing the licensing information about DARX: namely the fact that it is copyrighted to Olivier Marin in the context of the Laboratoire d'Informatique de Paris 6, and distributed under the GNU Lesser General Public License. |
|
Makefile.distrib |
File providing a set of useful commands when working with DARX. Commands can be called from the command line: $ make -f Makefile.distrib <command>
|
|
README |
Minimal startup guide for those who can't be bothered to read the present document before getting their hands dirty. |
|
darx_distrib.jar |
DARX software archive: contains both the source code and the Java bytecode. Should you wish to examine the source code, open a shell window, insert the path where you stored and gunzipped/untarred the distribution directory, and type in the following command: $ make -f Makefile.distrib extractsrc |
|
examples |
Directory containing the source code for the examples (see Strategy Switching Demonstration and Failure Recovery Demonstration) |
|
lgpl.txt |
Full text of the GNU Lesser General Public License v3. |
|
policy |
Java policy file for activating permissions in order to use the full potential of DARX over a network. |
|
startdarx |
Script file for launching a DARX server (see How to Use DARX) |
|
startnserv |
Script file for launching the DARX Name Server (see How to Use DARX) |
1. Make sure that the JAR file containing the bytecode for DARX (darx_distrib.jar) is present on every host where you wish to deploy the platform, and that you modified the CLASSPATH of the host accordingly.
2. Select a host for the Name Server and start it with the startnserv script file:
$ ./startnserv [-p <ns_port_number>] [-debug]
ns_port_number is the port number on which the Name Server will listen for connections; if no value is specified it defaults to 7777
debug mode means the Name Server operates in verbose mode, providing additional information for every request it processes
3. Start DARX servers with the startnserv script file:
$ ./startdarx [-ns <ns_url ns_port_number>] [-p <port_number>]
ns_url and ns_port_number are the URL and the port number on which the Name Server is listening for connections; if no value is specified it defaults to the values specified in the code (file NameServer.java)
port_number is the port number on which the DARX server awaits requests
4. Launch a client application. Examples may be found in the Makefile and are detailed below.
This example presents the main feature of DARX: replication strategy switching.
A Sender agent on Host A awaits message inputs from the user on the console, emits the messages to a Forwarder agent on host B which transmits them to a Displayer agent on a remote host C. As its name may hint at, the Displayer agent is in charge of displaying the contents of the messages it receives.
There are 4 phases, each separated by a single message emission (although this is alterable by setting the nb_of_inputs variable of the MsgSender Class to a different value):Phase 1. The Displayer agent is not replicated anywhere.
Phase 2. The Displayer agent gets replicated actively on host D.
Phase 3. The replication strategy for the Displayer agent is switched to passive with an update delay .
Phase 4. The replication strategy for the Displayer agent is switched back to active.To execute this example, you need to launch:
- The DARX Name Server
- 4 DARX servers (Hosts A, B, C and D)Once you have selected which machines will run the demonstration, you must alter the code accordingly. SENDER_URL, FORWARDER_URL, DISPLAYER_URL and BACKUP_URL must be set respectively to the URLs of hosts A, B, C and D. Each server must preferably be launched in a different terminal window for better readability. One final console will allow to launch the demonstration with the following command:
$ make -f Makefile.distrib switchtest
This example shows that agents can recover from failures when replicated on the DARX platform. The setting is exactly the same as in phase 2 of the replication switching example, except that the Sender agent takes in an infinite number of input messages from the user. The console command for launching this demonstration is as follows:
$ make -f Makefile.distrib failtest
In order to check that everything works as specified, all you need to do is kill the DARX server (host C) which runs the Displayer agent once all agents have been started and a first initial message has been successfully displayed. Any further messages sent by the user will automatically trigger a recovery. The Backup agent on Host D will be the one to take over the Displayer agent task.