Skip to main content

release_read_ahead

Function release_read_ahead 

Source
fn release_read_ahead(
    prefetched: &mut PrefetchedBlocks,
    buffers: &mut HashMap<u64, Bytes>,
)
Expand description

Drops the read-ahead window so a block that fits on its own can retry its reservation, and keeps the next blocks from attempting the same window again.

A slice retains its whole shared fetch, whose charge leaves with the window, so the current block’s slices are copied out first. The block’s own reservation already covers them.