Skip to main content

default_max_batch_bytes

Function default_max_batch_bytes 

Source
pub fn default_max_batch_bytes() -> usize
Expand description

The byte ceiling a read uses when the caller sets none: GDAL’s min(INT32_MAX, RAM / 4).

The memory term only binds below about 8 GB of RAM, since a quarter of anything larger already exceeds DEFAULT_MAX_BATCH_BYTES. It is there so a small machine does not spend a quarter of itself on a single batch.

The system’s memory is read once and cached. It is queried to choose a default, not to track a machine whose memory changes while we run.