Configuration

This document describes the configuration possibilities of the DRM nodes drm.server.NakedNode and drm.test.TestGUINode. There are three ways of configuring the nodes: using a configuration file, from command line, or through setting system properties.

Configuration files

When using a configuration file the name of the file has to be given as a command line parameter. For example:
java drm.server.NakedNode /home/garfield/drm/config
The content of the configuration file should conform to the format specified by the java class java.util.Properties. The known properties and their description can be found in the following default configuration file.

Command line

Command line configuration can be used with or without a configuration file. Each command line argument is interpreted as a line of a configuration file. The command line parameters override the configuration file.

The first argument is interpreted as a configuration file name first. If a file with that name could be loaded then it is loaded and the rest of the arguments are interpreted as additional lines from a configuration file. If the file could not be loaded then all arguments (including the first one) are interpreted as configuration file lines. For example:

java drm.server.NakedNode config "port=11111" "runClass=myexp.jar!Launch"
would load the given config file, override the port number and run the given application after startup.
java drm.test.TestGUINode "port=11111"
simply uses the default values and the port number is set to the given value. We get into trouble if there is a file called "port=11111" but it is not very likely...

System properties

Besides configuration files systems properties can also be set when starting up the node. At the moment only one system property is understood:
java.io.tmpdir
This property gives the directory which will be used by the node to store temporary files, classes of arriving agents, etc. This directory must be writable by the node. Note that it is a standard system property so change it only if you really know what you are doing.

You can set any property in the java command line using the -D option if no default value is provided by the local environment or the default is not appropriate:

java -Djava.io.tmpdir="/home/garfield/.drm" drm.server.NakedNode