BASE 2.0 - Administrator documentation: Adding job agents

This document describes how to configure and install job agents.

Contents
  1. What is a job agent?
  2. How to install a job agent
    1. Things to do on the web server
    2. Things to do on the database server
    3. Things to do on the job agent server
  3. Configuring the job agent
See also

Last updated: $Date: 2007-08-16 14:16:43 +0000 (Thu, 16 Aug 2007) $
Copyright © 2006 The respective authors. All rights reserved.

1. What is a job agent?

A job agent is a program running on another computer that is regularly checking the BASE job queue for jobs that are awaiting execution. When the job agent finds a job that it is able to execute it loads the plugin and executes it.

A job agent supports lots of configuration options that are not supported by the internal job queue. For example, you can:

All these options make it possible to create a very flexible setup. For example one job agent can be assigned for importing data only. Another job agent can be assigned for running analysis plugins for specific project only. A third may be a catch-all job agent that does all low-priority jobs.

2. How to install a job agent

It is not very difficult to install a job agent, but it requires some manual configuration. Therefore, no job agent is installed by default. Here is how to do it:

2.1 Things to do on the web server

1. Disable the internal job queue on the web server
We don't recommend using the internal job queue at the same time as job agents. The setting jobqueue.internal.enabled should be changed to false for the web server. This setting is found in the www/WEB-INF/classes/base.config file. After you have changed the setting the web server must be restarted.
2. Enable the job agent user account
The default installation creates a user account that the job agent uses to log in to BASE. This user account is disabled by default. You must enable the account and give it a password. This password goes into the jobagent.properties file in step 2.3.3 below.

2.2 Things to do on the database server

1. Create a user account on the database
This is the same step as step iv) in the regular BASE installation. You must create an account in the database that is allowed to connect from the job agent server. MySQL example:
GRANT ALL ON base2.* TO base2user@job.agent.host IDENTIFIED BY 'password';
GRANT ALL ON base2dynamic.* TO base2user@job.agent.host;
Replace job.agent.host with the host name of the server that is going to run the job agent. You should also change the password. This password goes into the base.config file in step 2.3.2 below.

2.3 Things to do on the job agent server

1. Download and unpack the regular BASE 2 distribution
You must use the same version on the web server and all job agents. You find the downloads here: http://base.thep.lu.se/wiki/DownloadPage
2. Edit the base.config file
The www/WEB-INF/classes/base.config file must be configured to use the same database as the web server application. The most important settings are: See the base.config reference for more information about the settings in this file.
3. Edit the jobagent.properties file
The www/WEB-INF/classes/jobagent.properties file contains settings for the job agent. The most important ones to specify value for are:

The jobagent.properties file contains many more configuration options. See the jobagent.properties reference for more information.

4. Register the job agent
From the bin directory, register the job agent with
./jobagent.sh register
5. Start the job agent
From the bin directory, start the job agent with
./jobagent.sh start &

See the jobagent.sh reference for more information about what you can do with the command line interface.

3. Configuring the job agent

Before the job agent starts executing jobs for you it must be configured. The configuration is done through the web interface.

1. Configure the plugins the job agent should handle
2. Give users access to the job agent
Use the regular Share functionality to specify which users/groups/projects should be able to use the job agent. You must give them at least USE permission.