pub struct SSTableReaderConfig {
pub read_buffer_size: usize,
pub use_mmap: bool,
pub mmap_min_size_bytes: usize,
pub block_cache_size: usize,
pub validate_checksums: bool,
pub use_bloom_filter: bool,
pub prefetch_size: usize,
}Expand description
Configuration for SSTable reader
Fields§
§read_buffer_size: usizeSize of the read buffer in bytes
use_mmap: boolWhether to memory-map SSTable files instead of using buffered file I/O.
Opt-in; defaults to false. When enabled, files at or above
Self::mmap_min_size_bytes are mapped into the address space and
served from the OS page cache with no per-block read syscall. This
mirrors Cassandra’s disk_access_mode: mmap and benefits repeated local
scans of the same files. Enable only for immutable local SSTables — see
crate::Config’s storage.use_mmap for the platform/filesystem
constraints (network FS and external mutation can SIGBUS).
mmap_min_size_bytes: usizeMinimum file size (bytes) for memory mapping to kick in.
Files smaller than this use buffered I/O even when Self::use_mmap is
set, since the per-file mapping overhead is not worthwhile for tiny
files and mapping a zero-length file is invalid.
block_cache_size: usizeMaximum number of blocks to cache
validate_checksums: boolWhether to validate checksums
use_bloom_filter: boolWhether to use bloom filters
prefetch_size: usizePrefetch size for sequential reads
Trait Implementations§
Source§impl Clone for SSTableReaderConfig
impl Clone for SSTableReaderConfig
Source§fn clone(&self) -> SSTableReaderConfig
fn clone(&self) -> SSTableReaderConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more