pub struct TagPruner<'a> { /* private fields */ }Expand description
One query’s view of the index, used to eliminate segments that cannot match its tag filters.
§Why this answers “excluded” rather than “matching”
The index is derived state: it is updated after the catalog, from a segment’s series sidecar, and a segment can be in the catalog while the index has never heard of it — for the window between a compaction’s catalog swap and its index swap, and for as long as a sidecar cannot be read. A lookup that returns “the segments that match” cannot express that gap: everything it does not return is pruned, so a segment the index has not seen is indistinguishable from one it has seen and rejected.
Asking the opposite question makes the gap safe. Pruning happens only when the index holds the segment’s tag set and that set is missing a filtered pair, so an unindexed segment is scanned — slower, never wrong. This is the same rule the zone maps follow: a pruning structure may only ever fail towards more work.
Implementations§
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for TagPruner<'a>
impl<'a> !Send for TagPruner<'a>
impl<'a> !UnwindSafe for TagPruner<'a>
impl<'a> Freeze for TagPruner<'a>
impl<'a> Sync for TagPruner<'a>
impl<'a> Unpin for TagPruner<'a>
impl<'a> UnsafeUnpin for TagPruner<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more