Expand description
Segment access abstractions for layouts.
Layouts refer to byte ranges by SegmentId. A SegmentSource resolves those ids to buffer
handles for readers, while a SegmentSink assigns ids when writers emit buffers.
SegmentCache implementations can sit in front of sources to reuse segment bytes across
scans.
Structs§
- File
Segment Cache - One file’s view of a
MokaSegmentCache; seeMokaSegmentCache::for_file. - Instrumented
Segment Cache - Wrapper for
SegmentCachethat tracks its hit rate. - Moka
Segment Cache - An in-memory Moka cache of segments, capped by total buffer bytes, that any number of files can share.
- NoOp
Segment Cache - Segment cache implementation that never stores anything.
- Segment
Cache Source Adapter SegmentSourcewrapper that consults aSegmentCachebefore the underlying source.- Segment
Id - Identifier for a single physical segment referenced by a layout.
- Segment
Source Id - Identifies the contents of one segment source, usually a file, in a cache that many sources share.
- Shared
Segment Source - A
SegmentSourcethat allows multiple requesters to await the same underlying segment request. - Test
Segments - A dummy in-memory implementation of a segment reader and writer.
Enums§
- Segment
Eviction - Which segments a
MokaSegmentCacheevicts when it is full.
Traits§
- Segment
Cache - Cache for individual segment byte buffers.
- Segment
Sink - Assigns segment ids and writes segment buffers during layout writing.
- Segment
Source - Provides segment data to a
crate::LayoutReader.
Type Aliases§
- Segment
Future - Static future resolving to a segment byte buffer.
- Segment
Sink Ref - Shared writer-side segment sink.