Skip to content

Commit 5eaae0b

Browse files
Now argument 'workers' for plan(multisession) defaults to availableCores(constraints = "connections-16") [#797]
1 parent b908c6f commit 5eaae0b

File tree

5 files changed

+12
-5
lines changed

5 files changed

+12
-5
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
Package: future
2-
Version: 1.58.0-9012
2+
Version: 1.58.0-9013
33
Title: Unified Parallel and Distributed Processing in R for Everyone
44
Depends:
55
R (>= 3.2.0)

NEWS.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
11
# Version (development version)
22

3+
## Significant Changes
4+
5+
* Now argument `workers` for `plan(multisession)` defaults to
6+
`availableCores(constraints = "connections-16")`. This will make
7+
`plan(multisession)` work also on computers with a large number of
8+
CPU cores, e.g. 192 and 256 cores.
9+
310
## Performance
411

512
* The pre-validation of the cluster worker allotted to a future when

R/backend_api-13.MultisessionFutureBackend-class.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#' @keywords internal
1414
#' @rdname FutureBackend
1515
#' @export
16-
MultisessionFutureBackend <- function(workers = availableCores(), rscript_libs = .libPaths(), interrupts = TRUE, gc = FALSE, earlySignal = FALSE, ...) {
16+
MultisessionFutureBackend <- function(workers = availableCores(constraints = "connections-16"), rscript_libs = .libPaths(), interrupts = TRUE, gc = FALSE, earlySignal = FALSE, ...) {
1717
debug <- isTRUE(getOption("future.debug"))
1818
if (debug) {
1919
mdebugf_push("MultisessionFutureBackend(workers = <workers>, interrupts = %s, ...) ...", interrupts)
@@ -129,7 +129,7 @@ print.MultisessionFutureBackend <- function(x, validate = TRUE, ...) {
129129
#'
130130
#' @aliases MultisessionFuture
131131
#' @export
132-
multisession <- function(..., workers = availableCores(), lazy = FALSE, rscript_libs = .libPaths(), gc = FALSE, earlySignal = FALSE, envir = parent.frame()) {
132+
multisession <- function(..., workers = availableCores(constraints = "connections-16"), lazy = FALSE, rscript_libs = .libPaths(), gc = FALSE, earlySignal = FALSE, envir = parent.frame()) {
133133
stop("INTERNAL ERROR: The future::multisession() must never be called directly")
134134
}
135135
class(multisession) <- c("multisession", "cluster", "multiprocess", "future", "function")

man/FutureBackend.Rd

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/multisession.Rd

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)