29.2.11. Plug-ins, jobs and job agents

This section gives an overview of plug-ins, jobs and job agents.

See also

Figure 29.12. Plug-ins, jobs and job agents

Plug-ins, jobs and job agents


The PluginDefinitionData holds information of the installed plugin classes. Much of the information is copied from the plug-in itself from the About object and by checking which interfaces it implements.

There are five main types of plug-ins:

  • IMPORT (mainType = 1): A plug-in that imports data to BASE.

  • EXPORT (mainType = 2): A plug-in that exports data from BASE.

  • INTENSITY (mainType = 3): A plug-in that calculates intensity values from raw data.

  • ANALYZE (mainType = 4): A plug-in that analyses data.

  • OTHER (mainType = 5): Any other plug-in.

A plug-in may have different configurations. The flags supportsConfigurations and requiresConfiguration are used to specify if a plug-in must have or can't have any configurations. Configuration parameter values are versioned. Each time anyone updates a configuration the version number is increased and the parameter values are stored as a new entity. This is required because we want to be able to know exactly which parameters a job were using when it was executed. When a job is created we also store the parameter version number (JobData.parameterVersion). This means that even if someone changes the configuration later we will always know which parameters the job used.

The PluginTypeData class is ued to group plug-ins that share some common functionality, by implementing additional (optional) interfaces. For example, the AutoDetectingImporter should be implemented by import plug-ins that supports automatic detection of file formats. Another example is the AnalysisFilterPlugin interface which should be implemented by all analysis plug-ins that only filters data.


A job represents a single invokation of a plug-in to do some work. The JobData class holds information about this. A job is usuallu executed by a plug-in, but doesn't have to be. The status property holds the current state of a job.

  • UNCONFIGURED (status = 0): The job is not yet ready to be executed.

  • WAITING (status = 1): The job is waiting to be executed.

  • PREPARING (status = 5): The job is about to be executed but hasn't started yet.

  • EXECUTING (status = 2): The job is currently executing.

  • ABORTING (status = 6): The job is executing but an ABORT signal has been sent requesting it to abort and finish.

  • DONE (status = 3): The job finished successfully.

  • ERROR (status = 4): The job finished with an error.

Job agents

A job agent is a program running on the same or a different server that is regularly checking for jobs that are waiting to be executed. The JobAgentData holds information about a job agent and the JobAgentSettingsData links the agent with the plug-ins the agent is able to execute. The job agent will only execute jobs that are owned by users or projects that the job agent has been shared to with at least use permission. The priorityBoost property can be used to give specific plug-ins higher priority. Thus, for a job agent it is possible to:

  • Specify exactly which plug-ins it will execute. For example, it is possible to dedicate one agent to only run one plug-in.

  • Give some plug-ins higher priority. For example a job agent that is mainly used for importing data should give higher priority to all import plug-ins. Other types of jobs will have to wait until there are no more data to be imported.

  • Specify exactly which users/groups/projects that may use the agent. For example, it is possible to dedicate one agent to only run jobs for a certain project.