This document describes how to start the various programs that make up a MIF installation. Generally, it is assumed that Windows machines will be used for development purposes and UNIX-like machines will be used for development and server installations. Therefore, the UNIX-like operating systems will have extra functionality installed on them such as scripts to run processes in the background. All paths in this wiki are relative to
$MIF_HOME unless noted otherwise.
Here are the important sub-directories and files which you will find in the installation directory ($MIF_HOME):
bin: Startup and shutdown scripts for MIF
config: Configuration files for MIF and other programs. These files will be in the classpath if the startup scripts from bin/ are used.
jars: All MIF jars including dependency jars.
log: Log files for MIF.
sources/mif-samples: All the sample source code for the samples documented in the wiki.
docs: READMES and API documentation for this release
These script have been tested on Windows XP, Linux EL4, and Mac OS X. However, it is very likely that they would also work on any other version of Windows or UNIX.
Starts MIF by calling the
RunMif class. Calling with the -h option gives a help screen. Here are some usage examples:
- Start MIF by specifying a classname for a class with a main method which creates, configures, and starts a MIF pipeline”
> bin\run-mif.bat -c com.foo.bar.ClassName
- Start MIF using the Spring configuration file
mifConfig.xml. This will search for the given config file on the MIF classpath. By convention all properties files are placed the directory
> bin\run-mif.bat -s mifConfig.xml
- Start the MIF sample
> bin\run-mif.bat -c gov.pnnl.mif.samples.hello.HelloWorldDriver
For the most part, Linux and Mac OS X installs are treated identically. They each have bash counterparts for all the batch scripts listed in the windows section. The bash scripts behave the same as the batch scripts, with the following exceptions:
This script starts JBoss as a server (bound to 127.0.0.1) in the background. Standard out and standard error are redirected to
log/jboss-console.log. Example usage:
> bin/jboss.sh start ejb3-clustered Starting jboss with: cd /local/MIF-0.7.4/third-party/jboss/bin; /local/MIF-0.7.4/third-party/jboss/bin/run.sh -c ejb3-clustered -b 127.0.0.1 Console output being sent to: /local/MIF-0.7.4/log/jboss-console.log ------------------------------------ NOTE: JBoss binding to: 127.0.0.1 ------------------------------------
This starts JBoss using the server configuration
ejb3-clustered. If no server is specified, then the default (
mq-standalone) is started. It's always a good idea to check the log file to make sure it started correctly. To cause JBoss to bind to a different address, edit this script and modify the variable
To stop jboss, type:
> bin/jboss.sh stop Stopping jboss with: kill 7489
To check whether JBoss is currently running:
> bin/jboss.sh status JBoss is running (7440)
This is used to start MIF in the foreground or background. The usage for this command is:
bin/mif-ctrl.sh [start <mif-args> | start-fg <mif-args> | stop <force> | status | help]
So, it is similar to mif-run.bat except that it has an additional first argument. The remaining arguments are passed to the class
RunMif. For example, to start MIF in the background using the specified properties file, type:
> bin/mif-ctrl.sh start -c helloComponent.properties
bin/run-mif.sh is a convenience script which matches the functionality of
run-mif.bat by wrapping a command similar to:
mif-ctrl start-fg $@