Bläddra i källkod

Added documentation and ensured --single works for non-parallel jobs.

Lacey Sanderson 8 år sedan
förälder
incheckning
9f42bd0f5d
2 ändrade filer med 5 tillägg och 2 borttagningar
  1. 4 1
      tripal_core/api/tripal_core.jobs.api.inc
  2. 1 1
      tripal_core/tripal_core.drush.inc

+ 4 - 1
tripal_core/api/tripal_core.jobs.api.inc

@@ -421,7 +421,10 @@ function tripal_execute_job($job_id, $redirect = TRUE) {
  *   based on order and priority.  However there are times when a specific
  *   based on order and priority.  However there are times when a specific
  *   job needs to be launched and this argument will allow it.  Only jobs
  *   job needs to be launched and this argument will allow it.  Only jobs
  *   which have not been run previously will run.
  *   which have not been run previously will run.
- *
+ * @param $max_jobs
+ *   The maximum number of jobs that should be run concurrently. If -1 then unlimited.
+ * @param $single
+ *   Ensures only a single job is run rather then the entire queue.
  * @ingroup tripal_jobs_api
  * @ingroup tripal_jobs_api
  */
  */
 function tripal_launch_job($do_parallel = 0, $job_id = NULL, $max_jobs = -1, $single = 0) {
 function tripal_launch_job($do_parallel = 0, $job_id = NULL, $max_jobs = -1, $single = 0) {

+ 1 - 1
tripal_core/tripal_core.drush.inc

@@ -335,7 +335,7 @@ function drush_tripal_core_trp_run_jobs() {
     drush_print("Tripal Job Launcher");
     drush_print("Tripal Job Launcher");
     drush_print("Running as user '$username'");
     drush_print("Running as user '$username'");
     drush_print("-------------------");
     drush_print("-------------------");
-    tripal_launch_job(0, $job_id);
+    tripal_launch_job(0, $job_id, $max_jobs, $single);
   }
   }
 }
 }
 /**
 /**