The code above, f2 function is intended to be a Plumber endpoint function that uses future_promise to launch new tasks (execution of f1 function, which is a slow code). The f1 function uses furrr::future_map to iterate. In the future plan, I set the outer and inner workers to 2 and 4 respectively, which is intended to allocate 2 workers on the Plumber R session for launching function f1, and after these f1-running workers have launched, 4 workers within each f1-launching worker to execute my_function. I have only been able to run my_function (through furrr::future_map) sequentially, rather than the intended 4 workers topology.
The code above,
f2
function is intended to be a Plumber endpoint function that usesfuture_promise
to launch new tasks (execution off1
function, which is a slow code). Thef1
function usesfurrr::future_map
to iterate. In the future plan, I set the outer and inner workers to 2 and 4 respectively, which is intended to allocate 2 workers on the Plumber R session for launching functionf1
, and after thesef1
-running workers have launched, 4 workers within eachf1
-launching worker to executemy_function
. I have only been able to runmy_function
(throughfurrr::future_map
) sequentially, rather than the intended 4 workers topology.