Configuration

Overview

This covers how to configure IRV to talk to different database and middle-tier servers.

Note that the IRV client is configured all at runtime (e.g. via command line arguments) and so is not covered.

However, both the various BuildSystemtargets for executing database creation, test execution, etc. and also the middle-tier EJBs for communication with the database rely on this configuration scheme.

Note: configuration of EJBs is at compiletime and hence settings are hard-coded into the IRV EAR file. Changes (for example, the database server the EJBs will use) requires following the configuration steps covered below and then re-creating and re-deploying the IRV EAR file with the BuildSystem.

Default Behavior

By default, both the database and EJB server are assumed to be on the local machine. As such, the BuildSystemloads the config\db_local.properties and config\ejb_local.properties, which contain the database connection information and EJB server host, respectively.

Custom Behavior

To change these properties, create new database and EJB files in the config directory. For example, db_yourmachine.proprties and ejb_hismachine.properties.

To execute tests or create an IRV EAR file with these custom, non-local properties, you can do two things:

1. Call ant with a -Dconf.db=yourmachine and/or -Dconf.ejb=hismachine command line arguments

2. Create a config\default.properties file with the lines conf.db=yourmachine and/or conf.ejb=hismachine

The first approach will require using the -D arguments upon each invocation of ant.

The second approach will become your default setup and no longer require -D arguments or continually changing property files (for example, one of our developers is not running a database locally on his machine, so created a default.properties with the line conf.db=db_candyland.properties and his BuildSystemnow uses that database for all test execution and IRV EAR file creation).