Tripal Jobs API

  1. 2.x tripal_core/api/ tripal_jobs_api
  2. 1.x tripal_core/api/ tripal_jobs_api

Tripal offers a job management subsystem for managing tasks that may require an extended period of time for completion. Drupal uses a UNIX-based cron job to handle tasks such as checking the availability of updates, indexing new nodes for searching, etc. Drupal's cron uses the web interface for launching these tasks, however, Tripal provides several administrative tasks that may time out and not complete due to limitations of the web server. Examples including syncing of a large number of features between chado and Drupal. To circumvent this, as well as provide more fine-grained control and monitoring, Tripal uses a jobs management sub-system built into the Tripal Core module. It is anticipated that this functionality will be used for managing analysis jobs provided by future tools, with eventual support for distributed computing.

The Tripal jobs management system allows administrators to submit tasks to be performed which can then be launched through a UNIX command-line PHP script or cron job. This command-line script can be added to a cron entry along-side the Drupal cron entry for automatic, regular launching of Tripal jobs. The order of execution of waiting jobs is determined first by priority and second by the order the jobs were entered.

The API functions described below provide a programmatic interface for adding, checking and viewing jobs.


tripal_core/api/, line 8
Tripal offers a job management subsystem for managing tasks that may require an extended period of time for completion.


Name Locationsort descending Description
tripal_add_job tripal_core/api/ Adds a job to the Tripal Jbo queue
tripal_get_job tripal_core/api/ Retrieve information regarding a tripal job
tripal_is_job_running tripal_core/api/ Indicates if any jobs are running.
tripal_get_job_start tripal_core/api/ Returns the start time for a given job
tripal_get_job_end tripal_core/api/ Returns the end time for a given job
tripal_max_jobs_exceeded tripal_core/api/ Check for too many concurrent jobs
tripal_rerun_job tripal_core/api/ Set a job to be re-ran (ie: add it back into the job queue)
tripal_cancel_job tripal_core/api/ Cancel a Tripal Job currently waiting in the job queue
tripal_launch_job tripal_core/api/ A function used to manually launch all queued tripal jobs
tripal_get_active_jobs tripal_core/api/ Returns a list of jobs that are active.
tripal_get_job_submit_date tripal_core/api/ Returns the date the job was added to the queue