retryJob: Retry a job, after some external error condition has been...

View source: R/retryJob.R

retryJobR Documentation

Retry a job, after some external error condition has been fixed

Description

Jobs often end in an error that requires external intervention. After such intervention has taken place, this function can be called to re-run those subjobs which either had an error, or which were run after a subjob with an error.

Usage

retryJob(j, msg = "external error corrected")

Arguments

j

the job, as an integer scalar job number. This can be a top-level job, or one of its sub-jobs; in the latter case, the top-level job is used anyway.

msg

a message explaining how the error condition was fixed.

Details

All subjobs of j with errors will be re-run. In addition, any subjob of j which ran after a subjob with errors will also be re-run.

To do this, the function:

  • sets sj$done to 0 for any subjob sj where sj$done < 0 or for any subjob last run after such a subjob

  • sets j$path to MOTUS_PATH$QUEUEx where x is the value of the job's queue.

  • moves the job folder from its current location to MOTUS_PATH$QUEUEx

One of the process servers watching queue 0 will then claim the job and re-run those subjobs touched above, as well as any which had not been run.

Value

TRUE if the job was found and resubmitted to queue 0. FALSE otherwise.

Author(s)

John Brzustowski jbrzusto@REMOVE_THIS_PART_fastmail.fm

See Also

processServer


MotusWTS/motusServer documentation built on Aug. 8, 2024, 10:23 p.m.