rrq_worker_envir_set: Set worker environment

View source: R/rrq_workers.R

rrq_worker_envir_setR Documentation

Set worker environment

Description

Register a function to create an environment when creating a worker. When a worker starts, they will run this function.

Usage

rrq_worker_envir_set(create, notify = TRUE, controller = NULL)

Arguments

create

A function that will create an environment. It will be called with one parameter (an environment), in a fresh R session. The function rrq_envir() can be used to create a suitable function for the most common case (loading packages and sourcing scripts).

notify

Boolean, indicating if we should send a REFRESH message to all workers to update their environment.

controller

The controller to use. If not given (or NULL) we'll use the controller registered with rrq_default_controller_set().


mrc-ide/rrq documentation built on April 25, 2024, 11:59 p.m.