pub trait BackendTransaction {
type IdlLayerType: IdlArcSqliteTransaction;
type RuvType: ReplicationUpdateVectorTransaction;
Show 17 methods
// Required methods
fn get_idlayer(&mut self) -> &mut Self::IdlLayerType;
fn get_ruv(&mut self) -> &mut Self::RuvType;
fn get_idxmeta_ref(&self) -> &IdxMeta;
// Provided methods
fn filter2idl(
&mut self,
filt: &FilterResolved,
thres: usize,
) -> Result<(IdList, FilterPlan), OperationError> { ... }
fn filter2idl_sub(
&mut self,
attr: &Attribute,
sub_idx_key: String,
) -> Result<(IdList, FilterPlan), OperationError> { ... }
fn search(
&mut self,
erl: &Limits,
filt: &Filter<FilterValidResolved>,
) -> Result<Vec<Arc<EntrySealedCommitted>>, OperationError> { ... }
fn exists(
&mut self,
erl: &Limits,
filt: &Filter<FilterValidResolved>,
) -> Result<bool, OperationError> { ... }
fn retrieve_range(
&mut self,
ranges: &BTreeMap<Uuid, ReplCidRange>,
) -> Result<Vec<Arc<EntrySealedCommitted>>, OperationError> { ... }
fn verify(&mut self) -> Vec<Result<(), ConsistencyError>> { ... }
fn verify_entry_index(
&mut self,
e: &EntrySealedCommitted,
) -> Result<(), ConsistencyError> { ... }
fn verify_indexes(&mut self) -> Vec<Result<(), ConsistencyError>> { ... }
fn verify_ruv(&mut self, results: &mut Vec<Result<(), ConsistencyError>>) { ... }
fn backup(&mut self, dst_path: &str) -> Result<(), OperationError> { ... }
fn name2uuid(&mut self, name: &str) -> Result<Option<Uuid>, OperationError> { ... }
fn externalid2uuid(
&mut self,
name: &str,
) -> Result<Option<Uuid>, OperationError> { ... }
fn uuid2spn(&mut self, uuid: Uuid) -> Result<Option<Value>, OperationError> { ... }
fn uuid2rdn(&mut self, uuid: Uuid) -> Result<Option<String>, OperationError> { ... }
}
Required Associated Types§
type IdlLayerType: IdlArcSqliteTransaction
type RuvType: ReplicationUpdateVectorTransaction
Required Methods§
fn get_idlayer(&mut self) -> &mut Self::IdlLayerType
fn get_ruv(&mut self) -> &mut Self::RuvType
fn get_idxmeta_ref(&self) -> &IdxMeta
Provided Methods§
sourcefn filter2idl(
&mut self,
filt: &FilterResolved,
thres: usize,
) -> Result<(IdList, FilterPlan), OperationError>
fn filter2idl( &mut self, filt: &FilterResolved, thres: usize, ) -> Result<(IdList, FilterPlan), OperationError>
Recursively apply a filter, transforming into IdList’s on the way. This builds a query execution log, so that it can be examined how an operation proceeded.
fn filter2idl_sub( &mut self, attr: &Attribute, sub_idx_key: String, ) -> Result<(IdList, FilterPlan), OperationError>
fn search( &mut self, erl: &Limits, filt: &Filter<FilterValidResolved>, ) -> Result<Vec<Arc<EntrySealedCommitted>>, OperationError>
sourcefn exists(
&mut self,
erl: &Limits,
filt: &Filter<FilterValidResolved>,
) -> Result<bool, OperationError>
fn exists( &mut self, erl: &Limits, filt: &Filter<FilterValidResolved>, ) -> Result<bool, OperationError>
Given a filter, assert some condition exists. Basically, this is a specialised case of search, where we don’t need to load any candidates if they match. This is heavily used in uuid refint and attr uniqueness.