Runtime options configure the execution environment. Use global = TRUE to configure the global context or use the returned object as a scoped context. A scoped context is recommended for programmatic usage as it prevents named views from interfering with each other.

sd_connect(
  ...,
  global = FALSE,
  memory_limit = NULL,
  temp_dir = NULL,
  memory_pool_type = NULL,
  unspillable_reserve_ratio = NULL
)

Arguments

...

Reserved for future options

global

Use TRUE to set options on the global context.

memory_limit

Maximum memory for query execution, as a human-readable string (e.g., "4gb", "512m") or NULL for unbounded (the default).

temp_dir

Directory for temporary/spill files, or NULL to use the DataFusion default.

memory_pool_type

Memory pool type: "greedy" (default) or "fair". Only takes effect when memory_limit is set.

unspillable_reserve_ratio

Fraction of memory (0–1) reserved for unspillable consumers. Only applies when memory_pool_type is "fair". Defaults to 0.2 when not explicitly set.

Value

The constructed context, invisibly.

Examples

sd_connect(memory_limit = "100mb", memory_pool_type = "fair")