pub struct CompactFragReuseIndex {
pub uuid: Uuid,
pub details: FragReuseIndexDetails,
/* private fields */
}Expand description
A compact row-address remap chain for deferred compactions.
Each FRI version retains rewritten-row bitmaps and fragment layouts. Queries use bitmap rank plus the ordered new-fragment ranges instead of storing one hash-map entry per affected row.
Fields§
§uuid: Uuid§details: FragReuseIndexDetailsImplementations§
Source§impl CompactFragReuseIndex
impl CompactFragReuseIndex
Sourcepub fn try_new(uuid: Uuid, details: FragReuseIndexDetails) -> Result<Self>
pub fn try_new(uuid: Uuid, details: FragReuseIndexDetails) -> Result<Self>
Build a queryable index directly from serialized FRI details without expanding each affected row into a hash map.
Sourcepub fn row_addr_remap(&self) -> &RowAddrRemap
pub fn row_addr_remap(&self) -> &RowAddrRemap
The ordered remap chain used by index and transaction remapping paths.
pub fn remap_row_id(&self, row_id: u64) -> Option<u64>
Sourcepub fn remap_row_ids_in_place(&self, row_ids: &mut [Option<u64>])
pub fn remap_row_ids_in_place(&self, row_ids: &mut [Option<u64>])
Apply all FRI versions to row addresses in place. None values remain
deleted and missing mappings pass through unchanged.
pub fn remap_row_addrs_tree_map( &self, row_addrs: &RowAddrTreeMap, ) -> RowAddrTreeMap
pub fn remap_row_ids_roaring_tree_map( &self, row_ids: &RoaringTreemap, ) -> RoaringTreemap
Sourcepub fn remap_row_ids_record_batch(
&self,
batch: RecordBatch,
row_id_idx: usize,
) -> Result<RecordBatch>
pub fn remap_row_ids_record_batch( &self, batch: RecordBatch, row_id_idx: usize, ) -> Result<RecordBatch>
Remap a record batch that contains a row_id column at index row_id_idx
Currently this assumes there are only 2 columns in the schema,
which is the case for all indexes.
For example, for btree, the schema is (value, row_id).
For vector index storage, the schema is (row_id, vector).
pub fn remap_row_ids_array(&self, array: ArrayRef) -> PrimitiveArray<UInt64Type>
pub fn remap_fragment_bitmap( &self, fragment_bitmap: &mut RoaringBitmap, ) -> Result<()>
Trait Implementations§
Source§impl Clone for CompactFragReuseIndex
impl Clone for CompactFragReuseIndex
Source§fn clone(&self) -> CompactFragReuseIndex
fn clone(&self) -> CompactFragReuseIndex
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CompactFragReuseIndex
impl Debug for CompactFragReuseIndex
Source§impl DeepSizeOf for CompactFragReuseIndex
impl DeepSizeOf for CompactFragReuseIndex
fn deep_size_of_children(&self, cx: &mut Context) -> usize
fn deep_size_of(&self) -> usize
impl Eq for CompactFragReuseIndex
Source§impl PartialEq for CompactFragReuseIndex
impl PartialEq for CompactFragReuseIndex
impl StructuralPartialEq for CompactFragReuseIndex
Auto Trait Implementations§
impl Freeze for CompactFragReuseIndex
impl RefUnwindSafe for CompactFragReuseIndex
impl Send for CompactFragReuseIndex
impl Sync for CompactFragReuseIndex
impl Unpin for CompactFragReuseIndex
impl UnsafeUnpin for CompactFragReuseIndex
impl UnwindSafe for CompactFragReuseIndex
Blanket Implementations§
impl<T> Allocation for T
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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