Expand description
LZ4-compressed sort chunk files for spilling to disk.
During Phase 1 (read + process), each rayon thread accumulates
SortEntry items in a local buffer. When the buffer exceeds a
size threshold, it is sorted by key and flushed to a chunk file.
Each chunk file contains a sequence of length-prefixed postcard frames compressed with LZ4.
Structs§
- Chunk
Reader - Streaming reader for a single chunk file.
- Chunk
Sink - Manages writing sorted chunk files to a temporary directory.
- Sort
Buffer - A thread-local buffer that accumulates sort entries and flushes
to a
ChunkSinkwhen the buffer exceeds the size threshold.
Functions§
- read_
chunk - Read all sort entries from a chunk file, in order.