The main issue I'm trying to handle is around passing cpp code into cluster nodes.
The approach used to be clusterEvalQ(cl, library("mulea")) so the package was loaded inside each cluster. However, it seems this is not good practice: "Don’t use library() or require(). These modify the search path, affecting what functions are available from the global environment. Instead, you should use the DESCRIPTION to specify your package’s requirements, as described in Chapter 9. This also makes sure those packages are installed when your package is installed. (https://r-pkgs.org/code.html)"
The current version uses clusterEvalQ(cl, devtools::load_all()) however, this only works inside a development environment so it does not work from the user side. Since during usage the package would be installed anyway, it is probably OK to revert this to the original version despite rdrr's suggestion.
The main issue I'm trying to handle is around passing cpp code into cluster nodes.
The approach used to be
clusterEvalQ(cl, library("mulea"))
so the package was loaded inside each cluster. However, it seems this is not good practice: "Don’t use library() or require(). These modify the search path, affecting what functions are available from the global environment. Instead, you should use the DESCRIPTION to specify your package’s requirements, as described in Chapter 9. This also makes sure those packages are installed when your package is installed. (https://r-pkgs.org/code.html)"The current version uses
clusterEvalQ(cl, devtools::load_all())
however, this only works inside a development environment so it does not work from the user side. Since during usage the package would be installed anyway, it is probably OK to revert this to the original version despite rdrr's suggestion.