makeClusterFunctions: Create a ClusterFuntions object.

Description Usage Arguments See Also


Use this funtion when you implement a backend for a batch system. You must define the functions specified in the arguments.


makeClusterFunctions(name, submitJob, killJob, listJobs, getArrayEnvirName,
  class = NULL, ...)



Name of cluster functions.


[function(conf, reg,, rscript, log.file, job.dir, resources, ...)]
Function to submit a new job. Must return a SubmitJobResult object.
The arguments are:
conf [environment]: The user configuration.
reg [Registry]: The registry. [character(1)]: Name of job, used if the job is displayed on the batch system. This is just for display and not an id!
rscript [character(1)]: File path to R script that is used to execute the job.
log.file [character(1)]: File path where log file (.Rout) has to be placed.
job.dir [character(1)]: Directory where all files relating to this job are placed.
resources [list]: Freely definable list of required resources for this job, e.g. walltime or memory.


[function(conf, reg,]
Function to kill a job on the batch system. Make sure that you definately kill the job! Return value is currently ignored.
The arguments are:
conf [environment]: The user configuration.
reg [Registry]: The registry. [character(1)]: Batch job id, as produced by submitJob.
Set killJob to NULL if killing jobs cannot be supported.


[function(conf, reg)]
List all jobs on the batch system for the current user / registry. This includes queued, running, held, idle, etc. jobs. Must return an integer vector of batch job ids, same format as they are produced by submitJob. It does not matter if you return a few job ids too many (e.g. all for the current user instead of all for the current registry), but you have to include all relevant ones. The arguments are:
conf [environment]: The user configuration.
reg [Registry]: The registry.
Set listJobs to NULL if listing jobs cannot be supported.


Returns the name of the environment variable specifying the array ID. Should return NA if not supported.


Optional class name for cluster functions object. Useful to provide a nice print method which might show additional information about the workers. Default is NULL.


Currently ignored.

See Also

Other clusterFunctions: makeClusterFunctionsInteractive; makeClusterFunctionsLSF; makeClusterFunctionsLocal; makeClusterFunctionsMulticore; makeClusterFunctionsSGE; makeClusterFunctionsSLURM; makeClusterFunctionsSSH; makeClusterFunctionsTorque

Search within the BatchJobs package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.