Skip to content

Working with Batch Configurations

Chase Tingley edited this page Dec 29, 2015 · 3 revisions

Batch configuration (.bconf) files package Rainbow settings for use in the Longhorn server environment. They are typically generated by Rainbow itself. However, when many bconfs are in use, it is time-consuming to generate each by hand.

Creating bconfs with <okapi:mkbconf>

This task provides similar functionality to the "Export Batch Configuration" feature in Rainbow. <okapi:mkbconf> can either generate a bconf based on a Rainbow settings (.rnb) file, or a combination of component files such as a pipeline (.pln) file and filter configuration (.fprm) files.

An example of each method can be found in the examples/mkbconf directory.

Generating from a settings file

<okapi:mkbconf settings="config/settings.rnb"
        bconfPath="output.bconf"
        filterConfigDir="config">
    <!-- Add any additional plugins -->
    <fileset dir="plugins" includes="**/*.jar"/>
    <!-- filter configs are imported from the rnb file; these are
       - then added, overriding previous mappings. The value of
       - 'filterConfigDir' is searched for custom fprm files. -->
    <filterMapping extension=".xml" filterConfig="okf_xmlstream@cdata" />
</okapi:mkbconf>

Generating from a pipeline file

<okapi:mkbconf pipeline="config/pipeline.pln"
        bconfPath="output.bconf"
        filterConfigDir="config">
    <!-- Add any additional plugins -->
    <fileset dir="plugins" includes="**/*.jar"/>
    <!-- filter configs are imported from the rnb file; these are
       - then added, overriding previous mappings. The value of
       - 'filterConfigDir' is searched for custom fprm files. -->
    <filterMapping extension=".xml" filterConfig="okf_xmlstream@cdata" />
</okapi:mkbconf>

Issues

When working with bconfs, the paths for any referenced files (for example, a SRX file used as a parameter for a segmentation step) should be specified relative to the location of the ant buildfile. In some cases, this may mean you need to modify your .pln or .rnb file to update the paths of these referenced files.

Exploding bconfs with <okapi:installbconf>

This task provides similar functionality to the "Install Batch Configuration" feature in Rainbow.

An example can be found in the examples/installbconf directory.

<!-- Very simple: write the contents of output.bconf to
   - the installed_bconf directory, which much exist and be empty. -->
<okapi:installbconf bconf="output.bconf" dir="installed_bconf" />