pub struct FragReuseIndex {
pub uuid: Uuid,
pub row_id_maps: Vec<HashMap<u64, Option<u64>>>,
pub details: FragReuseIndexDetails,
}Expand description
An index that stores row ID maps. A row ID map describes the mapping from old row address to new address after compactions. Each version contains the mapping for one round of compaction.
Fields§
§uuid: Uuid§row_id_maps: Vec<HashMap<u64, Option<u64>>>§details: FragReuseIndexDetailsImplementations§
Source§impl FragReuseIndex
impl FragReuseIndex
pub fn new( uuid: Uuid, row_id_maps: Vec<HashMap<u64, Option<u64>>>, details: FragReuseIndexDetails, ) -> Self
pub fn remap_row_id(&self, row_id: u64) -> Option<u64>
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 FragReuseIndex
impl Clone for FragReuseIndex
Source§fn clone(&self) -> FragReuseIndex
fn clone(&self) -> FragReuseIndex
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FragReuseIndex
impl Debug for FragReuseIndex
Source§impl DeepSizeOf for FragReuseIndex
impl DeepSizeOf for FragReuseIndex
fn deep_size_of_children(&self, cx: &mut Context) -> usize
fn deep_size_of(&self) -> usize
Source§impl<'de> Deserialize<'de> for FragReuseIndex
impl<'de> Deserialize<'de> for FragReuseIndex
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for FragReuseIndex
Source§impl PartialEq for FragReuseIndex
impl PartialEq for FragReuseIndex
Source§fn eq(&self, other: &FragReuseIndex) -> bool
fn eq(&self, other: &FragReuseIndex) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for FragReuseIndex
impl Serialize for FragReuseIndex
impl StructuralPartialEq for FragReuseIndex
Auto Trait Implementations§
impl Freeze for FragReuseIndex
impl RefUnwindSafe for FragReuseIndex
impl Send for FragReuseIndex
impl Sync for FragReuseIndex
impl Unpin for FragReuseIndex
impl UnsafeUnpin for FragReuseIndex
impl UnwindSafe for FragReuseIndex
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
Mutably borrows from an owned value. Read more
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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
Compare self to
key and return true if they are equal.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>
Converts
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>
Converts
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